Author: oxygene
Date: 2009-03-12 18:01:54 +0100 (Thu, 12 Mar 2009)
New Revision: 88
Modified:
trunk/filo/drivers/ide_new.c
Log:
Handle 2048 byte sectors somewhat. It assumes that the filesystem
also uses 2048 byte sectors and recalculates sector numbers based
on 512b sectors (ie. sector number * 4).
Prints a warning if assumption is wrong
Modified: trunk/filo/drivers/ide_new.c
===================================================================
--- trunk/filo/drivers/ide_new.c 2009-03-12 17:00:30 UTC (rev 87)
+++ trunk/filo/drivers/ide_new.c 2009-03-12 17:01:54 UTC (rev 88)
@@ -681,6 +681,14 @@
if (ob_ide_atapi_drive_ready(drive))
return 1;
+ if (drive->bs == 2048) {
+ if ((block & 3 != 0) || (sectors & 3 != 0)) {
+ printf("ob_ide_read_atapi: unaligned atapi access: %x
blocks, starting from %x\n", sectors, block);
+ }
+ block >>= 2;
+ sectors >>= 2;
+ }
+
memset(cmd, 0, sizeof(*cmd));
/*
--
coreboot mailing list: [email protected]
http://www.coreboot.org/mailman/listinfo/coreboot