summaryrefslogtreecommitdiff
path: root/common/cmd_ide.c
diff options
context:
space:
mode:
authorGreg Lopp <lopp@pobox.com>2007-04-13 08:02:24 +0200
committerStefan Roese <sr@denx.de>2007-04-13 08:02:24 +0200
commit0b94504d22e70f537c17a0d38c87edb6e370977d (patch)
tree591809e3746bdf75832b3865f36a11e791b98c98 /common/cmd_ide.c
parent2ad3aba01d37b72e7c957b07e102fccd64fe6d13 (diff)
[PATCH] Fix use of "void *" for block dev read/write buffer pointers
Signed-of-by: Greg Lopp <lopp@pobox.com> Acked-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'common/cmd_ide.c')
-rw-r--r--common/cmd_ide.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/common/cmd_ide.c b/common/cmd_ide.c
index b4119f30725..28797a920c5 100644
--- a/common/cmd_ide.c
+++ b/common/cmd_ide.c
@@ -1344,7 +1344,7 @@ ulong ide_read (int device, lbaint_t blknr, ulong blkcnt, void *buffer)
++n;
++blknr;
- buffer += ATA_SECTORWORDS;
+ buffer += ATA_BLOCKSIZE;
}
IDE_READ_E:
ide_led (DEVICE_LED(device), 0); /* LED off */
@@ -1428,7 +1428,7 @@ ulong ide_write (int device, lbaint_t blknr, ulong blkcnt, void *buffer)
c = ide_inb (device, ATA_STATUS); /* clear IRQ */
++n;
++blknr;
- buffer += ATA_SECTORWORDS;
+ buffer += ATA_BLOCKSIZE;
}
WR_OUT:
ide_led (DEVICE_LED(device), 0); /* LED off */
@@ -2052,7 +2052,7 @@ ulong atapi_read (int device, lbaint_t blknr, ulong blkcnt, void *buffer)
n+=cnt;
blkcnt-=cnt;
blknr+=cnt;
- buffer+=cnt*(ATAPI_READ_BLOCK_SIZE/4); /* ulong blocksize in ulong */
+ buffer+=(cnt*ATAPI_READ_BLOCK_SIZE);
} while (blkcnt > 0);
return (n);
}