From nobody@FreeBSD.org Thu Sep 22 16:28:25 2011 Return-Path: Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5B11E106566B for ; Thu, 22 Sep 2011 16:28:25 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22]) by mx1.freebsd.org (Postfix) with ESMTP id 4B0578FC0C for ; Thu, 22 Sep 2011 16:28:25 +0000 (UTC) Received: from red.freebsd.org (localhost [127.0.0.1]) by red.freebsd.org (8.14.4/8.14.4) with ESMTP id p8MGSO3O016253 for ; Thu, 22 Sep 2011 16:28:24 GMT (envelope-from nobody@red.freebsd.org) Received: (from nobody@localhost) by red.freebsd.org (8.14.4/8.14.4/Submit) id p8MGSOB1016252; Thu, 22 Sep 2011 16:28:24 GMT (envelope-from nobody) Message-Id: <201109221628.p8MGSOB1016252@red.freebsd.org> Date: Thu, 22 Sep 2011 16:28:24 GMT From: Andrey To: freebsd-gnats-submit@FreeBSD.org Subject: The usb flash drive JetFlash Transcend 16GB 1100 doesn't work by default X-Send-Pr-Version: www-3.1 X-GNATS-Notify: >Number: 160911 >Category: usb >Synopsis: The usb flash drive JetFlash Transcend 16GB 1100 doesn't work by default >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-usb >State: closed >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu Sep 22 16:30:05 UTC 2011 >Closed-Date: Sun Jan 29 08:09:44 UTC 2012 >Last-Modified: Sun Jan 29 08:09:44 UTC 2012 >Originator: Andrey >Release: FreeBSD 9.0-BETA2 >Organization: >Environment: reeBSD localhost 9.0-BETA2 FreeBSD 9.0-BETA2 #9 r225639M: Sat Sep 17 20:06:00 MSK 2011 root@localhost:/usr/obj/usr/src/sys/GENERIC amd64 >Description: The usb flash drive JetFlash Transcend 16GB 1100 doesn't work by default: dmesg; ugen3.2: at usbus3 umass0: on usbus3 umass0: SCSI over Bulk-Only; quirks = 0x0000 umass0:13:0:-1: Attached to scbus13 ugen3.2: at usbus3 (disconnected) umass0: at uhub3, port 1, addr 2 (disconnected) usbconfig: at usbus3, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON /dev/ haven't any da* devices. >How-To-Repeat: plug in usb flash drive JetFlash Transcend 16GB 1100 >Fix: usbconfig -d 3.2 add_quirk UQ_MSC_NO_SYNC_CACHE usbconfig -d 3.2 reset mount_msdos /dev/da0s1 /mnt/flash done >Release-Note: >Audit-Trail: From: Hans Petter Selasky To: freebsd-usb@freebsd.org Cc: Andrey , freebsd-gnats-submit@freebsd.org Subject: Re: usb/160911: The usb flash drive JetFlash Transcend 16GB 1100 doesn't work by default Date: Thu, 22 Sep 2011 18:46:39 +0200 On Thursday 22 September 2011 18:28:24 Andrey wrote: > >Number: 160911 > >Category: usb > >Synopsis: The usb flash drive JetFlash Transcend 16GB 1100 doesn't > >work by default Confidential: no > >Severity: non-critical > >Priority: low > >Responsible: freebsd-usb > >State: open > >Quarter: > >Keywords: > >Date-Required: > >Class: sw-bug > >Submitter-Id: current-users > >Arrival-Date: Thu Sep 22 16:30:05 UTC 2011 > >Closed-Date: > >Last-Modified: > >Originator: Andrey > >Release: FreeBSD 9.0-BETA2 > >Organization: > > >Environment: > reeBSD localhost 9.0-BETA2 FreeBSD 9.0-BETA2 #9 r225639M: Sat Sep 17 > 20:06:00 MSK 2011 root@localhost:/usr/obj/usr/src/sys/GENERIC amd64 > > >Description: > The usb flash drive JetFlash Transcend 16GB 1100 doesn't work by default: > dmesg; > > ugen3.2: at usbus3 > umass0: > on usbus3 umass0: SCSI over Bulk-Only; quirks = 0x0000 > umass0:13:0:-1: Attached to scbus13 > ugen3.2: at usbus3 (disconnected) > umass0: at uhub3, port 1, addr 2 (disconnected) > > usbconfig: > > at usbus3, cfg=0 md=HOST spd=HIGH (480Mbps) > pwr=ON > > /dev/ haven't any da* devices. > > >How-To-Repeat: > plug in usb flash drive JetFlash Transcend 16GB 1100 > > >Fix: > usbconfig -d 3.2 add_quirk UQ_MSC_NO_SYNC_CACHE > usbconfig -d 3.2 reset > > mount_msdos /dev/da0s1 /mnt/flash > done Hi, Can you dump the USB device descriptor of your device? --HPS From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: usb/160911: commit references a PR Date: Tue, 27 Sep 2011 07:06:17 +0000 (UTC) Author: hselasky Date: Tue Sep 27 07:06:02 2011 New Revision: 225777 URL: http://svn.freebsd.org/changeset/base/225777 Log: Add quirks for some USB mass storage devices which doesn't respond after trying to query the synchronize cache support. Submitted by: Keith White PR: usb/160911 Approved by: re (kensmith) MFC after: 1 week Modified: head/sys/dev/usb/quirk/usb_quirk.c head/sys/dev/usb/usbdevs Modified: head/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- head/sys/dev/usb/quirk/usb_quirk.c Tue Sep 27 07:05:41 2011 (r225776) +++ head/sys/dev/usb/quirk/usb_quirk.c Tue Sep 27 07:06:02 2011 (r225777) @@ -457,6 +457,13 @@ static struct usb_quirk_entry usb_quirks USB_QUIRK(ROLAND, SD80, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), USB_QUIRK(ROLAND, UA700, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), USB_QUIRK(MEDELI, DD305, 0x0000, 0xffff, UQ_SINGLE_CMD_MIDI, UQ_MATCH_VENDOR_ONLY), + + /* + * Quirks for manufacturers which USB devices does not respond + * after issuing non-supported commands: + */ + USB_QUIRK(FEIYA, DUMMY, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE, UQ_MATCH_VENDOR_ONLY), + USB_QUIRK(REALTEK, DUMMY, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE, UQ_MATCH_VENDOR_ONLY), }; #undef USB_QUIRK_VP #undef USB_QUIRK Modified: head/sys/dev/usb/usbdevs ============================================================================== --- head/sys/dev/usb/usbdevs Tue Sep 27 07:05:41 2011 (r225776) +++ head/sys/dev/usb/usbdevs Tue Sep 27 07:06:02 2011 (r225777) @@ -1569,6 +1569,7 @@ product EXTENDED XTNDACCESS 0x0100 XTNDA product FALCOM TWIST 0x0001 USB GSM/GPRS Modem /* FEIYA products */ +product FEIYA DUMMY 0x0000 Dummy product product FEIYA 5IN1 0x1132 5-in-1 Card Reader product FEIYA AC110 0x6300 AC-110 Card Reader @@ -2780,6 +2781,7 @@ product RATOC REXUSB60F 0xb020 USB seri /* ReakTek products */ /* Green House and CompUSA OEM this part */ +product REALTEK DUMMY 0x0000 Dummy product product REALTEK USB20CRW 0x0158 USB20CRW Card Reader product REALTEK USBKR100 0x8150 USBKR100 USB Ethernet product REALTEK RTL8187 0x8187 RTL8187 Wireless Adapter _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: usb/160911: commit references a PR Date: Tue, 1 Nov 2011 08:24:23 +0000 (UTC) Author: hselasky Date: Tue Nov 1 08:24:01 2011 New Revision: 226984 URL: http://svn.freebsd.org/changeset/base/226984 Log: MFC r226903, r225777, r226221 and r226534: Add some new USB device IDs and some USB device quirks. Improve the USB mass storage auto quirk detection. PR: usb/161798, usb/160911 Modified: stable/8/etc/devd/usb.conf stable/8/sys/dev/usb/quirk/usb_quirk.c stable/8/sys/dev/usb/usb_device.c stable/8/sys/dev/usb/usb_msctest.c stable/8/sys/dev/usb/usbdevs stable/8/sys/dev/usb/wlan/if_run.c Directory Properties: stable/8/etc/ (props changed) stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) Modified: stable/8/etc/devd/usb.conf ============================================================================== --- stable/8/etc/devd/usb.conf Tue Nov 1 04:21:57 2011 (r226983) +++ stable/8/etc/devd/usb.conf Tue Nov 1 08:24:01 2011 (r226984) @@ -565,6 +565,14 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x04e8"; + match "product" "0x2018"; + action "kldload if_run"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x04e8"; match "product" "(0x5f00|0x5f01|0x5f02|0x5f03|0x5f04)"; action "kldload uipaq"; }; @@ -741,7 +749,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x050d"; - match "product" "(0x8053|0x805c|0x815c|0x825a)"; + match "product" "(0x8053|0x805c|0x815c|0x825a|0x825b)"; action "kldload if_run"; }; @@ -1877,7 +1885,23 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x0af0"; - match "product" "(0x5000|0x6000|0x6050|0x6100|0x6150|0x6200|0x6250|0x6300|0x6350|0x6500|0x6501|0x6600|0x6601|0x6701|0x6721|0x6741|0x6761|0x6800|0x6901)"; + match "product" "(0x5000|0x6000|0x6050|0x6100|0x6150|0x6200|0x6250|0x6300|0x6350|0x6500|0x6501|0x6600|0x6601|0x6701)"; + action "kldload u3g"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x0af0"; + match "product" "0x6711"; + action "kldload uhso"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x0af0"; + match "product" "(0x6721|0x6741|0x6761|0x6800|0x6901)"; action "kldload u3g"; }; @@ -2069,7 +2093,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x0b95"; - match "product" "(0x1720|0x1780|0x7720|0x772a)"; + match "product" "(0x1720|0x1780|0x7720|0x772a|0x772b)"; action "kldload if_axe"; }; @@ -2500,6 +2524,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x0f3d"; + match "product" "0x68a3"; + action "kldload usie"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x0f4e"; match "product" "0x0200"; action "kldload uipaq"; @@ -2789,13 +2821,37 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x1199"; - match "product" "(0x0220|0x0224|0x0fff|0x6802|0x6803|0x6804|0x6805|0x6808|0x6809|0x6812|0x6813|0x6815|0x6816|0x6820|0x6821|0x6822|0x6832|0x6833|0x6834|0x6835|0x6838|0x6839|0x683a|0x683b|0x683c|0x683d|0x683e|0x6850|0x6851|0x6852|0x6853|0x6855|0x6856|0x6859|0x685a|0x6880|0x6890|0x6891|0x6892|0x6893|0x68a3)"; + match "product" "(0x0220|0x0224|0x0fff)"; + action "kldload u3g"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x1199"; + match "product" "0x0fff"; + action "kldload usie"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x1199"; + match "product" "(0x6802|0x6803|0x6804|0x6805|0x6808|0x6809|0x6812|0x6813|0x6815|0x6816|0x6820|0x6821|0x6822|0x6832|0x6833|0x6834|0x6835|0x6838|0x6839|0x683a|0x683b|0x683c|0x683d|0x683e|0x6850|0x6851|0x6852|0x6853|0x6855|0x6856|0x6859|0x685a|0x6880|0x6890|0x6891|0x6892|0x6893|0x68a3)"; action "kldload u3g"; }; nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x1199"; + match "product" "0x68a3"; + action "kldload usie"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x11ad"; match "product" "0x0701"; action "kldload uplcom"; @@ -2869,7 +2925,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x12d1"; - match "product" "(0x1001|0x1003|0x1004|0x1401|0x1402|0x1403|0x1404|0x1405|0x1406|0x1407|0x1408|0x1409|0x140a|0x140b|0x140c|0x140d|0x140e|0x140f|0x1410|0x1411|0x1412|0x1413|0x1414|0x1415|0x1416|0x1417|0x1418|0x1419|0x141a|0x141b|0x141c|0x141d|0x141e|0x141f|0x1420|0x1421|0x1422|0x1423|0x1424|0x1425|0x1426|0x1427|0x1428|0x1429|0x142a|0x142b|0x142c|0x142d|0x142e|0x142f|0x1430|0x1431|0x1432|0x1433|0x1434|0x1435|0x1436|0x1437|0x1438|0x1439|0x143a|0x143b|0x143c|0x143d|0x143e|0x143f|0x1446|0x1465|0x14ac|0x1520)" ; + match "product" "(0x1001|0x1003|0x1004|0x1401|0x1402|0x1403|0x1404|0x1405|0x1406|0x1407|0x1408|0x1409|0x140a|0x140b|0x140c|0x140d|0x140e|0x140f|0x1410|0x1411|0x1412|0x1413|0x1414|0x1415|0x1416|0x1417|0x1418|0x1419|0x141a|0x141b|0x141c|0x141d|0x141e|0x141f|0x1420|0x1421|0x1422|0x1423|0x1424|0x1425|0x1426|0x1427|0x1428|0x1429|0x142a|0x142b|0x142c|0x142d|0x142e|0x142f|0x1430|0x1431|0x1432|0x1433|0x1434|0x1435|0x1436|0x1437|0x1438|0x1439|0x143a|0x143b|0x143c|0x143d|0x143e|0x143f|0x1446|0x1465|0x14ac|0x1520|0 x1c05|0x1c0b)"; action "kldload u3g"; }; @@ -2972,6 +3028,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x13b1"; + match "product" "0x002f"; + action "kldload if_run"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x13d2"; match "product" "0x0400"; action "kldload if_kue"; @@ -3669,7 +3733,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x1c9e"; - match "product" "(0x6061|0x9603|0xf000)"; + match "product" "(0x6061|0x9603|0x9605|0xf000)"; action "kldload u3g"; }; @@ -4263,5 +4327,5 @@ nomatch 32 { action "kldload umass"; }; -# 1634 USB entries processed +# 1645 USB entries processed Modified: stable/8/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- stable/8/sys/dev/usb/quirk/usb_quirk.c Tue Nov 1 04:21:57 2011 (r226983) +++ stable/8/sys/dev/usb/quirk/usb_quirk.c Tue Nov 1 08:24:01 2011 (r226984) @@ -457,6 +457,14 @@ static struct usb_quirk_entry usb_quirks USB_QUIRK(ROLAND, SD80, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), USB_QUIRK(ROLAND, UA700, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), USB_QUIRK(MEDELI, DD305, 0x0000, 0xffff, UQ_SINGLE_CMD_MIDI, UQ_MATCH_VENDOR_ONLY), + + /* + * Quirks for manufacturers which USB devices does not respond + * after issuing non-supported commands: + */ + USB_QUIRK(FEIYA, DUMMY, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE, UQ_MATCH_VENDOR_ONLY), + USB_QUIRK(REALTEK, DUMMY, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE, UQ_MATCH_VENDOR_ONLY), + USB_QUIRK(INITIO, DUMMY, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE, UQ_MATCH_VENDOR_ONLY), }; #undef USB_QUIRK_VP #undef USB_QUIRK Modified: stable/8/sys/dev/usb/usb_device.c ============================================================================== --- stable/8/sys/dev/usb/usb_device.c Tue Nov 1 04:21:57 2011 (r226983) +++ stable/8/sys/dev/usb/usb_device.c Tue Nov 1 08:24:01 2011 (r226984) @@ -1851,7 +1851,8 @@ repeat_set_config: } } if (set_config_failed == 0 && config_index == 0 && - usb_test_quirk(&uaa, UQ_MSC_NO_SYNC_CACHE) == 0) { + usb_test_quirk(&uaa, UQ_MSC_NO_SYNC_CACHE) == 0 && + usb_test_quirk(&uaa, UQ_MSC_NO_GETMAXLUN) == 0) { /* * Try to figure out if there are any MSC quirks we Modified: stable/8/sys/dev/usb/usb_msctest.c ============================================================================== --- stable/8/sys/dev/usb/usb_msctest.c Tue Nov 1 04:21:57 2011 (r226983) +++ stable/8/sys/dev/usb/usb_msctest.c Tue Nov 1 08:24:01 2011 (r226984) @@ -604,6 +604,29 @@ usb_iface_is_cdrom(struct usb_device *ud return (is_cdrom); } +static uint8_t +usb_msc_get_max_lun(struct usb_device *udev, uint8_t iface_index) +{ + struct usb_device_request req; + usb_error_t err; + uint8_t buf = 0; + + + /* The Get Max Lun command is a class-specific request. */ + req.bmRequestType = UT_READ_CLASS_INTERFACE; + req.bRequest = 0xFE; /* GET_MAX_LUN */ + USETW(req.wValue, 0); + req.wIndex[0] = iface_index; + req.wIndex[1] = 0; + USETW(req.wLength, 1); + + err = usbd_do_request(udev, NULL, &req, &buf); + if (err) + buf = 0; + + return (buf); +} + usb_error_t usb_msc_auto_quirk(struct usb_device *udev, uint8_t iface_index) { @@ -623,6 +646,11 @@ usb_msc_auto_quirk(struct usb_device *ud */ usb_pause_mtx(NULL, hz); + if (usb_msc_get_max_lun(udev, iface_index) == 0) { + DPRINTF("Device has only got one LUN.\n"); + usbd_add_dynamic_quirk(udev, UQ_MSC_NO_GETMAXLUN); + } + is_no_direct = 1; for (timeout = 4; timeout; timeout--) { err = bbb_command_start(sc, DIR_IN, 0, sc->buffer, Modified: stable/8/sys/dev/usb/usbdevs ============================================================================== --- stable/8/sys/dev/usb/usbdevs Tue Nov 1 04:21:57 2011 (r226983) +++ stable/8/sys/dev/usb/usbdevs Tue Nov 1 08:24:01 2011 (r226984) @@ -606,6 +606,7 @@ vendor BALTECH 0x13ad Baltech vendor CISCOLINKSYS 0x13b1 Cisco-Linksys vendor SHARK 0x13d2 Shark vendor AZUREWAVE 0x13d3 AsureWave +vendor INITIO 0x13fd Initio Corporation vendor EMTEC 0x13fe Emtec vendor NOVATEL 0x1410 Novatel Wireless vendor MERLIN 0x1416 Merlin @@ -1142,6 +1143,7 @@ product BELKIN RT2870_1 0x8053 RT2870 product BELKIN RT2870_2 0x805c RT2870 product BELKIN F5D8053V3 0x815c F5D8053 v3 product BELKIN F5D8055 0x825a F5D8055 +product BELKIN F5D8055V2 0x825b F5D8055 v2 product BELKIN F5D9050V3 0x905b F5D9050 ver 3 Wireless Adapter product BELKIN2 F5U002 0x0002 F5U002 Parallel printer product BELKIN F6D4050V1 0x935a F6D4050 v1 @@ -1225,8 +1227,9 @@ product CISCOLINKSYS HU200TS 0x001a HU20 product CISCOLINKSYS WUSB54GC 0x0020 WUSB54GC product CISCOLINKSYS WUSB54GR 0x0023 WUSB54GR product CISCOLINKSYS WUSBF54G 0x0024 WUSBF54G -product CISCOLINKSYS2 RT3070 0x4001 RT3070 -product CISCOLINKSYS3 RT3070 0x0101 RT3070 +product CISCOLINKSYS AE1000 0x002f AE1000 +product CISCOLINKSYS2 RT3070 0x4001 RT3070 +product CISCOLINKSYS3 RT3070 0x0101 RT3070 /* Clipsal products */ product CLIPSAL 5500PCU 0x0303 5500PCU C-Bus @@ -1567,6 +1570,7 @@ product EXTENDED XTNDACCESS 0x0100 XTNDA product FALCOM TWIST 0x0001 USB GSM/GPRS Modem /* FEIYA products */ +product FEIYA DUMMY 0x0000 Dummy product product FEIYA 5IN1 0x1132 5-in-1 Card Reader product FEIYA AC110 0x6300 AC-110 Card Reader @@ -1884,6 +1888,10 @@ product IBM USBCDROMDRIVE 0x4427 USB CD- /* Imagination Technologies products */ product IMAGINATION DBX1 0x2107 DBX1 DSP core +/* Initio Corporation products */ +product INITIO DUMMY 0x0000 Dummy product +product INITIO INIC_1610P 0x1e40 USB to SATA Bridge + /* Inside Out Networks products */ product INSIDEOUT EDGEPORT4 0x0001 EdgePort/4 serial ports @@ -2774,6 +2782,7 @@ product RATOC REXUSB60F 0xb020 USB seri /* ReakTek products */ /* Green House and CompUSA OEM this part */ +product REALTEK DUMMY 0x0000 Dummy product product REALTEK USB20CRW 0x0158 USB20CRW Card Reader product REALTEK USBKR100 0x8150 USBKR100 USB Ethernet product REALTEK RTL8187 0x8187 RTL8187 Wireless Adapter @@ -2827,6 +2836,7 @@ product SAGEM XG760A 0x004a XG-760A product SAGEM XG76NA 0x0062 XG-76NA /* Samsung products */ +product SAMSUNG WIS09ABGN 0x2018 WIS09ABGN Wireless LAN adapter product SAMSUNG ML6060 0x3008 ML-6060 laser printer product SAMSUNG YP_U2 0x5050 YP-U2 MP3 Player product SAMSUNG YP_U4 0x5092 YP-U4 MP3 Player Modified: stable/8/sys/dev/usb/wlan/if_run.c ============================================================================== --- stable/8/sys/dev/usb/wlan/if_run.c Tue Nov 1 04:21:57 2011 (r226983) +++ stable/8/sys/dev/usb/wlan/if_run.c Tue Nov 1 08:24:01 2011 (r226984) @@ -144,9 +144,11 @@ static const STRUCT_USB_HOST_ID run_devs RUN_DEV(AZUREWAVE, RT3070_3), RUN_DEV(BELKIN, F5D8053V3), RUN_DEV(BELKIN, F5D8055), + RUN_DEV(BELKIN, F5D8055V2), RUN_DEV(BELKIN, F6D4050V1), RUN_DEV(BELKIN, RT2870_1), RUN_DEV(BELKIN, RT2870_2), + RUN_DEV(CISCOLINKSYS, AE1000), RUN_DEV(CISCOLINKSYS2, RT3070), RUN_DEV(CISCOLINKSYS3, RT3070), RUN_DEV(CONCEPTRONIC2, RT2870_1), @@ -247,6 +249,7 @@ static const STRUCT_USB_HOST_ID run_devs RUN_DEV(RALINK, RT3370), RUN_DEV(RALINK, RT3572), RUN_DEV(RALINK, RT8070), + RUN_DEV(SAMSUNG, WIS09ABGN), RUN_DEV(SAMSUNG2, RT2870_1), RUN_DEV(SENAO, RT2870_1), RUN_DEV(SENAO, RT2870_2), _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: usb/160911: commit references a PR Date: Tue, 1 Nov 2011 22:01:05 +0000 (UTC) Author: hselasky Date: Tue Nov 1 22:00:49 2011 New Revision: 227007 URL: http://svn.freebsd.org/changeset/base/227007 Log: MFC r226903, r225777, r226221 and r226534: Add some new USB device IDs and some USB device quirks. Improve the USB mass storage auto quirk detection. PR: usb/161798, usb/160911 Approved by: re (kib) Modified: stable/9/etc/devd/usb.conf stable/9/sys/dev/usb/quirk/usb_quirk.c stable/9/sys/dev/usb/usb_device.c stable/9/sys/dev/usb/usb_msctest.c stable/9/sys/dev/usb/usbdevs stable/9/sys/dev/usb/wlan/if_run.c Directory Properties: stable/9/etc/ (props changed) stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) Modified: stable/9/etc/devd/usb.conf ============================================================================== --- stable/9/etc/devd/usb.conf Tue Nov 1 21:26:57 2011 (r227006) +++ stable/9/etc/devd/usb.conf Tue Nov 1 22:00:49 2011 (r227007) @@ -565,6 +565,14 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x04e8"; + match "product" "0x2018"; + action "kldload if_run"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x04e8"; match "product" "(0x5f00|0x5f01|0x5f02|0x5f03|0x5f04)"; action "kldload uipaq"; }; @@ -741,7 +749,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x050d"; - match "product" "(0x8053|0x805c|0x815c|0x825a)"; + match "product" "(0x8053|0x805c|0x815c|0x825a|0x825b)"; action "kldload if_run"; }; @@ -1877,7 +1885,23 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x0af0"; - match "product" "(0x5000|0x6000|0x6050|0x6100|0x6150|0x6200|0x6250|0x6300|0x6350|0x6500|0x6501|0x6600|0x6601|0x6701|0x6721|0x6741|0x6761|0x6800|0x6901)"; + match "product" "(0x5000|0x6000|0x6050|0x6100|0x6150|0x6200|0x6250|0x6300|0x6350|0x6500|0x6501|0x6600|0x6601|0x6701)"; + action "kldload u3g"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x0af0"; + match "product" "0x6711"; + action "kldload uhso"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x0af0"; + match "product" "(0x6721|0x6741|0x6761|0x6800|0x6901)"; action "kldload u3g"; }; @@ -2069,7 +2093,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x0b95"; - match "product" "(0x1720|0x1780|0x7720|0x772a)"; + match "product" "(0x1720|0x1780|0x7720|0x772a|0x772b)"; action "kldload if_axe"; }; @@ -2500,6 +2524,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x0f3d"; + match "product" "0x68a3"; + action "kldload usie"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x0f4e"; match "product" "0x0200"; action "kldload uipaq"; @@ -2789,13 +2821,37 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x1199"; - match "product" "(0x0220|0x0224|0x0fff|0x6802|0x6803|0x6804|0x6805|0x6808|0x6809|0x6812|0x6813|0x6815|0x6816|0x6820|0x6821|0x6822|0x6832|0x6833|0x6834|0x6835|0x6838|0x6839|0x683a|0x683b|0x683c|0x683d|0x683e|0x6850|0x6851|0x6852|0x6853|0x6855|0x6856|0x6859|0x685a|0x6880|0x6890|0x6891|0x6892|0x6893|0x68a3)"; + match "product" "(0x0220|0x0224|0x0fff)"; + action "kldload u3g"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x1199"; + match "product" "0x0fff"; + action "kldload usie"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; + match "vendor" "0x1199"; + match "product" "(0x6802|0x6803|0x6804|0x6805|0x6808|0x6809|0x6812|0x6813|0x6815|0x6816|0x6820|0x6821|0x6822|0x6832|0x6833|0x6834|0x6835|0x6838|0x6839|0x683a|0x683b|0x683c|0x683d|0x683e|0x6850|0x6851|0x6852|0x6853|0x6855|0x6856|0x6859|0x685a|0x6880|0x6890|0x6891|0x6892|0x6893|0x68a3)"; action "kldload u3g"; }; nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x1199"; + match "product" "0x68a3"; + action "kldload usie"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x11ad"; match "product" "0x0701"; action "kldload uplcom"; @@ -2869,7 +2925,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x12d1"; - match "product" "(0x1001|0x1003|0x1004|0x1401|0x1402|0x1403|0x1404|0x1405|0x1406|0x1407|0x1408|0x1409|0x140a|0x140b|0x140c|0x140d|0x140e|0x140f|0x1410|0x1411|0x1412|0x1413|0x1414|0x1415|0x1416|0x1417|0x1418|0x1419|0x141a|0x141b|0x141c|0x141d|0x141e|0x141f|0x1420|0x1421|0x1422|0x1423|0x1424|0x1425|0x1426|0x1427|0x1428|0x1429|0x142a|0x142b|0x142c|0x142d|0x142e|0x142f|0x1430|0x1431|0x1432|0x1433|0x1434|0x1435|0x1436|0x1437|0x1438|0x1439|0x143a|0x143b|0x143c|0x143d|0x143e|0x143f|0x1446|0x1465|0x14ac|0x1520)" ; + match "product" "(0x1001|0x1003|0x1004|0x1401|0x1402|0x1403|0x1404|0x1405|0x1406|0x1407|0x1408|0x1409|0x140a|0x140b|0x140c|0x140d|0x140e|0x140f|0x1410|0x1411|0x1412|0x1413|0x1414|0x1415|0x1416|0x1417|0x1418|0x1419|0x141a|0x141b|0x141c|0x141d|0x141e|0x141f|0x1420|0x1421|0x1422|0x1423|0x1424|0x1425|0x1426|0x1427|0x1428|0x1429|0x142a|0x142b|0x142c|0x142d|0x142e|0x142f|0x1430|0x1431|0x1432|0x1433|0x1434|0x1435|0x1436|0x1437|0x1438|0x1439|0x143a|0x143b|0x143c|0x143d|0x143e|0x143f|0x1446|0x1465|0x14ac|0x1520|0 x1c05|0x1c0b)"; action "kldload u3g"; }; @@ -2972,6 +3028,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x13b1"; + match "product" "0x002f"; + action "kldload if_run"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x13d2"; match "product" "0x0400"; action "kldload if_kue"; @@ -3669,7 +3733,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x1c9e"; - match "product" "(0x6061|0x9603|0xf000)"; + match "product" "(0x6061|0x9603|0x9605|0xf000)"; action "kldload u3g"; }; @@ -4263,5 +4327,5 @@ nomatch 32 { action "kldload umass"; }; -# 1634 USB entries processed +# 1645 USB entries processed Modified: stable/9/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- stable/9/sys/dev/usb/quirk/usb_quirk.c Tue Nov 1 21:26:57 2011 (r227006) +++ stable/9/sys/dev/usb/quirk/usb_quirk.c Tue Nov 1 22:00:49 2011 (r227007) @@ -457,6 +457,14 @@ static struct usb_quirk_entry usb_quirks USB_QUIRK(ROLAND, SD80, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), USB_QUIRK(ROLAND, UA700, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), USB_QUIRK(MEDELI, DD305, 0x0000, 0xffff, UQ_SINGLE_CMD_MIDI, UQ_MATCH_VENDOR_ONLY), + + /* + * Quirks for manufacturers which USB devices does not respond + * after issuing non-supported commands: + */ + USB_QUIRK(FEIYA, DUMMY, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE, UQ_MATCH_VENDOR_ONLY), + USB_QUIRK(REALTEK, DUMMY, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE, UQ_MATCH_VENDOR_ONLY), + USB_QUIRK(INITIO, DUMMY, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE, UQ_MATCH_VENDOR_ONLY), }; #undef USB_QUIRK_VP #undef USB_QUIRK Modified: stable/9/sys/dev/usb/usb_device.c ============================================================================== --- stable/9/sys/dev/usb/usb_device.c Tue Nov 1 21:26:57 2011 (r227006) +++ stable/9/sys/dev/usb/usb_device.c Tue Nov 1 22:00:49 2011 (r227007) @@ -1851,7 +1851,8 @@ repeat_set_config: } } if (set_config_failed == 0 && config_index == 0 && - usb_test_quirk(&uaa, UQ_MSC_NO_SYNC_CACHE) == 0) { + usb_test_quirk(&uaa, UQ_MSC_NO_SYNC_CACHE) == 0 && + usb_test_quirk(&uaa, UQ_MSC_NO_GETMAXLUN) == 0) { /* * Try to figure out if there are any MSC quirks we Modified: stable/9/sys/dev/usb/usb_msctest.c ============================================================================== --- stable/9/sys/dev/usb/usb_msctest.c Tue Nov 1 21:26:57 2011 (r227006) +++ stable/9/sys/dev/usb/usb_msctest.c Tue Nov 1 22:00:49 2011 (r227007) @@ -603,6 +603,29 @@ usb_iface_is_cdrom(struct usb_device *ud return (is_cdrom); } +static uint8_t +usb_msc_get_max_lun(struct usb_device *udev, uint8_t iface_index) +{ + struct usb_device_request req; + usb_error_t err; + uint8_t buf = 0; + + + /* The Get Max Lun command is a class-specific request. */ + req.bmRequestType = UT_READ_CLASS_INTERFACE; + req.bRequest = 0xFE; /* GET_MAX_LUN */ + USETW(req.wValue, 0); + req.wIndex[0] = iface_index; + req.wIndex[1] = 0; + USETW(req.wLength, 1); + + err = usbd_do_request(udev, NULL, &req, &buf); + if (err) + buf = 0; + + return (buf); +} + usb_error_t usb_msc_auto_quirk(struct usb_device *udev, uint8_t iface_index) { @@ -622,6 +645,11 @@ usb_msc_auto_quirk(struct usb_device *ud */ usb_pause_mtx(NULL, hz); + if (usb_msc_get_max_lun(udev, iface_index) == 0) { + DPRINTF("Device has only got one LUN.\n"); + usbd_add_dynamic_quirk(udev, UQ_MSC_NO_GETMAXLUN); + } + is_no_direct = 1; for (timeout = 4; timeout; timeout--) { err = bbb_command_start(sc, DIR_IN, 0, sc->buffer, Modified: stable/9/sys/dev/usb/usbdevs ============================================================================== --- stable/9/sys/dev/usb/usbdevs Tue Nov 1 21:26:57 2011 (r227006) +++ stable/9/sys/dev/usb/usbdevs Tue Nov 1 22:00:49 2011 (r227007) @@ -606,6 +606,7 @@ vendor BALTECH 0x13ad Baltech vendor CISCOLINKSYS 0x13b1 Cisco-Linksys vendor SHARK 0x13d2 Shark vendor AZUREWAVE 0x13d3 AsureWave +vendor INITIO 0x13fd Initio Corporation vendor EMTEC 0x13fe Emtec vendor NOVATEL 0x1410 Novatel Wireless vendor MERLIN 0x1416 Merlin @@ -1144,6 +1145,7 @@ product BELKIN RT2870_1 0x8053 RT2870 product BELKIN RT2870_2 0x805c RT2870 product BELKIN F5D8053V3 0x815c F5D8053 v3 product BELKIN F5D8055 0x825a F5D8055 +product BELKIN F5D8055V2 0x825b F5D8055 v2 product BELKIN F5D9050V3 0x905b F5D9050 ver 3 Wireless Adapter product BELKIN2 F5U002 0x0002 F5U002 Parallel printer product BELKIN F6D4050V1 0x935a F6D4050 v1 @@ -1227,8 +1229,9 @@ product CISCOLINKSYS HU200TS 0x001a HU20 product CISCOLINKSYS WUSB54GC 0x0020 WUSB54GC product CISCOLINKSYS WUSB54GR 0x0023 WUSB54GR product CISCOLINKSYS WUSBF54G 0x0024 WUSBF54G -product CISCOLINKSYS2 RT3070 0x4001 RT3070 -product CISCOLINKSYS3 RT3070 0x0101 RT3070 +product CISCOLINKSYS AE1000 0x002f AE1000 +product CISCOLINKSYS2 RT3070 0x4001 RT3070 +product CISCOLINKSYS3 RT3070 0x0101 RT3070 /* Clipsal products */ product CLIPSAL 5500PCU 0x0303 5500PCU C-Bus @@ -1569,6 +1572,7 @@ product EXTENDED XTNDACCESS 0x0100 XTNDA product FALCOM TWIST 0x0001 USB GSM/GPRS Modem /* FEIYA products */ +product FEIYA DUMMY 0x0000 Dummy product product FEIYA 5IN1 0x1132 5-in-1 Card Reader product FEIYA AC110 0x6300 AC-110 Card Reader @@ -1886,6 +1890,10 @@ product IBM USBCDROMDRIVE 0x4427 USB CD- /* Imagination Technologies products */ product IMAGINATION DBX1 0x2107 DBX1 DSP core +/* Initio Corporation products */ +product INITIO DUMMY 0x0000 Dummy product +product INITIO INIC_1610P 0x1e40 USB to SATA Bridge + /* Inside Out Networks products */ product INSIDEOUT EDGEPORT4 0x0001 EdgePort/4 serial ports @@ -2780,6 +2788,7 @@ product RATOC REXUSB60F 0xb020 USB seri /* ReakTek products */ /* Green House and CompUSA OEM this part */ +product REALTEK DUMMY 0x0000 Dummy product product REALTEK USB20CRW 0x0158 USB20CRW Card Reader product REALTEK USBKR100 0x8150 USBKR100 USB Ethernet product REALTEK RTL8187 0x8187 RTL8187 Wireless Adapter @@ -2833,6 +2842,7 @@ product SAGEM XG760A 0x004a XG-760A product SAGEM XG76NA 0x0062 XG-76NA /* Samsung products */ +product SAMSUNG WIS09ABGN 0x2018 WIS09ABGN Wireless LAN adapter product SAMSUNG ML6060 0x3008 ML-6060 laser printer product SAMSUNG YP_U2 0x5050 YP-U2 MP3 Player product SAMSUNG YP_U4 0x5092 YP-U4 MP3 Player Modified: stable/9/sys/dev/usb/wlan/if_run.c ============================================================================== --- stable/9/sys/dev/usb/wlan/if_run.c Tue Nov 1 21:26:57 2011 (r227006) +++ stable/9/sys/dev/usb/wlan/if_run.c Tue Nov 1 22:00:49 2011 (r227007) @@ -144,9 +144,11 @@ static const STRUCT_USB_HOST_ID run_devs RUN_DEV(AZUREWAVE, RT3070_3), RUN_DEV(BELKIN, F5D8053V3), RUN_DEV(BELKIN, F5D8055), + RUN_DEV(BELKIN, F5D8055V2), RUN_DEV(BELKIN, F6D4050V1), RUN_DEV(BELKIN, RT2870_1), RUN_DEV(BELKIN, RT2870_2), + RUN_DEV(CISCOLINKSYS, AE1000), RUN_DEV(CISCOLINKSYS2, RT3070), RUN_DEV(CISCOLINKSYS3, RT3070), RUN_DEV(CONCEPTRONIC2, RT2870_1), @@ -247,6 +249,7 @@ static const STRUCT_USB_HOST_ID run_devs RUN_DEV(RALINK, RT3370), RUN_DEV(RALINK, RT3572), RUN_DEV(RALINK, RT8070), + RUN_DEV(SAMSUNG, WIS09ABGN), RUN_DEV(SAMSUNG2, RT2870_1), RUN_DEV(SENAO, RT2870_1), RUN_DEV(SENAO, RT2870_2), _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" State-Changed-From-To: open->closed State-Changed-By: miwi State-Changed-When: Sun Jan 29 08:09:43 UTC 2012 State-Changed-Why: already committed and mfc. http://www.freebsd.org/cgi/query-pr.cgi?pr=160911 >Unformatted: