Age | Commit message (Collapse) | Author |
|
called from the last sdclose() on a device will now reset SDF_DIRTY
after submitting the SYNCHRONIZE CACHE command. sddone() need not
worry about SDF_DIRTY since it was never called for the SYNCHRONIZE
CACHE command anyway.
This eliminates a spurious SYNCHRONIZE CACHE command being issued for
every sd device from sd_shutdown().
ok dlg@
|
|
and a file is written onto the stick. Without these fixes the
machine panics or hangs.
The usb fix calls the callback when the stick is pulled out to free
the associated buffers. Otherwise we have busy buffers for ever
and the automatic unmount will panic.
The change in the scsi layer prevents passing down further dirty
buffers to usb after the stick has been deactivated.
In vfs the automatic unmount has moved from the function vgonel()
to vop_generic_revoke(). Both are called when the sd device's vnode
is removed. In vgonel() the VXLOCK is already held which can cause
a deadlock. So call dounmount() earlier.
ok krw@, I like this marco@, tested by ian@
|
|
Tested, tweaked and ok otto@
|
|
using the new NO_CCB result. Currently a no-op since no driver produces
that result.
ok dlg@ marco@ deraadt@
|
|
ok miod@ marco@
|
|
copy of the vendor/product/revision fields in sd_softc. Just use the
INQUIRY data to build the disklabel 'label' when required. No
functional change.
|
|
scsi_link to determine device type, rather than keeping a copy in
sd_softc.type. Remove unused sd_softc.type field.
|
|
|
|
devices. Use READ CAPACITY like NetBSD, FreeBSD, Linux and OpenSolaris
do. Well, NetBSD keeps READ FORMAT CAPACITIES as a backup. Fixes
problems with devices (such as my IBM USB Memory Key) which return
block counts that are off by one for READ FORMAT CAPACITIES.
This eliminates the significant difference between sd_atapi.c and
sd_scsi.c so merge sd_scsi.c into sd.c and just be careful to mark
ATAPI removable devices as both SDEV_NOSYNCCACHE and unable to return
MODE SENSE page 4 info.
All geometry faking is now in one place. Where it can be 'improved'.
sd_scsi.c, sd_atapi.c and atapi_disk.h will be removed as a result.
|
|
|
|
|
|
|
|
More SCSI logic from NetBSD-current
Some tape fixes. ATAPI tapes do not work yet for most operations.
|