Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions | Variables
smilmain.c File Reference
#include <linux/slab.h>
#include "usb.h"
#include "scsiglue.h"
#include "smcommon.h"
#include "smil.h"

Go to the source code of this file.

Macros

#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 Chk_D_Bit(a, b)   (a[(BYTE)((b)/8)] & BitData[(b)%8])
 

Functions

int Check_D_LogCHS (WORD *, BYTE *, BYTE *)
 
void Initialize_D_Media (void)
 
void PowerOff_D_Media (void)
 
int Check_D_MediaPower (void)
 
int Check_D_MediaExist (void)
 
int Check_D_MediaWP (void)
 
int Check_D_MediaFmt (struct us_data *)
 
int Check_D_MediaFmtForEraseAll (struct us_data *)
 
int Conv_D_MediaAddr (struct us_data *, DWORD)
 
int Inc_D_MediaAddr (struct us_data *)
 
int Check_D_FirstSect (void)
 
int Check_D_LastSect (void)
 
int Media_D_ReadOneSect (struct us_data *, WORD, BYTE *)
 
int Media_D_WriteOneSect (struct us_data *, WORD, BYTE *)
 
int Media_D_CopyBlockHead (struct us_data *)
 
int Media_D_CopyBlockTail (struct us_data *)
 
int Media_D_EraseOneBlock (void)
 
int Media_D_EraseAllBlock (void)
 
int Copy_D_BlockAll (struct us_data *, DWORD)
 
int Copy_D_BlockHead (struct us_data *)
 
int Copy_D_BlockTail (struct us_data *)
 
int Reassign_D_BlockHead (struct us_data *)
 
int Assign_D_WriteBlock (void)
 
int Release_D_ReadBlock (struct us_data *)
 
int Release_D_WriteBlock (struct us_data *)
 
int Release_D_CopySector (struct us_data *)
 
int Copy_D_PhyOneSect (struct us_data *)
 
int Read_D_PhyOneSect (struct us_data *, WORD, BYTE *)
 
int Write_D_PhyOneSect (struct us_data *, WORD, BYTE *)
 
int Erase_D_PhyOneBlock (struct us_data *)
 
int Set_D_PhyFmtValue (struct us_data *)
 
int Search_D_CIS (struct us_data *)
 
int Make_D_LogTable (struct us_data *)
 
void Check_D_BlockIsFull (void)
 
int MarkFail_D_PhyOneBlock (struct us_data *)
 
int SM_FreeMem (void)
 
int Media_D_ReadSector (struct us_data *us, DWORD start, WORD count, BYTE *buf)
 
int Media_D_CopySector (struct us_data *us, DWORD start, WORD count, BYTE *buf)
 

Variables

DWORD ErrXDCode
 
DWORD ErrCode
 
WORD ReadBlock
 
WORD WriteBlock
 
DWORD MediaChange
 
BYTE IsSSFDCCompliance
 
BYTE IsXDCompliance
 

Macro Definition Documentation

#define Chk_D_Bit (   a,
  b 
)    (a[(BYTE)((b)/8)] & BitData[(b)%8])

Definition at line 67 of file smilmain.c.

#define Clr_D_Bit (   a,
  b 
)    (a[(BYTE)((b)/8)]&=~BitData[(b)%8])

Definition at line 66 of file smilmain.c.

#define Set_D_Bit (   a,
  b 
)    (a[(BYTE)((b)/8)]|= BitData[(b)%8])

Definition at line 65 of file smilmain.c.

Function Documentation

int Assign_D_WriteBlock ( void  )

Definition at line 1230 of file smilmain.c.

void Check_D_BlockIsFull ( void  )
int Check_D_FirstSect ( void  )
int Check_D_LastSect ( void  )
int Check_D_LogCHS ( WORD ,
BYTE ,
BYTE  
)
int Check_D_MediaExist ( void  )
int Check_D_MediaFmt ( struct us_data us)

Definition at line 654 of file smilmain.c.

int Check_D_MediaFmtForEraseAll ( struct us_data )
int Check_D_MediaPower ( void  )
int Check_D_MediaWP ( void  )
int Conv_D_MediaAddr ( struct us_data us,
DWORD  addr 
)

Definition at line 739 of file smilmain.c.

int Copy_D_BlockAll ( struct us_data us,
DWORD  mode 
)

Definition at line 1080 of file smilmain.c.

int Copy_D_BlockHead ( struct us_data )
int Copy_D_BlockTail ( struct us_data )
int Copy_D_PhyOneSect ( struct us_data us)

Definition at line 1326 of file smilmain.c.

int Erase_D_PhyOneBlock ( struct us_data us)

Definition at line 1449 of file smilmain.c.

int Inc_D_MediaAddr ( struct us_data us)

Definition at line 774 of file smilmain.c.

void Initialize_D_Media ( void  )
int Make_D_LogTable ( struct us_data us)

Definition at line 1610 of file smilmain.c.

int MarkFail_D_PhyOneBlock ( struct us_data us)

Definition at line 1740 of file smilmain.c.

int Media_D_CopyBlockHead ( struct us_data )
int Media_D_CopyBlockTail ( struct us_data )
int Media_D_CopySector ( struct us_data us,
DWORD  start,
WORD  count,
BYTE buf 
)

Definition at line 189 of file smilmain.c.

int Media_D_EraseAllBlock ( void  )
int Media_D_EraseOneBlock ( void  )
int Media_D_ReadOneSect ( struct us_data us,
WORD  count,
BYTE buf 
)

Definition at line 856 of file smilmain.c.

int Media_D_ReadSector ( struct us_data us,
DWORD  start,
WORD  count,
BYTE buf 
)

Definition at line 147 of file smilmain.c.

int Media_D_WriteOneSect ( struct us_data ,
WORD  ,
BYTE  
)
void PowerOff_D_Media ( void  )
int Read_D_PhyOneSect ( struct us_data us,
WORD  count,
BYTE buf 
)

Definition at line 1390 of file smilmain.c.

int Reassign_D_BlockHead ( struct us_data )
int Release_D_CopySector ( struct us_data us)

Definition at line 244 of file smilmain.c.

int Release_D_ReadBlock ( struct us_data us)

Definition at line 1271 of file smilmain.c.

int Release_D_WriteBlock ( struct us_data us)

Definition at line 1310 of file smilmain.c.

int Search_D_CIS ( struct us_data us)

Definition at line 1547 of file smilmain.c.

int Set_D_PhyFmtValue ( struct us_data us)

Definition at line 1464 of file smilmain.c.

int SM_FreeMem ( void  )

Definition at line 97 of file smilmain.c.

int Write_D_PhyOneSect ( struct us_data ,
WORD  ,
BYTE  
)

Variable Documentation

DWORD ErrCode

Definition at line 49 of file smilmain.c.

DWORD ErrXDCode

Definition at line 48 of file smilmain.c.

BYTE IsSSFDCCompliance

Definition at line 70 of file smilmain.c.

BYTE IsXDCompliance

Definition at line 71 of file smilmain.c.

DWORD MediaChange

Definition at line 60 of file smilmain.c.

WORD ReadBlock

Definition at line 58 of file smilmain.c.

WORD WriteBlock

Definition at line 59 of file smilmain.c.