Commit ff4e065d authored by Kevin McKinney's avatar Kevin McKinney Committed by Greg Kroah-Hartman

Staging: bcm: Remove typedef for _FLASH2X_SECTION_VAL and reference directly.

This patch removes typedef for _FLASH2X_SECTION_VAL,
and changes the name of the enum to bcm_flash2x_section_val.
In addition, any calls to typedefs FLASH2X_SECTION_VAL
are changed to reference the enum directly.
Signed-off-by: default avatarKevin McKinney <klmckinney1@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 0becebb1
......@@ -371,8 +371,8 @@ struct bcm_mini_adapter {
PFLASH2X_VENDORSPECIFIC_INFO psFlash2xVendorInfo;
UINT uiFlashBaseAdd; /* Flash start address */
UINT uiActiveISOOffset; /* Active ISO offset chosen before f/w download */
FLASH2X_SECTION_VAL eActiveISO; /* Active ISO section val */
FLASH2X_SECTION_VAL eActiveDSD; /* Active DSD val chosen before f/w download */
enum bcm_flash2x_section_val eActiveISO; /* Active ISO section val */
enum bcm_flash2x_section_val eActiveDSD; /* Active DSD val chosen before f/w download */
UINT uiActiveDSDOffsetAtFwDld; /* For accessing Active DSD chosen before f/w download */
UINT uiFlashLayoutMajorVersion;
UINT uiFlashLayoutMinorVersion;
......
......@@ -1644,7 +1644,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
break;
case IOCTL_BCM_SET_ACTIVE_SECTION: {
FLASH2X_SECTION_VAL eFlash2xSectionVal = 0;
enum bcm_flash2x_section_val eFlash2xSectionVal = 0;
BCM_DEBUG_PRINT(Adapter, DBG_TYPE_OTHERS, OSAL_DBG, DBG_LVL_ALL, "IOCTL_BCM_SET_ACTIVE_SECTION Called");
if (IsFlash2x(Adapter) != TRUE) {
......@@ -1799,7 +1799,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
case IOCTL_BCM_SELECT_DSD: {
UINT SectOfset = 0;
FLASH2X_SECTION_VAL eFlash2xSectionVal;
enum bcm_flash2x_section_val eFlash2xSectionVal;
eFlash2xSectionVal = NO_SECTION_VAL;
BCM_DEBUG_PRINT(Adapter, DBG_TYPE_OTHERS, OSAL_DBG, DBG_LVL_ALL, "IOCTL_BCM_SELECT_DSD Called");
......
......@@ -129,7 +129,7 @@ struct bcm_bulk_wrm_buffer {
unsigned long Values[1];
};
typedef enum _FLASH2X_SECTION_VAL {
enum bcm_flash2x_section_val {
NO_SECTION_VAL = 0, /* no section is chosen when absolute offset is given for RD/WR */
ISO_IMAGE1,
ISO_IMAGE2,
......@@ -146,13 +146,13 @@ typedef enum _FLASH2X_SECTION_VAL {
ISO_IMAGE2_PART2,
ISO_IMAGE2_PART3,
TOTAL_SECTIONS
} FLASH2X_SECTION_VAL;
};
/*
* Structure used for READ/WRITE Flash Map2.x
*/
struct bcm_flash2x_readwrite {
FLASH2X_SECTION_VAL Section; /* which section has to be read/written */
enum bcm_flash2x_section_val Section; /* which section has to be read/written */
u32 offset; /* Offset within Section. */
u32 numOfBytes; /* NOB from the offset */
u32 bVerify;
......@@ -167,8 +167,8 @@ struct bcm_flash2x_readwrite {
*/
struct bcm_flash2x_copy_section {
FLASH2X_SECTION_VAL SrcSection;
FLASH2X_SECTION_VAL DstSection;
enum bcm_flash2x_section_val SrcSection;
enum bcm_flash2x_section_val DstSection;
u32 offset;
u32 numOfBytes;
};
......
......@@ -161,14 +161,14 @@ INT BeceemNVMWrite(
INT BcmInitNVM(struct bcm_mini_adapter *Adapter);
INT BcmUpdateSectorSize(struct bcm_mini_adapter *Adapter,UINT uiSectorSize);
BOOLEAN IsSectionExistInFlash(struct bcm_mini_adapter *Adapter, FLASH2X_SECTION_VAL section);
BOOLEAN IsSectionExistInFlash(struct bcm_mini_adapter *Adapter, enum bcm_flash2x_section_val section);
INT BcmGetFlash2xSectionalBitMap(struct bcm_mini_adapter *Adapter, struct bcm_flash2x_bitmap *psFlash2xBitMap);
INT BcmFlash2xBulkWrite(
struct bcm_mini_adapter *Adapter,
PUINT pBuffer,
FLASH2X_SECTION_VAL eFlashSectionVal,
enum bcm_flash2x_section_val eFlashSectionVal,
UINT uiOffset,
UINT uiNumBytes,
UINT bVerify);
......@@ -176,24 +176,24 @@ INT BcmFlash2xBulkWrite(
INT BcmFlash2xBulkRead(
struct bcm_mini_adapter *Adapter,
PUINT pBuffer,
FLASH2X_SECTION_VAL eFlashSectionVal,
enum bcm_flash2x_section_val eFlashSectionVal,
UINT uiOffsetWithinSectionVal,
UINT uiNumBytes);
INT BcmGetSectionValStartOffset(struct bcm_mini_adapter *Adapter, FLASH2X_SECTION_VAL eFlashSectionVal);
INT BcmGetSectionValStartOffset(struct bcm_mini_adapter *Adapter, enum bcm_flash2x_section_val eFlashSectionVal);
INT BcmSetActiveSection(struct bcm_mini_adapter *Adapter, FLASH2X_SECTION_VAL eFlash2xSectVal);
INT BcmSetActiveSection(struct bcm_mini_adapter *Adapter, enum bcm_flash2x_section_val eFlash2xSectVal);
INT BcmAllocFlashCSStructure(struct bcm_mini_adapter *psAdapter);
INT BcmDeAllocFlashCSStructure(struct bcm_mini_adapter *psAdapter);
INT BcmCopyISO(struct bcm_mini_adapter *Adapter, struct bcm_flash2x_copy_section sCopySectStrut);
INT BcmFlash2xCorruptSig(struct bcm_mini_adapter *Adapter, FLASH2X_SECTION_VAL eFlash2xSectionVal);
INT BcmFlash2xWriteSig(struct bcm_mini_adapter *Adapter, FLASH2X_SECTION_VAL eFlashSectionVal);
INT BcmFlash2xCorruptSig(struct bcm_mini_adapter *Adapter, enum bcm_flash2x_section_val eFlash2xSectionVal);
INT BcmFlash2xWriteSig(struct bcm_mini_adapter *Adapter, enum bcm_flash2x_section_val eFlashSectionVal);
INT validateFlash2xReadWrite(struct bcm_mini_adapter *Adapter, struct bcm_flash2x_readwrite *psFlash2xReadWrite);
INT IsFlash2x(struct bcm_mini_adapter *Adapter);
INT BcmCopySection(struct bcm_mini_adapter *Adapter,
FLASH2X_SECTION_VAL SrcSection,
FLASH2X_SECTION_VAL DstSection,
enum bcm_flash2x_section_val SrcSection,
enum bcm_flash2x_section_val DstSection,
UINT offset,
UINT numOfBytes);
......
This diff is collapsed.
......@@ -89,7 +89,7 @@ INT vendorextnIoctl(struct bcm_mini_adapter *Adapter, UINT cmd, ULONG arg)
//
//------------------------------------------------------------------
INT vendorextnReadSection(PVOID pContext, PUCHAR pBuffer, FLASH2X_SECTION_VAL SectionVal,
INT vendorextnReadSection(PVOID pContext, PUCHAR pBuffer, enum bcm_flash2x_section_val SectionVal,
UINT offset, UINT numOfBytes)
{
return STATUS_FAILURE;
......@@ -114,7 +114,7 @@ INT vendorextnReadSection(PVOID pContext, PUCHAR pBuffer, FLASH2X_SECTION_VAL S
// STATUS_SUCCESS/STATUS_FAILURE
//
//------------------------------------------------------------------
INT vendorextnWriteSection(PVOID pContext, PUCHAR pBuffer, FLASH2X_SECTION_VAL SectionVal,
INT vendorextnWriteSection(PVOID pContext, PUCHAR pBuffer, enum bcm_flash2x_section_val SectionVal,
UINT offset, UINT numOfBytes, BOOLEAN bVerify)
{
return STATUS_FAILURE;
......@@ -138,7 +138,7 @@ INT vendorextnWriteSection(PVOID pContext, PUCHAR pBuffer, FLASH2X_SECTION_VAL
// STATUS_SUCCESS/STATUS_FAILURE
//
//------------------------------------------------------------------
INT vendorextnWriteSectionWithoutErase(PVOID pContext, PUCHAR pBuffer, FLASH2X_SECTION_VAL SectionVal,
INT vendorextnWriteSectionWithoutErase(PVOID pContext, PUCHAR pBuffer, enum bcm_flash2x_section_val SectionVal,
UINT offset, UINT numOfBytes)
{
return STATUS_FAILURE;
......
......@@ -8,11 +8,11 @@ INT vendorextnGetSectionInfo(PVOID pContext,PFLASH2X_VENDORSPECIFIC_INFO pVendo
INT vendorextnExit(struct bcm_mini_adapter *Adapter);
INT vendorextnInit(struct bcm_mini_adapter *Adapter);
INT vendorextnIoctl(struct bcm_mini_adapter *Adapter, UINT cmd, ULONG arg);
INT vendorextnReadSection(PVOID pContext, PUCHAR pBuffer, FLASH2X_SECTION_VAL SectionVal,
INT vendorextnReadSection(PVOID pContext, PUCHAR pBuffer, enum bcm_flash2x_section_val SectionVal,
UINT offset, UINT numOfBytes);
INT vendorextnWriteSection(PVOID pContext, PUCHAR pBuffer, FLASH2X_SECTION_VAL SectionVal,
INT vendorextnWriteSection(PVOID pContext, PUCHAR pBuffer, enum bcm_flash2x_section_val SectionVal,
UINT offset, UINT numOfBytes, BOOLEAN bVerify);
INT vendorextnWriteSectionWithoutErase(PVOID pContext, PUCHAR pBuffer, FLASH2X_SECTION_VAL SectionVal,
INT vendorextnWriteSectionWithoutErase(PVOID pContext, PUCHAR pBuffer, enum bcm_flash2x_section_val SectionVal,
UINT offset, UINT numOfBytes);
#endif /* */
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment