| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
| |
(cdcleanup,cdsysctlinit): Defend against calling sysctl_ctx_free on an
uninitialized sysctl_ctx.
Approved by: re (murray)
Notes:
svn path=/stable/4/; revision=121319
|
| |
|
|
|
|
|
|
|
|
| |
(dacleanup, dasysctlinit): Defend against calling sysctl_ctx_free on
an uninitialized sysctl_ctx.
Approved by: re (murray)
Notes:
svn path=/stable/4/; revision=121318
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
drivers out of cdregister() and daregister(), which are run from interrupt
context.
Files/revisions merged:
scsi_da.c: 1.157, 1.158
scsi_cd.c: 1.81
subr_taskqueue.c: 1.17
taskqueue.h: 1.8
cd.4: 1.33
da.4: 1.42
cd.9: 1.18
not merged: taskqueue.9 rev 1.7, 1.8 (not in RELENG_4)
This code is necessarily a little bit different than the version committed
to -current, mainly in the area of mutexes. (Which become splfoo() in
-stable.)
The sysctl code does blocking mallocs (M_WAITOK), which causes problems
if malloc(9) actually needs to sleep. (And causes a panic for people
running with INVARIANTS turned on.)
The eventual fix for this issue will involve moving the CAM probe process
inside a kernel thread. For now, though, I have fixed the issue by moving
dynamic sysctl variable creation for these two drivers to a task queue
running in a kernel thread.
The existing task queue in -stable (taskqueue_swi) runs in software interrupt
handlers, which wouldn't fix the problem at hand. So I have created a new
task queue, taskqueue_thread, that runs inside a kernel thread.
scsi_cd.c: Remove sysctl variable creation code from cdregister(), and
move it to a new function, cdsysctlinit(). Queue
cdsysctlinit() to the taskqueue_thread taskqueue once we
have fully registered the cd(4) driver instance.
scsi_da.c: Remove sysctl variable creation code from daregister(), and
move it to move it to a new function, dasysctlinit().
Queue dasysctlinit() to the taskqueue_thread taskqueue once
we have fully registered the da(4) instance.
taskqueue.h: Declare the new taskqueue_thread taskqueue, update some
comments.
subr_taskqueue.c:
Create the new kernel thread taskqueue.
cd.4: Update the cd(4) man page to talk about the minimum command
size sysctl/loader tunable. Also note that the changer
variables are available as loader tunables as well.
da.4: Update the da(4) man page to cover the retry_count,
default_timeout and minimum_cmd_size sysctl variables/loader
tunables. Remove references to /dev/r???, they aren't used
any longer.
cd.9: Update the cd(9) man page to describe the CD_Q_10_BYTE_ONLY
quirk.
Approved by: re (scottl, murray)
Notes:
svn path=/stable/4/; revision=119934
|
| |
|
|
|
|
|
|
|
|
|
| |
This is functionally a no-op. If you have 4G or more memory, most likely
you will still have problem with dumping since PCI device windows are
not currently excluded.
Approved by: re
Notes:
svn path=/stable/4/; revision=119598
|
| |
|
|
|
|
|
|
|
|
|
|
| |
are the same for -current and -stable.
Also, temporarily re-enable all USB floppy quirks for 4.9R. Although I
received no input whether or not these devices work without the quirks,
installs often depend on USB floppies and it is unacceptable for them to
be broken for a release. They will be disabled again after the release.
Notes:
svn path=/stable/4/; revision=119463
|
| |
|
|
|
|
|
| |
6-byte commands for umass(4) devices.
Notes:
svn path=/stable/4/; revision=119460
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=119457
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
fix a number of related problems along the way.
Files/revisions merged:
scsi_cd.c: 1.72, 1.77, 1.80
scsi_all.c: 1.39 (partial)
scsi_all.h: 1.22
scsi_cd.h: 1.7
scsi_da.c: 1.139
atapi-cam.c: 1.13
not merged: umass.c rev 1.76 (doesn't apply to -stable)
Because of the differences between -current and -stable, some of these
changes are not identical to the ones in -current.
Most notably, cd(4) in -stable uses the slice code, whereas cd(4) in
-current has no disklabel support at all. So there is extra code in the
-stable version of these patches to handle that.
- Automatically detect CDROM drives that can't handle 6 byte mode
sense and mode select, and adjust our command size accordingly.
We have to handle this in the cd(4) driver (where the buffers are
allocated), since the parameter list length is different for the
6 and 10 byte mode sense commands.
- Remove MODE_SENSE and MODE_SELECT translation in ATAPICAM, since
there's no way for that to work properly.
- Merge support for sending a path inquiry CCB to see if the SIM has set
the PIM_NO_6_BYTE flag. (scsi_cd.c rev 1.80)
- Add a quirk entry for CDROM drives that just hang when they get a 6
byte mode sense or mode select. The reason for the quirk must be
documented in a PR, and all quirks must be approved by
ken@FreeBSD.org. This is to make sure that we fully understand why
each quirk is needed. In most cases, the PIM_NO_6_BYTE flag set by the
SIM driver should eliminate the need for a quirk.
- Change the way the da(4) handles the no_6_byte sysctl. There is
now a per-drive sysctl to set the minimum command size for that
particular disk. (Since you could have multiple disks with
multiple requirements in one system.)
- Loader tunable support for all the sysctls in the da(4) and cd(4)
drivers.
- Add a CDIOCCLOSE ioctl for cd(4) (bde pointed this out a long
time ago).
- Add a media validation routine (cdcheckmedia()) to the cd(4)
driver, to fix some problems bde pointed out a long time ago. For
-stable, open() will still fail if there is no media in the drive. This
is because of issues with the slice code handling media changing
underneath it. If bde and I can get those issues worked out, there is
basic code in this set of patches to handle allowing the CDIOCCLOSE and
CDIOCEJECT ioctls without media in the drive.
- The media validation routine also reads the table of contents off
the drive. We use the table of contents to implement the
CDIOCPLAYTRACKS ioctl using the PLAY AUDIO MSF command. The
PLAY AUDIO TRACK INDEX command that we previously used was
deprecated after SCSI-2. It works in every SCSI CDROM I've tried,
but doesn't seem to work on ATAPI CDROM drives. We still use the
play audio track index command if we don't have a valid TOC, but
I suppose it'll fail anyway in that case.
- Add _len() versions of scsi_mode_sense() and scsi_mode_select() so
that we can specify the minimum command length.
Approved by: re
Notes:
svn path=/stable/4/; revision=119386
|
| |
|
|
|
|
|
|
|
|
| |
We do not need `\n' for panic().
cam/scsi/scsi_low.c: 1.15 -> 1.16
dev/ct/ct.c: 1.5 -> 1.6
Notes:
svn path=/stable/4/; revision=118690
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=118629
|
| |
|
|
|
|
|
|
|
|
| |
to such devices. If a device fails due to this commit, add:
options DA_OLD_QUIRKS
to the kernel config and recompile. Then send the output of "camcontrol
inquiry da0" to scsi@freebsd.org so the quirk can be re-enabled.
Notes:
svn path=/stable/4/; revision=118571
|
| |
|
|
|
|
|
|
|
|
| |
set this flag to indicate they do not wish to receive 6 byte commands.
The da(4) driver now honors this flag. Note that the cd(4) portion of the
commit is not MFCd now because it depends on other code which needs to be
MFCd first.
Notes:
svn path=/stable/4/; revision=118139
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=115112
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=114235
|
| |
|
|
|
|
|
| |
has been in -current for a while but was never MFCd.
Notes:
svn path=/stable/4/; revision=114127
|
| |
|
|
|
|
|
| |
Approved by: re (jhb)
Notes:
svn path=/stable/4/; revision=112221
|
| |
|
|
|
|
|
|
|
| |
different format than the one in -current but they have the same effect.
Approved by: re (jhb)
Notes:
svn path=/stable/4/; revision=112220
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=112023
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This code allows a user program to enable target mode on a SIM and
then emulate any number of devices (disks, tape drives, etc.) All
decisions about device behavior (UA, CA, inquiry response) are left
to the usermode program and the kernel driver is merely a conduit
for CCBs. This enables multiple concurrent target emulators, each
using its own backing store and IO model.
Also included is a user program that emulates a disk (RBC) using a
file as a backing store. This provides functionality similar to
md(4) at the CAM layer.
Approved by: re (scottl)
Notes:
svn path=/stable/4/; revision=111098
|
| |
|
|
|
|
|
|
| |
process or thread to change a mapping or resize a file. vmapbuf() Now
returns an error which callers check.
Notes:
svn path=/stable/4/; revision=109824
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=109604
|
| |
|
|
|
|
|
|
| |
Clear the "device open" flag and release the peripheral
if returning a error from daopen().
Notes:
svn path=/stable/4/; revision=108130
|
| |
|
|
|
|
|
|
|
|
|
|
| |
sizes. But for some reason the block size is different when a different
type of tape is placed in the drive. This commit fixes that.
PR: 46209
Submitted by: Alex Wang <alex@alexwang.com>
Approved by: mjacob
Notes:
svn path=/stable/4/; revision=107973
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Although the SCSI spec indicates that the "additional length field" of
the inquiry data is "n - 4", n is an index to the last byte of inquiry
data, not the length of data. For length calculations, use 5, not 4.
In xpt_set_transfer_settings, never attempt U320 transfer speeds if
the information transfer units capability is not supported by the device.
The SPI4 spec precludes running any PACED transfer speed without IUTs.
Reviewed by: scottl, ken
Notes:
svn path=/stable/4/; revision=107714
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=107222
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=107195
|
| |
|
|
|
|
|
| |
Pointed out by: bsd
Notes:
svn path=/stable/4/; revision=107097
|
| |
|
|
|
|
|
|
|
|
| |
* Add CDRIOC{READ,WRITE}SPEED ioctls to cd(4). Units are in KB/sec.
* Change atapi-cd ioctls to use the same units.
* Change burncd, cdcontrol to convert CDROM speed to KB/sec before
calling the ioctl. Add a "max" speed option for their command lines.
Notes:
svn path=/stable/4/; revision=107093
|
| |
|
|
|
|
|
| |
PR: kern/41010
Notes:
svn path=/stable/4/; revision=106787
|
| |
|
|
|
|
|
|
|
|
|
| |
PR: kern/43627
Submitted-By: Guido van Rooij <guido@mouse.gvr.org>
PR: kern/33638
PR: kern/43580
Submitted-By: Olexander Kunytsa <kunia@istc.kiev.ua>
Notes:
svn path=/stable/4/; revision=106239
|
| |
|
|
|
|
|
|
|
| |
Fix region code reporting.
Reported by: Andrew Gordon <arg@arg1.demon.co.uk>
Notes:
svn path=/stable/4/; revision=106021
|
| |
|
|
|
|
|
| |
Add support for Simplified Direct Access Device in scsi_op_desc().
Notes:
svn path=/stable/4/; revision=105613
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Fix the location of the length bytes in the 12-byte read/write CDB
structure. This has been broken since 1998, but probably hasn't been
noticed because it takes a read/write of 64K blocks (32MB with 512 byte
blocks) to trigger using the 12 byte read/write CDB in scsi_read_write().
Submitted by: emoore
Notes:
svn path=/stable/4/; revision=104935
|
| |
|
|
|
|
|
|
| |
Approved by: re
Prompted by: scottl/ken
Notes:
svn path=/stable/4/; revision=103789
|
| |
|
|
|
|
|
|
| |
example, a client registered to receive specific events for bus 0,
target *, lun *, was not receiving notifications.
Notes:
svn path=/stable/4/; revision=102636
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=102629
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=102628
|
| |
|
|
|
|
|
| |
Add \n to various printfs. grep shows these should be the last ones.
Notes:
svn path=/stable/4/; revision=102580
|
| |
|
|
|
|
|
|
|
|
|
| |
Updates to cmd6workaround:
* Only update cdb in place if not CDB_POINTER
* Correctly check for QFRZ before restarting CCB
* More accurate printf message
* style(9) changes at end
Notes:
svn path=/stable/4/; revision=102373
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=101203
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=98489
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=98297
|
| |
|
|
|
|
|
|
| |
PR: kern/38208
Approved by: re
Notes:
svn path=/stable/4/; revision=97514
|
| |
|
|
|
|
|
|
|
|
| |
reader. Note that even with the quirk entry the reader typically only
works if the USB device is recognized by UHCI instead of the generic
OHCI driver.
Approved by: re
Notes:
svn path=/stable/4/; revision=96960
|
| |
|
|
|
|
|
|
| |
PR: kern/38104
Approved by: re (brian)
Notes:
svn path=/stable/4/; revision=96684
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=95380
|
| |
|
|
|
|
|
|
|
|
|
| |
- Add support for Simplified Direct Access Device.
- Automatically detect devices that do not support READ(6)/WRITE(6).
scsi_all.c: rev. 1.29
scsi_da.c: rev. 1.98, 1.101
Notes:
svn path=/stable/4/; revision=94180
|
| |
|
|
|
|
|
|
|
| |
USB2 drive.
Submitted by: Brian Schellenberger <bts@babbleon.org>
Notes:
svn path=/stable/4/; revision=91106
|
| |
|
|
| |
Notes:
svn path=/stable/4/; revision=90173
|
| |
|
|
|
|
|
| |
Approved by: re
Notes:
svn path=/stable/4/; revision=89340
|