diff options
Diffstat (limited to 'firmware/drivers')
-rw-r--r-- | firmware/drivers/ata.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/firmware/drivers/ata.c b/firmware/drivers/ata.c index 4780cf5c0f..ff463e52d1 100644 --- a/firmware/drivers/ata.c +++ b/firmware/drivers/ata.c | |||
@@ -280,7 +280,7 @@ STATICIRAM ICODE_ATTR void copy_read_sectors(unsigned char* buf, int wordcount) | |||
280 | do | 280 | do |
281 | { | 281 | { |
282 | tmp = ATA_DATA; | 282 | tmp = ATA_DATA; |
283 | #if defined(SWAP_WORDS) || defined(ROCKBOX_LITTLE_ENDIAN) | 283 | #if defined(ATA_SWAP_WORDS) || defined(ROCKBOX_LITTLE_ENDIAN) |
284 | *buf++ = tmp & 0xff; /* I assume big endian */ | 284 | *buf++ = tmp & 0xff; /* I assume big endian */ |
285 | *buf++ = tmp >> 8; /* and don't use the SWAB16 macro */ | 285 | *buf++ = tmp >> 8; /* and don't use the SWAB16 macro */ |
286 | #else | 286 | #else |
@@ -295,7 +295,7 @@ STATICIRAM ICODE_ATTR void copy_read_sectors(unsigned char* buf, int wordcount) | |||
295 | unsigned short* wbufend = wbuf + wordcount; | 295 | unsigned short* wbufend = wbuf + wordcount; |
296 | do | 296 | do |
297 | { | 297 | { |
298 | #ifdef SWAP_WORDS | 298 | #ifdef ATA_SWAP_WORDS |
299 | *wbuf = swap16(ATA_DATA); | 299 | *wbuf = swap16(ATA_DATA); |
300 | #else | 300 | #else |
301 | *wbuf = ATA_DATA; | 301 | *wbuf = ATA_DATA; |
@@ -315,7 +315,7 @@ STATICIRAM ICODE_ATTR void copy_write_sectors(const unsigned char* buf, | |||
315 | const unsigned char* bufend = buf + wordcount*2; | 315 | const unsigned char* bufend = buf + wordcount*2; |
316 | do | 316 | do |
317 | { | 317 | { |
318 | #if defined(SWAP_WORDS) || defined(ROCKBOX_LITTLE_ENDIAN) | 318 | #if defined(ATA_SWAP_WORDS) || defined(ROCKBOX_LITTLE_ENDIAN) |
319 | tmp = (unsigned short) *buf++; | 319 | tmp = (unsigned short) *buf++; |
320 | tmp |= (unsigned short) *buf++ << 8; | 320 | tmp |= (unsigned short) *buf++ << 8; |
321 | SET_16BITREG(ATA_DATA, tmp); | 321 | SET_16BITREG(ATA_DATA, tmp); |
@@ -332,7 +332,7 @@ STATICIRAM ICODE_ATTR void copy_write_sectors(const unsigned char* buf, | |||
332 | unsigned short* wbufend = wbuf + wordcount; | 332 | unsigned short* wbufend = wbuf + wordcount; |
333 | do | 333 | do |
334 | { | 334 | { |
335 | #ifdef SWAP_WORDS | 335 | #ifdef ATA_SWAP_WORDS |
336 | SET_16BITREG(ATA_DATA, swap16(*wbuf)); | 336 | SET_16BITREG(ATA_DATA, swap16(*wbuf)); |
337 | #else | 337 | #else |
338 | SET_16BITREG(ATA_DATA, *wbuf); | 338 | SET_16BITREG(ATA_DATA, *wbuf); |
@@ -1127,7 +1127,7 @@ static int identify(void) | |||
1127 | for (i=0; i<SECTOR_SIZE/2; i++) { | 1127 | for (i=0; i<SECTOR_SIZE/2; i++) { |
1128 | /* the IDENTIFY words are already swapped, so we need to treat | 1128 | /* the IDENTIFY words are already swapped, so we need to treat |
1129 | this info differently that normal sector data */ | 1129 | this info differently that normal sector data */ |
1130 | #if defined(ROCKBOX_BIG_ENDIAN) && !defined(SWAP_WORDS) | 1130 | #if defined(ROCKBOX_BIG_ENDIAN) && !defined(ATA_SWAP_WORDS) |
1131 | identify_info[i] = swap16(ATA_DATA); | 1131 | identify_info[i] = swap16(ATA_DATA); |
1132 | #else | 1132 | #else |
1133 | identify_info[i] = ATA_DATA; | 1133 | identify_info[i] = ATA_DATA; |