Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 26 Jan 1996 23:06:37 +0100 (MET)
From:      J Wunsch <j@uriah.heep.sax.de>
To:        freebsd-scsi@freebsd.org
Subject:   Problem with SDEV_ONCE_ONLY devices
Message-ID:  <199601262206.XAA20513@uriah.heep.sax.de>

next in thread | raw e-mail | index | archive | help
While playing with the new worm driver (it's already getting into a
better shape!), i noticed the following annoying bug several times.

It becomes especially apparent for devices that have the
SDEV_ONCE_ONLY flag set, as the worm driver has.

The device is being opened normally, but for one or the other reason,
a SCSI error occurs.  Either by playing with the control device and
scsi(8), or in my case today, by some buggy code inside the driver.

Anyway, after this happens, it seems that the function scsi_close() is
never actually being called, so the SDEV_IS_OPEN flag is never reset.
Any subsequent attempts to open the device end up in an EBUSY.

Clearing the flag using DDB or kgdb cures the problem, so it's defin-
ately the SDEV_IS_OPEN flag.  I have no idea why scsi_close() is not
called however.

-- 
cheers, J"org

joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199601262206.XAA20513>