freebsd-nq/sys/dev/usb
Kenneth D. Merry 56eac725a3 Fix ATAPI/USB/Firewire CDROM drive handling in cd(4) and hopefully fix
a number of related problems along the way.

 - 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 removed in ATAPICAM
   and in the umass(4) driver, since there's no way for that to work
   properly.

 - 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.  Once the CAM_NEW_TRAN_CODE is finished, we
   should be able to remove any such quirks, since we'll know what
   protocol the drive speaks (SCSI, ATAPI, etc.) and therefore whether
   we should use 6 or 10 byte mode sense/select commands.

 - 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.  We
   now allow open() to succeed no matter what, but if we don't detect
   valid media, the user can only issue CDIOCCLOSE or CDIOCEJECT
   ioctls.

 - 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.

 - Fix a couple of formatting problems in the sense printing code.

MFC after: 	4 weeks
2003-02-21 06:19:38 +00:00
..
devlist2h.awk constify 2002-04-01 19:22:04 +00:00
dsbr100io.h Support for USB fm radio. 2002-03-04 03:51:21 +00:00
FILES Support for USB fm radio. 2002-03-04 03:51:21 +00:00
hid.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
hid.h Use ANSI prototypes and declarations. 2002-04-01 19:01:09 +00:00
if_aue.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
if_auereg.h network interface driver changes: 2002-11-14 23:54:55 +00:00
if_cue.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
if_cuereg.h network interface driver changes: 2002-11-14 23:54:55 +00:00
if_kue.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
if_kuereg.h network interface driver changes: 2002-11-14 23:54:55 +00:00
kue_fw.h
Makefile.usbdevs
ohci_pci.c Use uhci_pci_match to return the device description and rework the 2002-08-18 11:52:47 +00:00
ohci.c Fix two bugs in the DMA chaining code for OHCI. The first bug is that 2002-12-20 18:47:39 +00:00
ohcireg.h Merge from NetBSD: 2002-04-01 13:21:43 +00:00
ohcivar.h In rev 1.51 of usb_port.h I switched over to using the USB_USE_SOFTINTR 2002-09-30 17:50:18 +00:00
rio500_usb.h
ubsa.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
ucom.c Fix a typo in a console message. 2002-11-17 13:33:55 +00:00
ucomvar.h Replace the FOO_DEBUG definitions with USB_DEBUG, and switch the 2002-07-31 14:34:36 +00:00
udbp.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
udbp.h Should have been part of recent commit: 2002-06-01 07:18:32 +00:00
ufm.c There's no need for a locally defined usb_proc_t when we've got 2002-11-06 14:29:27 +00:00
uftdi.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
uftdireg.h Add the uftdi ucom driver which supports the following adapters: 2002-08-11 23:32:33 +00:00
ugen.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
ugraphire_rdesc.h MFNetBSD: uhid.c (1.42 & 1.43), ugraphire_rdesc.h (1.1) 2002-04-07 17:04:01 +00:00
uhci_pci.c Add a device description for Intel 82801CA/CAM (ICH3) USB controller 2002-08-28 20:24:49 +00:00
uhci.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
uhcireg.h MFNetBSD: uhcireg.h (1.15), uhcivar.h (1.33) 2002-04-07 18:06:34 +00:00
uhcivar.h In rev 1.51 of usb_port.h I switched over to using the USB_USE_SOFTINTR 2002-09-30 17:50:18 +00:00
uhid.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
uhub.c Use the hw.usb sysctl tree instead of debug.usb. 2002-08-08 12:05:51 +00:00
ukbd.c Replace various spelling with FALLTHROUGH which is lint()able 2002-08-25 13:23:09 +00:00
ulpt.c Correct typos, mostly s/ a / an / where appropriate. Some whitespace cleanup, 2003-01-01 18:49:04 +00:00
umass.c Fix ATAPI/USB/Firewire CDROM drive handling in cd(4) and hopefully fix 2003-02-21 06:19:38 +00:00
umodem.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
ums.c Use the hw.usb sysctl tree instead of debug.usb. 2002-08-08 12:05:51 +00:00
uplcom.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
urio.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
usb_ethersubr.c network interface driver changes: 2002-11-14 23:54:55 +00:00
usb_ethersubr.h Remove __P. 2002-03-20 02:08:01 +00:00
usb_if.m
usb_mem.h NetBSD have adopted our usage of the DMAADDR macro: 2002-05-28 20:51:43 +00:00
usb_port.h Some kernel threads try to do significant work, and the default KSTACK_PAGES 2002-10-02 07:44:29 +00:00
usb_quirks.c Add support YAMAHA NetVolante Routers 2003-02-12 13:20:39 +00:00
usb_quirks.h
usb_subr.c Some USB devices are not prepared to deal with a single byte string 2003-01-14 23:07:43 +00:00
usb.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
usb.h Packed structures are defined differently in older gcc's, like the one 2002-11-06 21:37:21 +00:00
usbcdc.h Merge from NetBSD and arrange for FreeBSD's slight differences in 2003-01-09 04:24:28 +00:00
usbdevs Add support SUNTAC Ir-Trinity IS96U 2003-02-13 12:55:18 +00:00
usbdevs_data.h Sync to 1.114 of usbdevs 2003-02-13 12:57:24 +00:00
usbdevs.h Sync to 1.114 of usbdevs 2003-02-13 12:57:24 +00:00
usbdi_util.c Replace (ab)uses of "NULL" where "0" is really meant. 2002-08-22 21:24:01 +00:00
usbdi_util.h MFNetBSD: uhid.c (1.45), ums.c (1.49), usbdi_util.c (1.35), usbdi_util.h (1.23) 2002-04-07 17:13:00 +00:00
usbdi.c MFNetBSD: ohci.c (1.124), uhci.c (1.159), usbdi.c (1.100) 2002-05-26 22:00:06 +00:00
usbdi.h MFNetBSD: ugen.c (1.57), ulpt.c (1.48), usb.c (1.67), usbdi.c (1.96), 2002-05-06 18:23:36 +00:00
usbdivar.h Synchronise the code style with NetBSD. (No functional changes). 2002-04-07 13:37:46 +00:00
usbhid.h
uscanner.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
uvisor.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00
uvscom.c Back out M_* changes, per decision of the TRB. 2003-02-19 05:47:46 +00:00