--- /targets/ewp/LxNETES-3/u-boot_head/u-boot/include/fat.h 2004-04-23 22:32:07.000000000 +0200 +++ ./include/fat.h 2005-11-17 09:56:34.000000000 +0100 @@ -3,6 +3,7 @@ * * 2002-07-28 - rjones@nexus-tech.net - ported to ppcboot v1.1.6 * 2003-03-10 - kharris@nexus-tech.net - ported to u-boot + * 2005-11-15 - joachim_jaeger@digi.com - alignment bug fixed * * See file CREDITS for list of people who contributed to this * project. @@ -99,7 +100,8 @@ #define FAT2CPU16(x) (x) #define FAT2CPU32(x) (x) #else -#define FAT2CPU16(x) ((((x) & 0x00ff) << 8) | (((x) & 0xff00) >> 8)) +#define FAT2CPU16(x) ((((x) & 0x00ff) << 8) | \ + (((x) & 0xff00) >> 8)) #define FAT2CPU32(x) ((((x) & 0x000000ff) << 24) | \ (((x) & 0x0000ff00) << 8) | \ (((x) & 0x00ff0000) >> 8) | \ @@ -177,13 +179,13 @@ /* Private filesystem parameters */ typedef struct { + __u8 fatbuf[FATBUFSIZE]; /* Current FAT buffer, has to be 32bit aligned see FAT32 accesses */ int fatsize; /* Size of FAT in bits */ __u16 fatlength; /* Length of FAT in sectors */ __u16 fat_sect; /* Starting sector of the FAT */ __u16 rootdir_sect; /* Start sector of root directory */ __u16 clust_size; /* Size of clusters in sectors */ short data_begin; /* The sector of the first cluster, can be negative */ - __u8 fatbuf[FATBUFSIZE]; /* Current FAT buffer */ int fatbufnum; /* Used by get_fatent, init to -1 */ } fsdata;