forked from Minki/linux
keucr: fixes do not use C99 // comments error
This patch fixes the following checkpatch error, ERROR: do not use C99 // comments Signed-off-by: Amarjargal Gundjalam <amarjargal16@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
dc606b8e4f
commit
1557a64028
@ -50,7 +50,8 @@ DWORD ErrCode;
|
|||||||
static BYTE WorkBuf[SECTSIZE];
|
static BYTE WorkBuf[SECTSIZE];
|
||||||
static BYTE Redundant[REDTSIZE];
|
static BYTE Redundant[REDTSIZE];
|
||||||
static BYTE WorkRedund[REDTSIZE];
|
static BYTE WorkRedund[REDTSIZE];
|
||||||
static WORD *Log2Phy[MAX_ZONENUM]; // 128 x 1000, Log2Phy[MAX_ZONENUM][MAX_LOGBLOCK];
|
/* 128 x 1000, Log2Phy[MAX_ZONENUM][MAX_LOGBLOCK]; */
|
||||||
|
static WORD *Log2Phy[MAX_ZONENUM];
|
||||||
static BYTE Assign[MAX_ZONENUM][MAX_BLOCKNUM / 8];
|
static BYTE Assign[MAX_ZONENUM][MAX_BLOCKNUM / 8];
|
||||||
static WORD AssignStart[MAX_ZONENUM];
|
static WORD AssignStart[MAX_ZONENUM];
|
||||||
WORD ReadBlock;
|
WORD ReadBlock;
|
||||||
@ -58,7 +59,7 @@ WORD WriteBlock;
|
|||||||
DWORD MediaChange;
|
DWORD MediaChange;
|
||||||
static DWORD SectCopyMode;
|
static DWORD SectCopyMode;
|
||||||
|
|
||||||
//BIT Control Macro
|
/* BIT Control Macro */
|
||||||
static BYTE BitData[] = { 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80 };
|
static BYTE BitData[] = { 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80 };
|
||||||
#define Set_D_Bit(a, b) (a[(BYTE)((b) / 8)] |= BitData[(b) % 8])
|
#define Set_D_Bit(a, b) (a[(BYTE)((b) / 8)] |= BitData[(b) % 8])
|
||||||
#define Clr_D_Bit(a, b) (a[(BYTE)((b) / 8)] &= ~BitData[(b) % 8])
|
#define Clr_D_Bit(a, b) (a[(BYTE)((b) / 8)] &= ~BitData[(b) % 8])
|
||||||
@ -68,7 +69,7 @@ BYTE IsSSFDCCompliance;
|
|||||||
BYTE IsXDCompliance;
|
BYTE IsXDCompliance;
|
||||||
|
|
||||||
|
|
||||||
//----- SM_FreeMem() -------------------------------------------------
|
/* ----- SM_FreeMem() ------------------------------------------------- */
|
||||||
int SM_FreeMem(void)
|
int SM_FreeMem(void)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
@ -84,8 +85,8 @@ int SM_FreeMem(void)
|
|||||||
return NO_ERROR;
|
return NO_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
//SmartMedia Read/Write/Erase Function
|
/* SmartMedia Read/Write/Erase Function */
|
||||||
//----- Media_D_ReadSector() -------------------------------------------
|
/* ----- Media_D_ReadSector() ------------------------------------------- */
|
||||||
int Media_D_ReadSector(struct us_data *us, DWORD start, WORD count, BYTE *buf)
|
int Media_D_ReadSector(struct us_data *us, DWORD start, WORD count, BYTE *buf)
|
||||||
{
|
{
|
||||||
WORD len, bn;
|
WORD len, bn;
|
||||||
@ -119,8 +120,8 @@ int Media_D_ReadSector(struct us_data *us, DWORD start, WORD count, BYTE *buf)
|
|||||||
|
|
||||||
return NO_ERROR;
|
return NO_ERROR;
|
||||||
}
|
}
|
||||||
// here
|
/* here */
|
||||||
//----- Media_D_CopySector() ------------------------------------------
|
/* ----- Media_D_CopySector() ------------------------------------------ */
|
||||||
int Media_D_CopySector(struct us_data *us, DWORD start, WORD count, BYTE *buf)
|
int Media_D_CopySector(struct us_data *us, DWORD start, WORD count, BYTE *buf)
|
||||||
{
|
{
|
||||||
WORD len, bn;
|
WORD len, bn;
|
||||||
@ -165,7 +166,7 @@ int Media_D_CopySector(struct us_data *us, DWORD start, WORD count, BYTE *buf)
|
|||||||
return NO_ERROR;
|
return NO_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
//----- Release_D_CopySector() ------------------------------------------
|
/* ----- Release_D_CopySector() ------------------------------------------ */
|
||||||
int Release_D_CopySector(struct us_data *us)
|
int Release_D_CopySector(struct us_data *us)
|
||||||
{
|
{
|
||||||
Log2Phy[Media.Zone][Media.LogBlock] = WriteBlock;
|
Log2Phy[Media.Zone][Media.LogBlock] = WriteBlock;
|
||||||
@ -182,8 +183,8 @@ int Release_D_CopySector(struct us_data *us)
|
|||||||
return SMSUCCESS;
|
return SMSUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
//SmartMedia Physical Format Test Subroutine
|
/* SmartMedia Physical Format Test Subroutine */
|
||||||
//----- Check_D_MediaFmt() ---------------------------------------------
|
/* ----- Check_D_MediaFmt() --------------------------------------------- */
|
||||||
int Check_D_MediaFmt(struct us_data *us)
|
int Check_D_MediaFmt(struct us_data *us)
|
||||||
{
|
{
|
||||||
pr_info("Check_D_MediaFmt\n");
|
pr_info("Check_D_MediaFmt\n");
|
||||||
@ -208,8 +209,8 @@ int Check_D_MediaFmt(struct us_data *us)
|
|||||||
return SMSUCCESS;
|
return SMSUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
//SmartMedia Physical Address Control Subroutine
|
/* SmartMedia Physical Address Control Subroutine */
|
||||||
//----- Conv_D_MediaAddr() ---------------------------------------------
|
/* ----- Conv_D_MediaAddr() --------------------------------------------- */
|
||||||
int Conv_D_MediaAddr(struct us_data *us, DWORD addr)
|
int Conv_D_MediaAddr(struct us_data *us, DWORD addr)
|
||||||
{
|
{
|
||||||
DWORD temp;
|
DWORD temp;
|
||||||
@ -238,7 +239,7 @@ int Conv_D_MediaAddr(struct us_data *us, DWORD addr)
|
|||||||
return ERROR;
|
return ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
//----- Inc_D_MediaAddr() ----------------------------------------------
|
/* ----- Inc_D_MediaAddr() ---------------------------------------------- */
|
||||||
int Inc_D_MediaAddr(struct us_data *us)
|
int Inc_D_MediaAddr(struct us_data *us)
|
||||||
{
|
{
|
||||||
WORD LogBlock = Media.LogBlock;
|
WORD LogBlock = Media.LogBlock;
|
||||||
@ -287,8 +288,8 @@ int Inc_D_MediaAddr(struct us_data *us)
|
|||||||
return ERROR;
|
return ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
//SmartMedia Read/Write Subroutine with Retry
|
/* SmartMedia Read/Write Subroutine with Retry */
|
||||||
//----- Media_D_ReadOneSect() ------------------------------------------
|
/* ----- Media_D_ReadOneSect() ------------------------------------------ */
|
||||||
int Media_D_ReadOneSect(struct us_data *us, WORD count, BYTE *buf)
|
int Media_D_ReadOneSect(struct us_data *us, WORD count, BYTE *buf)
|
||||||
{
|
{
|
||||||
DWORD err, retry;
|
DWORD err, retry;
|
||||||
@ -330,8 +331,8 @@ int Media_D_ReadOneSect(struct us_data *us, WORD count, BYTE *buf)
|
|||||||
return ERROR;
|
return ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
//SmartMedia Physical Sector Data Copy Subroutine
|
/* SmartMedia Physical Sector Data Copy Subroutine */
|
||||||
//----- Copy_D_BlockAll() ----------------------------------------------
|
/* ----- Copy_D_BlockAll() ---------------------------------------------- */
|
||||||
int Copy_D_BlockAll(struct us_data *us, DWORD mode)
|
int Copy_D_BlockAll(struct us_data *us, DWORD mode)
|
||||||
{
|
{
|
||||||
BYTE sect;
|
BYTE sect;
|
||||||
@ -366,8 +367,8 @@ int Copy_D_BlockAll(struct us_data *us, DWORD mode)
|
|||||||
return SMSUCCESS;
|
return SMSUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
//SmartMedia Physical Block Assign/Release Subroutine
|
/* SmartMedia Physical Block Assign/Release Subroutine */
|
||||||
//----- Assign_D_WriteBlock() ------------------------------------------
|
/* ----- Assign_D_WriteBlock() ------------------------------------------ */
|
||||||
int Assign_D_WriteBlock(void)
|
int Assign_D_WriteBlock(void)
|
||||||
{
|
{
|
||||||
ReadBlock = Media.PhyBlock;
|
ReadBlock = Media.PhyBlock;
|
||||||
@ -398,7 +399,7 @@ int Assign_D_WriteBlock(void)
|
|||||||
return ERROR;
|
return ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
//----- Release_D_ReadBlock() ------------------------------------------
|
/* ----- Release_D_ReadBlock() ------------------------------------------ */
|
||||||
int Release_D_ReadBlock(struct us_data *us)
|
int Release_D_ReadBlock(struct us_data *us)
|
||||||
{
|
{
|
||||||
DWORD mode;
|
DWORD mode;
|
||||||
@ -432,7 +433,7 @@ int Release_D_ReadBlock(struct us_data *us)
|
|||||||
return SMSUCCESS;
|
return SMSUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
//----- Release_D_WriteBlock() -----------------------------------------
|
/* ----- Release_D_WriteBlock() ----------------------------------------- */
|
||||||
int Release_D_WriteBlock(struct us_data *us)
|
int Release_D_WriteBlock(struct us_data *us)
|
||||||
{
|
{
|
||||||
SectCopyMode = COMPLETED;
|
SectCopyMode = COMPLETED;
|
||||||
@ -445,8 +446,8 @@ int Release_D_WriteBlock(struct us_data *us)
|
|||||||
return SMSUCCESS;
|
return SMSUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
//SmartMedia Physical Sector Data Copy Subroutine
|
/* SmartMedia Physical Sector Data Copy Subroutine */
|
||||||
//----- Copy_D_PhyOneSect() --------------------------------------------
|
/* ----- Copy_D_PhyOneSect() -------------------------------------------- */
|
||||||
int Copy_D_PhyOneSect(struct us_data *us)
|
int Copy_D_PhyOneSect(struct us_data *us)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
@ -521,8 +522,8 @@ int Copy_D_PhyOneSect(struct us_data *us)
|
|||||||
return SMSUCCESS;
|
return SMSUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
//SmartMedia Physical Sector Read/Write/Erase Subroutine
|
/* SmartMedia Physical Sector Read/Write/Erase Subroutine */
|
||||||
//----- Read_D_PhyOneSect() --------------------------------------------
|
/* ----- Read_D_PhyOneSect() -------------------------------------------- */
|
||||||
int Read_D_PhyOneSect(struct us_data *us, WORD count, BYTE *buf)
|
int Read_D_PhyOneSect(struct us_data *us, WORD count, BYTE *buf)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
@ -573,7 +574,7 @@ int Read_D_PhyOneSect(struct us_data *us, WORD count, BYTE *buf)
|
|||||||
return ERROR;
|
return ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
//----- Erase_D_PhyOneBlock() ------------------------------------------
|
/* ----- Erase_D_PhyOneBlock() ------------------------------------------ */
|
||||||
int Erase_D_PhyOneBlock(struct us_data *us)
|
int Erase_D_PhyOneBlock(struct us_data *us)
|
||||||
{
|
{
|
||||||
if (Ssfdc_D_EraseBlock(us)) {
|
if (Ssfdc_D_EraseBlock(us)) {
|
||||||
@ -589,8 +590,8 @@ int Erase_D_PhyOneBlock(struct us_data *us)
|
|||||||
return SMSUCCESS;
|
return SMSUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
//SmartMedia Physical Format Check Local Subroutine
|
/* SmartMedia Physical Format Check Local Subroutine */
|
||||||
//----- Set_D_PhyFmtValue() --------------------------------------------
|
/* ----- Set_D_PhyFmtValue() -------------------------------------------- */
|
||||||
int Set_D_PhyFmtValue(struct us_data *us)
|
int Set_D_PhyFmtValue(struct us_data *us)
|
||||||
{
|
{
|
||||||
if (Set_D_SsfdcModel(us->SM_DeviceID))
|
if (Set_D_SsfdcModel(us->SM_DeviceID))
|
||||||
@ -599,7 +600,7 @@ int Set_D_PhyFmtValue(struct us_data *us)
|
|||||||
return SMSUCCESS;
|
return SMSUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
//----- Search_D_CIS() -------------------------------------------------
|
/* ----- Search_D_CIS() ------------------------------------------------- */
|
||||||
int Search_D_CIS(struct us_data *us)
|
int Search_D_CIS(struct us_data *us)
|
||||||
{
|
{
|
||||||
Media.Zone = 0;
|
Media.Zone = 0;
|
||||||
@ -651,7 +652,7 @@ int Search_D_CIS(struct us_data *us)
|
|||||||
return ERROR;
|
return ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
//----- Make_D_LogTable() ----------------------------------------------
|
/* ----- Make_D_LogTable() ---------------------------------------------- */
|
||||||
int Make_D_LogTable(struct us_data *us)
|
int Make_D_LogTable(struct us_data *us)
|
||||||
{
|
{
|
||||||
WORD phyblock, logblock;
|
WORD phyblock, logblock;
|
||||||
@ -740,17 +741,17 @@ int Make_D_LogTable(struct us_data *us)
|
|||||||
Media.Sector = 0;
|
Media.Sector = 0;
|
||||||
Media.PhyBlock = phyblock;
|
Media.PhyBlock = phyblock;
|
||||||
|
|
||||||
} // End for (Media.PhyBlock<Ssfdc.MaxBlocks)
|
} /* End for (Media.PhyBlock<Ssfdc.MaxBlocks) */
|
||||||
|
|
||||||
AssignStart[Media.Zone] = 0;
|
AssignStart[Media.Zone] = 0;
|
||||||
|
|
||||||
} // End for (Media.Zone<MAX_ZONENUM)
|
} /* End for (Media.Zone<MAX_ZONENUM) */
|
||||||
|
|
||||||
Ssfdc_D_Reset(us);
|
Ssfdc_D_Reset(us);
|
||||||
return SMSUCCESS;
|
return SMSUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
//----- MarkFail_D_PhyOneBlock() ---------------------------------------
|
/* ----- MarkFail_D_PhyOneBlock() --------------------------------------- */
|
||||||
int MarkFail_D_PhyOneBlock(struct us_data *us)
|
int MarkFail_D_PhyOneBlock(struct us_data *us)
|
||||||
{
|
{
|
||||||
BYTE sect;
|
BYTE sect;
|
||||||
@ -765,7 +766,7 @@ int MarkFail_D_PhyOneBlock(struct us_data *us)
|
|||||||
ErrCode = ERR_HwError;
|
ErrCode = ERR_HwError;
|
||||||
MediaChange = ERROR;
|
MediaChange = ERROR;
|
||||||
return ERROR;
|
return ERROR;
|
||||||
} // NO Status Check
|
} /* NO Status Check */
|
||||||
}
|
}
|
||||||
|
|
||||||
Ssfdc_D_Reset(us);
|
Ssfdc_D_Reset(us);
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
// Driver for USB Mass Storage compliant devices
|
/* Driver for USB Mass Storage compliant devices */
|
||||||
|
|
||||||
#ifndef _USB_H_
|
#ifndef _USB_H_
|
||||||
#define _USB_H_
|
#define _USB_H_
|
||||||
@ -26,19 +26,19 @@ struct us_unusual_dev {
|
|||||||
int (*initFunction)(struct us_data *);
|
int (*initFunction)(struct us_data *);
|
||||||
};
|
};
|
||||||
|
|
||||||
//EnE HW Register
|
/* EnE HW Register */
|
||||||
#define REG_CARD_STATUS 0xFF83
|
#define REG_CARD_STATUS 0xFF83
|
||||||
#define REG_HW_TRAP1 0xFF89
|
#define REG_HW_TRAP1 0xFF89
|
||||||
|
|
||||||
// SRB Status. Refers /usr/include/wine/wine/wnaspi32.h & SCSI sense key
|
/* SRB Status. Refers /usr/include/wine/wine/wnaspi32.h & SCSI sense key */
|
||||||
#define SS_SUCCESS 0x00 // No Sense
|
#define SS_SUCCESS 0x00 /* No Sense */
|
||||||
#define SS_NOT_READY 0x02
|
#define SS_NOT_READY 0x02
|
||||||
#define SS_MEDIUM_ERR 0x03
|
#define SS_MEDIUM_ERR 0x03
|
||||||
#define SS_HW_ERR 0x04
|
#define SS_HW_ERR 0x04
|
||||||
#define SS_ILLEGAL_REQUEST 0x05
|
#define SS_ILLEGAL_REQUEST 0x05
|
||||||
#define SS_UNIT_ATTENTION 0x06
|
#define SS_UNIT_ATTENTION 0x06
|
||||||
|
|
||||||
//ENE Load FW Pattern
|
/* ENE Load FW Pattern */
|
||||||
#define SD_INIT1_PATTERN 1
|
#define SD_INIT1_PATTERN 1
|
||||||
#define SD_INIT2_PATTERN 2
|
#define SD_INIT2_PATTERN 2
|
||||||
#define SD_RW_PATTERN 3
|
#define SD_RW_PATTERN 3
|
||||||
@ -82,8 +82,9 @@ typedef struct _SM_STATUS {
|
|||||||
BYTE IsMS:1;
|
BYTE IsMS:1;
|
||||||
} SM_STATUS, *PSM_STATUS;
|
} SM_STATUS, *PSM_STATUS;
|
||||||
|
|
||||||
// SD Block Length
|
/* SD Block Length */
|
||||||
#define SD_BLOCK_LEN 9 // 2^9 = 512 Bytes, The HW maximum read/write data length
|
#define SD_BLOCK_LEN 9 /* 2^9 = 512 Bytes,
|
||||||
|
The HW maximum read/write data length */
|
||||||
|
|
||||||
/* Dynamic bitflag definitions (us->dflags): used in set_bit() etc. */
|
/* Dynamic bitflag definitions (us->dflags): used in set_bit() etc. */
|
||||||
#define US_FLIDX_URB_ACTIVE 0 /* current_urb is in use */
|
#define US_FLIDX_URB_ACTIVE 0 /* current_urb is in use */
|
||||||
@ -176,19 +177,19 @@ struct us_data {
|
|||||||
#ifdef CONFIG_PM
|
#ifdef CONFIG_PM
|
||||||
pm_hook suspend_resume_hook;
|
pm_hook suspend_resume_hook;
|
||||||
#endif
|
#endif
|
||||||
// for 6250 code
|
/* for 6250 code */
|
||||||
SD_STATUS SD_Status;
|
SD_STATUS SD_Status;
|
||||||
MS_STATUS MS_Status;
|
MS_STATUS MS_Status;
|
||||||
SM_STATUS SM_Status;
|
SM_STATUS SM_Status;
|
||||||
|
|
||||||
//----- SD Control Data ----------------
|
/* ----- SD Control Data ---------------- */
|
||||||
//SD_REGISTER SD_Regs;
|
/* SD_REGISTER SD_Regs; */
|
||||||
WORD SD_Block_Mult;
|
WORD SD_Block_Mult;
|
||||||
BYTE SD_READ_BL_LEN;
|
BYTE SD_READ_BL_LEN;
|
||||||
WORD SD_C_SIZE;
|
WORD SD_C_SIZE;
|
||||||
BYTE SD_C_SIZE_MULT;
|
BYTE SD_C_SIZE_MULT;
|
||||||
|
|
||||||
// SD/MMC New spec.
|
/* SD/MMC New spec. */
|
||||||
BYTE SD_SPEC_VER;
|
BYTE SD_SPEC_VER;
|
||||||
BYTE SD_CSD_VER;
|
BYTE SD_CSD_VER;
|
||||||
BYTE SD20_HIGH_CAPACITY;
|
BYTE SD20_HIGH_CAPACITY;
|
||||||
@ -197,14 +198,14 @@ struct us_data {
|
|||||||
BYTE MMC_BusWidth;
|
BYTE MMC_BusWidth;
|
||||||
BYTE MMC_HIGH_CAPACITY;
|
BYTE MMC_HIGH_CAPACITY;
|
||||||
|
|
||||||
//----- MS Control Data ----------------
|
/* ----- MS Control Data ---------------- */
|
||||||
BOOLEAN MS_SWWP;
|
BOOLEAN MS_SWWP;
|
||||||
DWORD MSP_TotalBlock;
|
DWORD MSP_TotalBlock;
|
||||||
/* MS_LibControl MS_Lib; */
|
/* MS_LibControl MS_Lib; */
|
||||||
BOOLEAN MS_IsRWPage;
|
BOOLEAN MS_IsRWPage;
|
||||||
WORD MS_Model;
|
WORD MS_Model;
|
||||||
|
|
||||||
//----- SM Control Data ----------------
|
/* ----- SM Control Data ---------------- */
|
||||||
BYTE SM_DeviceID;
|
BYTE SM_DeviceID;
|
||||||
BYTE SM_CardID;
|
BYTE SM_CardID;
|
||||||
|
|
||||||
@ -213,7 +214,7 @@ struct us_data {
|
|||||||
DWORD bl_num;
|
DWORD bl_num;
|
||||||
int SrbStatus;
|
int SrbStatus;
|
||||||
|
|
||||||
//------Power Managerment ---------------
|
/* ------Power Managerment --------------- */
|
||||||
BOOLEAN Power_IsResum;
|
BOOLEAN Power_IsResum;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user