diff options
Diffstat (limited to 'firmware/drivers')
-rw-r--r-- | firmware/drivers/ata.c | 4 | ||||
-rw-r--r-- | firmware/drivers/fat.c | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/firmware/drivers/ata.c b/firmware/drivers/ata.c index 20e6247fb9..0983fb52ee 100644 --- a/firmware/drivers/ata.c +++ b/firmware/drivers/ata.c | |||
@@ -287,7 +287,7 @@ static void copy_read_sectors(unsigned char* buf, int wordcount) | |||
287 | #ifdef PREFER_C_READING | 287 | #ifdef PREFER_C_READING |
288 | unsigned short tmp = 0; | 288 | unsigned short tmp = 0; |
289 | 289 | ||
290 | if ( (unsigned int)buf & 1) | 290 | if ( (unsigned long)buf & 1) |
291 | { /* not 16-bit aligned, copy byte by byte */ | 291 | { /* not 16-bit aligned, copy byte by byte */ |
292 | unsigned char* bufend = buf + wordcount*2; | 292 | unsigned char* bufend = buf + wordcount*2; |
293 | do | 293 | do |
@@ -567,7 +567,7 @@ static void copy_write_sectors(const unsigned char* buf, int wordcount) | |||
567 | { | 567 | { |
568 | #ifdef PREFER_C_WRITING | 568 | #ifdef PREFER_C_WRITING |
569 | 569 | ||
570 | if ( (unsigned int)buf & 1) | 570 | if ( (unsigned long)buf & 1) |
571 | { /* not 16-bit aligned, copy byte by byte */ | 571 | { /* not 16-bit aligned, copy byte by byte */ |
572 | unsigned short tmp = 0; | 572 | unsigned short tmp = 0; |
573 | const unsigned char* bufend = buf + wordcount*2; | 573 | const unsigned char* bufend = buf + wordcount*2; |
diff --git a/firmware/drivers/fat.c b/firmware/drivers/fat.c index 4c63498b8c..3adca5e864 100644 --- a/firmware/drivers/fat.c +++ b/firmware/drivers/fat.c | |||
@@ -199,7 +199,7 @@ struct bpb | |||
199 | int bpb_fatsz16; /* Number of used sectors per FAT structure */ | 199 | int bpb_fatsz16; /* Number of used sectors per FAT structure */ |
200 | unsigned long bpb_totsec32; /* Number of sectors on the volume | 200 | unsigned long bpb_totsec32; /* Number of sectors on the volume |
201 | (new 32-bit) */ | 201 | (new 32-bit) */ |
202 | int last_word; /* 0xAA55 */ | 202 | unsigned int last_word; /* 0xAA55 */ |
203 | 203 | ||
204 | /**** FAT32 specific *****/ | 204 | /**** FAT32 specific *****/ |
205 | long bpb_fatsz32; | 205 | long bpb_fatsz32; |