diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2009-08-13 15:23:14 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2009-08-13 15:23:14 +0000 |
commit | cf6459c8f783ece5445be14e8e2e7201f7cd6632 (patch) | |
tree | a5a86e9615b432c0d3ef13f965013ddf06ea6bff /sys/arch/vax/vsa/hdc9224.c | |
parent | 46faf138ca97f0462a1c22674098875302fe10d0 (diff) |
Replace the error strings that were being passed around with much simpler
errnos. Note that the error strings are being ignored, since we long ago
decided to not spam the console, and there is no other nice way to use the
errors (without changing the ioctls to pass it back)
The errno is now useful, since we can pass b_error from failing IO up, and
the drive can decide how to use that
ok miod
Diffstat (limited to 'sys/arch/vax/vsa/hdc9224.c')
-rw-r--r-- | sys/arch/vax/vsa/hdc9224.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/sys/arch/vax/vsa/hdc9224.c b/sys/arch/vax/vsa/hdc9224.c index edf8a9078b2..10151a5eae3 100644 --- a/sys/arch/vax/vsa/hdc9224.c +++ b/sys/arch/vax/vsa/hdc9224.c @@ -1,4 +1,4 @@ -/* $OpenBSD: hdc9224.c,v 1.23 2009/06/04 21:38:10 miod Exp $ */ +/* $OpenBSD: hdc9224.c,v 1.24 2009/08/13 15:23:13 deraadt Exp $ */ /* $NetBSD: hdc9224.c,v 1.16 2001/07/26 15:05:09 wiz Exp $ */ /* * Copyright (c) 1996 Ludd, University of Lule}, Sweden. @@ -345,7 +345,7 @@ hdattach(struct device *parent, struct device *self, void *aux) struct hdsoftc *hd = (void*)self; struct hdc_attach_args *ha = aux; struct disklabel *dl; - char *msg; + int error; hd->sc_drive = ha->ha_drive; /* @@ -362,14 +362,11 @@ hdattach(struct device *parent, struct device *self, void *aux) disk_printtype(hd->sc_drive, hd->sc_xbn.media_id); dl = hd->sc_disk.dk_label; hdmakelabel(dl, &hd->sc_xbn); - msg = readdisklabel(MAKEDISKDEV(HDMAJOR, hd->sc_dev.dv_unit, RAW_PART), + error = readdisklabel(MAKEDISKDEV(HDMAJOR, hd->sc_dev.dv_unit, RAW_PART), hdstrategy, dl, 0); printf("%s: %luMB, %lu sectors\n", hd->sc_dev.dv_xname, DL_GETDSIZE(dl) / (1048576 / DEV_BSIZE), DL_GETDSIZE(dl)); - if (msg) { - /*printf("%s: %s\n", hd->sc_dev.dv_xname, msg);*/ - } #ifdef HDDEBUG hdc_printgeom(&hd->sc_xbn); #endif |