From ffdf82e1a73fa4f679a44b961f1134602bb898aa Mon Sep 17 00:00:00 2001 From: Paul Saab Date: Wed, 14 Apr 2004 19:45:07 +0000 Subject: Don't allow the driver to be unloaded if the device node is open. --- sys/dev/ciss/ciss.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'sys/dev/ciss') diff --git a/sys/dev/ciss/ciss.c b/sys/dev/ciss/ciss.c index 0988b3415d4b..367d3ceccba3 100644 --- a/sys/dev/ciss/ciss.c +++ b/sys/dev/ciss/ciss.c @@ -428,7 +428,10 @@ ciss_detach(device_t dev) struct ciss_softc *sc = device_get_softc(dev); debug_called(1); - + + if (sc->ciss_flags & CISS_FLAG_CONTROL_OPEN) + return (EBUSY); + /* flush adapter cache */ ciss_flush_adapter(sc); -- cgit v1.3