summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>1995-05-21 03:27:13 +0000
committerphk <phk@FreeBSD.org>1995-05-21 03:27:13 +0000
commit5edfd32aaa977c96870f006abc1b4d2cafa094f1 (patch)
tree5740eec0f59d5c9283576cefe52cc67d4d178f4f /sys
parentbba1428e2f8f96fb77f4e38ec7f30959e9450421 (diff)
downloadFreeBSD-src-5edfd32aaa977c96870f006abc1b4d2cafa094f1.zip
FreeBSD-src-5edfd32aaa977c96870f006abc1b4d2cafa094f1.tar.gz
Now I could finally test this change: bad144 is now relative to the
partition.
Diffstat (limited to 'sys')
-rw-r--r--sys/i386/boot/biosboot/disk.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/i386/boot/biosboot/disk.c b/sys/i386/boot/biosboot/disk.c
index b8e2b6e..5e858e2 100644
--- a/sys/i386/boot/biosboot/disk.c
+++ b/sys/i386/boot/biosboot/disk.c
@@ -24,7 +24,7 @@
* the rights to redistribute these changes.
*
* from: Mach, Revision 2.2 92/04/04 11:35:49 rpd
- * $Id: disk.c,v 1.10 1995/05/08 02:02:56 phk Exp $
+ * $Id: disk.c,v 1.11 1995/05/11 16:19:50 phk Exp $
*/
/*
@@ -256,9 +256,9 @@ badsect(int dosdev, int sector)
goto no_remap;
}
- cyl = sector / dl->d_secpercyl;
- head = (sector % dl->d_secpercyl) / dl->d_nsectors;
- sec = sector % dl->d_nsectors;
+ cyl = (sector-boff) / dl->d_secpercyl;
+ head = ((sector-boff) % dl->d_secpercyl) / dl->d_nsectors;
+ sec = (sector-boff) % dl->d_nsectors;
sec = (head<<8) + sec;
/* now, look in the table for a possible bad sector */
OpenPOWER on IntegriCloud