summaryrefslogtreecommitdiff
path: root/sys/dev/ata/wd.c
diff options
context:
space:
mode:
authorKenneth R Westerback <krw@cvs.openbsd.org>2007-04-26 22:42:12 +0000
committerKenneth R Westerback <krw@cvs.openbsd.org>2007-04-26 22:42:12 +0000
commit3fc1bf5f90c5862ead9339c149d7d7bc5610508b (patch)
treee79d154b8b1d5e2511a92821e548781c7615c4e3 /sys/dev/ata/wd.c
parent55ac11543f25dab487e3ffdeff6cc00e34df6c55 (diff)
Eliminate CPU_BIOS from userland and wd(4) by always using the BIOS
geometry in the disklabel when there is a BIOS geometry to provide. This removes the option to set a disklabel to 'BIOS' geometry via the 'g b' command in the editor. Makes reported geometry more consistant and moves MD code to MD land where it should be. Doc help from jmc@, Feedback from millert@, marco@, weingart@, kettenis@. ok deraadt@
Diffstat (limited to 'sys/dev/ata/wd.c')
-rw-r--r--sys/dev/ata/wd.c12
1 files changed, 1 insertions, 11 deletions
diff --git a/sys/dev/ata/wd.c b/sys/dev/ata/wd.c
index a903463c0b3..538f097bba2 100644
--- a/sys/dev/ata/wd.c
+++ b/sys/dev/ata/wd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: wd.c,v 1.55 2007/03/27 23:32:55 deraadt Exp $ */
+/* $OpenBSD: wd.c,v 1.56 2007/04/26 22:42:11 krw Exp $ */
/* $NetBSD: wd.c,v 1.193 1999/02/28 17:15:27 explorer Exp $ */
/*
@@ -788,17 +788,7 @@ wdgetdefaultlabel(struct wd_softc *wd, struct disklabel *lp)
lp->d_ntracks = wd->sc_params.atap_heads;
lp->d_nsectors = wd->sc_params.atap_sectors;
lp->d_secpercyl = lp->d_ntracks * lp->d_nsectors;
-#ifdef CPU_BIOS
- /*
- * Stick to what the controller says for BIOS compatibility. Let the
- * CPU_BIOS logic on i386 and friends deal with any mismatch to actual
- * size.
- */
- lp->d_ncylinders = wd->sc_params.atap_cylinders;
-#else
- /* We are not constrained by BIOS concerns. Calculate cylinder count. */
lp->d_ncylinders = lp->d_secperunit / lp->d_secpercyl;
-#endif
if (wd->drvp->ata_vers == -1) {
lp->d_type = DTYPE_ST506;
strncpy(lp->d_typename, "ST506/MFM/RLL", sizeof lp->d_typename);