Age | Commit message (Collapse) | Author |
|
ok deraadt@
|
|
#ifdef _KERNEL
|
|
userland processes should not see all the kernel components.
|
|
ok krw@
|
|
commented out, remove it. Unifdef TFS while there.
ok marco@ krw@
|
|
set. SCSI_SILENT mediates printing error messages only.
|
|
days. if you really want it still you can fetch it via disklabel(8).
ok krw@ deraadt@
|
|
ok krw@ marco@ miod@ deraadt@
|
|
|
|
INQUIRY options don't spam dmesg during probe. Seen by miod@ and kettenis@
for SCSI CD's.
ok miod@
|
|
|
|
a vpd page that uniquely identifies a device no matter what bus topology or
addressing was used to find it.
we have a workaround for old school scsi devices that do not differentiate
between luns. if the inq data for high luns is the same as the inq data
for lun 0, we assume it is one of these buggy devices.
the problem with this is that things like SANs present multiple
volumes as luns and they all have the same inq data. if you wanted
to present more than one volume to openbsd you would only ever see
the first one.
devices give us a mechanism to differentiate between luns, so now
i do get all my volumes attached in openbsde.
review and feedback by krw@ marco@ testing by todd@
|
|
|
|
keeps it on the stack till we attach a driver to it. then it copies
the inquiry data int the scsi_link struct.
this diff uses the scsi_link struct instead of the stack for that data,
which makes the inq data for users of the scsi_link struct available much
earlier during device probe.
review and feedback from both krw@ and marco@
|
|
to all the scsi midlayer code into a local variable.
ok krw@ marco@
|
|
flagged SCSI_DATA_OUT) and data that has been returned (for commands
flagged SCSI_DATA_IN). This is better than just printing the data
buffer before the command is issued since that does not include any
data that has been read. e.g. INQUIRY data, as thib@ and I discovered.
ok marco@
|
|
Not sure what's more surprising: how long it took for NetBSD to
catch up to the rest of the BSDs (including UCB), or the amount of
code that NetBSD has claimed for itself without attributing to the
actual authors.
OK deraadt@
|
|
all defined to 4. Replace some magic number 4's with SCSI_RETRIES. Fix a
few lines that were now too long.
|
|
|
|
commands. Bump limit back to the standard 4, and at the same time eliminate
SDRETRIES and CDRETRIES (both defined to 4) in favour of a new define,
SCSI_RETRIES, also defined to 4.
|
|
instead. We do not make use of the PMI and RELADDR bits in the
READ CAPACITY command, and thus there is no difference between
cd and sd capacity handling. Brings cd and sd more into line,
shrinks code and makes things easier to understand.
Make types for blocksize and disksize consistant and MI.
Make cdopen() as silent as sdopen().
ok marco@
|
|
scsi_read_cap_data as READ_CD_CAPACITY, scsi_read_cd_capacity and
scsi_read_cd_cap_data respectively. No functional change as all were
identical to their counterparts.
|
|
SENSE_NOT_READY_BECOMING_READY sense errors. Some devices such as USB
Zip250 drives return the former when they mean the latter. Give the
first TEST UNIT READY command three times the usual retries so more
devices have time to get ready. This allows more removable devices to
detect media details and avoid issuing 'drive offline' messages.
ok marco@
|
|
RAW_PART will always be 0 -> disksize, so the bounds check will always
pass for i/o's to valid addresses. Now the i/o will be properly truncated
if it goes past the end of the device. This prevents various adverse
impacts of issuing i/o's for data past the end of the device.
Repeatedly requested by todd@.
ok weingart@ deraadt@
|
|
errors before issuing INQUIRY. Fixes Sony YE-Data floppy drive and
probably other devices at the cost of possibly breaking some 10 year
old CD-ROM drives. Un-special cases mvme68k which was forcing these
initial TURs.
Now wait for the inevitable weird USB device that breaks to surface.
ok marco@ deraadt@
|
|
debug output shows the xs/command before it's issued rather than
displaying it on command completion. Some commands don't come back
and it would be nice to see their details.
While here nuke invocations of scsi_show* in umass. If you want SCSI
debug output use SCSI debug options.
Only affects SCSI debug output.
ok marco@
|
|
|
|
1) remove multiple size queues, introduced as a stopgap.
2) decouple pages containing data from their mappings
3) only keep buffers mapped when they actually have to be mapped
(right now, this is when buffers are B_BUSY)
4) New functions to make a buffer busy, and release the busy flag
(buf_acquire and buf_release)
5) Move high/low water marks and statistics counters into a structure
6) Add a sysctl to retrieve buffer cache statistics
Tested in several variants and beat upon by bob and art for a year. run
accidentally on henning's nfs server for a few months...
ok deraadt@, krw@, art@ - who promises to be around to deal with any fallout
|
|
that may run without interrupts, don't forget to add scsi_autoconf
to the flags and POLL for the result rather than wait for an interrupt that
will never come. Fixes Dale's Iomega Jazz drive on the ahc here, and no
doubt many other device combinations.
|
|
device. Fallout from doing better PREVENT ALLOW dance.
Prodded by marco@ as a result of a report from Andreas Kahari on tech@.
|
|
trying to dma-map odd length data areas. No other alignment should be
required according to miod@. Makes my new SATA tape drive work.
ok deraadt@
|
|
|
|
problems.
ok krw@, marco@, deraadt@
|
|
blksize to 0 to avoid confusing garbage values with useful info.
Noticed by jolan@.
|
|
ok krw@
|
|
tape drives it is nice not to crash if one is detached. Basically use
a consistant mechanism modelled on sd to lookup devices and do the
device reference increments and decrements. Problem reported (PR#5811)
and fix tested by Jozef Hatala. Still some corner cases Jozef is
looking for but we'll fix those as discovered.
|
|
should fix a number of 'drive offline' situations where the device claims
it has no media loaded until the lock in occurs. Like a Blackberry Pearl
Todd Fries found and probably other USB devices. Move the lock in during
device open to before the test unit ready to eliminate similar spurious
rejections of the device.
Feedback from marco@, tests by todd@ and miod@.
ok deraadt@ beck@ dlg@ miod@
|
|
devices using 'sdopen'. PR#5810 from Jozef Hatala.
ok beck@
|
|
SCSI buses like atapiscsi. This more accurately describes the
commands that will be used on the device.
ok dlg@
|
|
|
|
geometry. But 63 * 255 > 2880 and the cylinder count becomes 0. So
if we end up with a valid disksize but 0 cylinders, set heads =
cylinders = 1 and sectors-per-track = disksize.
|
|
device before issuing scsi commands to it, but it was never implemented,
never used, and no hba actually filled them in. i came along and added
another two function pointers for the same thing.
this cleans up the extra pointers.
ok krw@ marco@ miod@ deraadt@
|
|
serial number and split the vpd header out for use in other places. while
here define the device identification page bits too.
ok krw@ marco@
|
|
sys/dev/pci/pciide.c from naddy@
|
|
the adapter to be notified when a device goes away so it can free any state
it maintains about that device.
ok deraadt@ marco@
|
|
"adapter_softc" is simply a way for the adapter to determine what scsibus
it is now dealing with, not a pointer back to the adapters device struct.
ok deraadt@ marco@
|
|
|
|
|
|
correct st_softc. Fixes 'mt rewoffl' panics, as reported on misc@ by
Jeff Ross and reproduced on my tape machine.
|
|
of pr 5635 confirms this works for him. similar diff authored by krw
who was unaware i wrote this and mailed it to Lucas...
|