diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2011-06-19 04:55:35 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2011-06-19 04:55:35 +0000 |
commit | 3e3ad7757f379f859cf5f09cbb7aa83f78364b19 (patch) | |
tree | 295c545f0e41cbdb975ac2a060c71d9b5f07b0be /sys/arch/hp300/dev | |
parent | a809e4c7b624b56c125ce1320f4ad1bc5958112b (diff) |
Use disk_lock_nointr() in the xxclose() routines so that they cannot
be interrupted.
ok matthew
Diffstat (limited to 'sys/arch/hp300/dev')
-rw-r--r-- | sys/arch/hp300/dev/hd.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/sys/arch/hp300/dev/hd.c b/sys/arch/hp300/dev/hd.c index c742eb48971..b15bf3ddcf5 100644 --- a/sys/arch/hp300/dev/hd.c +++ b/sys/arch/hp300/dev/hd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: hd.c,v 1.66 2011/06/19 04:35:06 deraadt Exp $ */ +/* $OpenBSD: hd.c,v 1.67 2011/06/19 04:55:34 deraadt Exp $ */ /* $NetBSD: rd.c,v 1.33 1997/07/10 18:14:08 kleink Exp $ */ /* @@ -602,16 +602,12 @@ hdclose(dev, flag, mode, p) struct hd_softc *rs; struct disk *dk; int mask, s; - int error; rs = hdlookup(unit); if (rs == NULL) return (ENXIO); - if ((error = disk_lock(&rs->sc_dkdev)) != 0) { - device_unref(&rs->sc_dev); - return (error); - } + disk_lock_nointr(&rs->sc_dkdev); mask = 1 << DISKPART(dev); dk = &rs->sc_dkdev; |