return USB_STOR_TRANSPORT_ERROR;
}
- us->SM_Status = *(PSM_STATUS)&buf[0];
+ us->SM_Status = *(struct keucr_sm_status *)&buf[0];
us->SM_DeviceID = buf[1];
us->SM_CardID = buf[2];
/***************************************************************************
Struct Definition
***************************************************************************/
-struct SSFDCTYPE {
+struct keucr_media_info {
BYTE Model;
BYTE Attribute;
BYTE MaxZones;
WORD MaxLogBlocks;
};
-typedef struct SSFDCTYPE_T {
- BYTE Model;
- BYTE Attribute;
- BYTE MaxZones;
- BYTE MaxSectors;
- WORD MaxBlocks;
- WORD MaxLogBlocks;
-} *SSFDCTYPE_T;
-
-struct ADDRESS {
+struct keucr_media_address {
BYTE Zone; /* Zone Number */
BYTE Sector; /* Sector(512byte) Number on Block */
WORD PhyBlock; /* Physical Block Number on Zone */
WORD LogBlock; /* Logical Block Number of Zone */
};
-typedef struct ADDRESS_T {
- BYTE Zone; /* Zone Number */
- BYTE Sector; /* Sector(512byte) Number on Block */
- WORD PhyBlock; /* Physical Block Number on Zone */
- WORD LogBlock; /* Logical Block Number of Zone */
-} *ADDRESS_T;
-
-struct CIS_AREA {
+struct keucr_media_area {
BYTE Sector; /* Sector(512byte) Number on Block */
WORD PhyBlock; /* Physical Block Number on Zone 0 */
};
extern WORD WriteBlock;
extern DWORD MediaChange;
-extern struct SSFDCTYPE Ssfdc;
-extern struct ADDRESS Media;
-extern struct CIS_AREA CisArea;
+extern struct keucr_media_info Ssfdc;
+extern struct keucr_media_address Media;
+extern struct keucr_media_area CisArea;
/*
* SMILMain.c
void _Calc_D_ECCdata(BYTE *);
-struct SSFDCTYPE Ssfdc;
-struct ADDRESS Media;
-struct CIS_AREA CisArea;
+struct keucr_media_info Ssfdc;
+struct keucr_media_address Media;
+struct keucr_media_area CisArea;
static BYTE EccBuf[6];
extern PBYTE SMHostAddr;
us->Power_IsResum = true;
- us->SM_Status = *(PSM_STATUS)&tmp;
+ us->SM_Status = *(struct keucr_sm_status *)&tmp;
return 0;
}
us->Power_IsResum = true;
- us->SM_Status = *(PSM_STATUS)&tmp;
+ us->SM_Status = *(struct keucr_sm_status *)&tmp;
return 0;
}
#define FDIR_WRITE 0
#define FDIR_READ 1
-typedef struct _SD_STATUS {
+struct keucr_sd_status {
BYTE Insert:1;
BYTE Ready:1;
BYTE MediaChange:1;
BYTE HiSpeed:1;
BYTE WtP:1;
BYTE Reserved:1;
-} SD_STATUS, *PSD_STATUS;
+};
-typedef struct _MS_STATUS {
+struct keucr_ms_status {
BYTE Insert:1;
BYTE Ready:1;
BYTE MediaChange:1;
BYTE Reserved1:1;
BYTE WtP:1;
BYTE Reserved2:1;
-} MS_STATUS, *PMS_STATUS;
+};
-typedef struct _SM_STATUS {
+struct keucr_sm_status {
BYTE Insert:1;
BYTE Ready:1;
BYTE MediaChange:1;
BYTE Reserved:3;
BYTE WtP:1;
BYTE IsMS:1;
-} SM_STATUS, *PSM_STATUS;
+};
/* SD Block Length */
#define SD_BLOCK_LEN 9 /* 2^9 = 512 Bytes,
pm_hook suspend_resume_hook;
#endif
/* for 6250 code */
- SD_STATUS SD_Status;
- MS_STATUS MS_Status;
- SM_STATUS SM_Status;
+ struct keucr_sd_status SD_Status;
+ struct keucr_ms_status MS_Status;
+ struct keucr_sm_status SM_Status;
/* ----- SD Control Data ---------------- */
/* SD_REGISTER SD_Regs; */