From owner-freebsd-usb@FreeBSD.ORG Mon Sep 5 08:33:11 2011 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5AEAD1065673 for ; Mon, 5 Sep 2011 08:33:11 +0000 (UTC) (envelope-from Kaminar@seznam.cz) Received: from mxl1.seznam.cz (mxl1.seznam.cz [77.75.72.44]) by mx1.freebsd.org (Postfix) with ESMTP id 8D7FC8FC16 for ; Mon, 5 Sep 2011 08:33:09 +0000 (UTC) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=seznam.cz; h=To:Date:From:Received:Subject:Mime-Version:Message-Id:Content-Transfer-Encoding:Content-Type:X-Country:X-Abuse:X-Seznam-User:X-Virus-Info:X-Seznam-SPF:X-Seznam-DomainKeys; b=krgP17SHdh/AUnhM8BzyqQtKc0h03fDKHqCTi8+PhH0MMNAClGyAtSge1JBZpuFCj PPA6Qy6/8me4XITKypOgO6Bjx7iAFU6P0UUio9JJnyuyBM7s3GfeHfysrjSBFhwE0r2 wjDvnzq/iDRqoCx5I9jY7Wr/ohk3gVVyJ+tiQqY= To: freebsd-usb@freebsd.org Date: Mon, 05 Sep 2011 10:09:08 +0200 (CEST) From: Kaminar Received: from ( [85.132.159.231]) by email.seznam.cz (Email.Seznam.cz) with HTTP for Kaminar@seznam.cz; Mon, 5 Sep 2011 10:05:18 +0200 (CEST) Mime-Version: 1.0 Message-Id: <36906.1460.1877-31416-1359865944-1315210148@seznam.cz> Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii" X-Country: CZ X-Abuse: abuse@seznam.cz X-Seznam-User: Kaminar@seznam.cz X-Virus-Info: clean X-Seznam-SPF: neutral X-Seznam-DomainKeys: neutral Subject: Problem with connecting external HDD ADATA CH11 1TB USB 3.0 X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Sep 2011 08:33:11 -0000 Hi, I bought external HDD ADATA CH11 1TB USB 3.0 (compatible with USB2.0). I have problem to connect HDD to FreeBSD box. I post my problem on FreeBSD forum (the thread on FreeBSD forum is http://forums.freebsd.org/showthread.php?t=26082). People on forum suggest to me to send problem here. I enclosure summary of everything of what I observed. HDD: external HDD ADATA CH11 1TB USB 3.0 (compatible with USB2.0), 2.5inch size without cable power supply. After HDD connection to USB2.0 on desktop PC with FreeBSD 8.1R I got error messages: Code: kernel: usb_alloc_device: set address 2 failed (USB_ERR_STALLED, ignored) kernel: usb_alloc_device: getting device descriptor at addr 2 failed, USB_ERR_STALLED kernel: usbd_req_re_enumerate: addr=2, set address failed! (USB_ERR_STALLED, ignored) kernel: usbd_req_re_enumerate: getting device descriptor at addr 2 failed, USB_ERR_STALLED kernel: usbd_req_re_enumerate: addr=2, set address failed! (USB_ERR_STALLED, ignored) kernel: usbd_req_re_enumerate: getting device descriptor at addr 2 failed, USB_ERR_STALLED kernel: ugen4.2: <(null)> at usbus4 (disconnected) kernel: uhub_reattach_port: could not allocate new device In this thread http://forums.freebsd.org/showthread.php?t=25386 I found somebody solved similar problem by connecting disk within USB hub. I tried three hubs. Every USB hubs have not power supply. With the first USB hub I got: ----------------------------- Code: kernel: ugen4.2: at usbus4 kernel: uhub9: on usbus4 kernel: uhub9: 4 ports with 4 removable, self powered root: Unknown USB device: vendor 0x125f product 0xa11a bus uhub9 kernel: ugen4.3: at usbus4 kernel: umass0: on usbus4 kernel: umass0: SCSI over Bulk-Only; quirks = 0x0000 kernel: umass0:14:0:-1: Attached to scbus14 No success. No device appeared. It looks like USB hub seems not to properly powering HDD. The HDD probably was not spinning and there was only hearing quiet ticking from HDD. After disconnecting disk I got: Code: kernel: ugen4.3: at usbus4 (disconnected) kernel: umass0: at uhub9, port 4, addr 3 (disconnected) kernel: (probe0:umass-sim0:0:0:0): AutoSense failed kernel: ugen4.2: at usbus4 (disconnected) kernel: uhub9: at uhub4, port 2, addr 2 (disconnected) With the second USB hub I got: ------------------------------ Code: kernel: ugen8.2: at usbus8 kernel: uhub9: on usbus8 kernel: uhub9: 4 ports with 4 removable, self powered root: Unknown USB device: vendor 0x125f product 0xa11a bus uhub9 kernel: ugen8.3: at usbus8 kernel: umass0: on usbus8 kernel: umass0: SCSI over Bulk-Only; quirks = 0x0000 kernel: umass0:14:0:-1: Attached to scbus14 kernel: (probe0:umass-sim0:0:0:0): AutoSense failed kernel: ugen8.3: at usbus8 (disconnected) kernel: umass0: at uhub9, port 3, addr 3 (disconnected) kernel: ugen8.2: at usbus8 (disconnected) kernel: uhub9: at uhub8, port 2, addr 2 (disconnected) No success. No device appeared. With the third USB hub I got: ----------------------------- Code: kernel: ugen8.2: at usbus8 kernel: uhub9: on usbus8 kernel: uhub9: 4 ports with 4 removable, self powered root: Unknown USB device: vendor 0x125f product 0xa11a bus uhub9 kernel: ugen8.3: at usbus8 kernel: umass0: on usbus8 kernel: umass0: SCSI over Bulk-Only; quirks = 0x0000 kernel: umass0:14:0:-1: Attached to scbus14 kernel: da0 at umass-sim0 bus 0 scbus14 target 0 lun 0 kernel: da0: Fixed Direct Access SCSI-5 device kernel: da0: 40.000MB/s transfers kernel: da0: 953869MB (1953525168 512 byte sectors: 255H 63S/T 121601C) kernel: ugen8.3: at usbus8 (disconnected) kernel: umass0: at uhub9, port 3, addr 3 (disconnected) kernel: (da0:umass-sim0:0:0:0): lost device kernel: (da0:umass-sim0:0:0:0): removing device entry kernel: ugen8.2: at usbus8 (disconnected) kernel: uhub9: at uhub8, port 2, addr 2 (disconnected) With the third USB hub it seems HDD is working. The disk was preformated to FAT32. I tried to copy one small file and delete it. It works. But why doesn't it work if HDD is connected directly to PC or within 1st or 2nd USB hub? The third USB hub is not mine and I am afraid it is not on market yet. Due to I need other solution to use my external HDD. Linux box (Ubuntu 10.04): ------------------------- I tried it on Linux box too (on Ubuntu 10.04 which is on different computer than my FreeBSD is installed). HDD directly plugged to computer's USB2.0 connector was automatically mounted and it seems to work. But in messages appeared some error: Code: usb 1-7: new high speed USB device using ehci_hcd and address 4 usb 1-7: configuration #1 chosen from 1 choice Initializing USB Mass Storage driver... scsi4 : SCSI emulation for USB Mass Storage devices usbcore: registered new interface driver usb-storage USB Mass Storage support registered. usb-storage: device found at 4 usb-storage: waiting for device to settle before scanning usb-storage: device scan complete scsi 4:0:0:0: Direct-Access ADATA CH11 GL00 PQ: 0 ANSI: 5 sd 4:0:0:0: Attached scsi generic sg3 type 0 sd 4:0:0:0: [sdc] 1953525168 512-byte logical blocks: (1.00 TB/931 GiB) sd 4:0:0:0: [sdc] Write Protect is off sd 4:0:0:0: [sdc] Mode Sense: 23 00 00 00 sd 4:0:0:0: [sdc] Assuming drive cache: write through sd 4:0:0:0: [sdc] Assuming drive cache: write through sdc: sdc1 sd 4:0:0:0: [sdc] Assuming drive cache: write through sd 4:0:0:0: [sdc] Attached SCSI disk sd 4:0:0:0: [sdc] Sense Key : Recovered Error [current] [descriptor] Descriptor sense data with sense descriptors (in hex): 72 01 04 1d 00 00 00 0e 09 0c 00 00 00 00 00 00 00 4f 00 c2 00 50 sd 4:0:0:0: [sdc] ASC=0x4 ASCQ=0x1d On the Internet this Linux bug is mentioned, but I didn't find any solution. Livecd FreeBSD 9.0-BETA1: -------------------------------- I tried my external HDD under FreeBSD 9.0-BETA1 (same computer where my FreeBSD 8.1R is installed). After I connected HDD to USB2.0 port, same problem appeared as in my first post in this email. After connecting HDD to USB3.0 I got this messages with some error: Code: ugen4.2: at usbus4 umass0: on usbus4 umass0: SCSI over Bulk-Only; quirks = 0x0000 umass0:15:0:-1: Attached to scbus15 (probe0:umass-sim0:0:0:0): REPORT LUNS. CDB: a0 0 0 0 0 0 0 0 0 10 0 0 (probe0:umass-sim0:0:0:0): CAM status: SCSI Status Error (probe0:umass-sim0:0:0:0): SCSI status: Check Condition (probe0:umass-sim0:0:0:0): SCSI sense: ILLEGAL REQUEST asc:20,0 (Invalid command operation code) da0 at umass-sim0 bus 0 scbus15 target 0 lun 0 da0: Fixed Direct Access SCSI-5 device da0: 400.000MB/s transfers da0: 953869MB (1953525168 512 byte sectors: 255H 63S/T 121601C) It seems that HDD would probably work. I tried to mount it and write one file. The information about error on the Internet is messy for me. After unplugging HDD I got: Code: ugen4.2: at usbus4 (disconnected) umass0: at uhub4, port 1, addr 1 (disconnected) (da0:umass-sim0:0:0:0): lost device - 0 outstanding (da0:umass-sim0:0:0:0): removing device entry Could you give me some suggestion what is wrong? Regards, Karel From owner-freebsd-usb@FreeBSD.ORG Mon Sep 5 09:01:58 2011 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 49CBD106566B for ; Mon, 5 Sep 2011 09:01:58 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe08.c2i.net [212.247.154.226]) by mx1.freebsd.org (Postfix) with ESMTP id B25088FC0A for ; Mon, 5 Sep 2011 09:01:57 +0000 (UTC) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.1 cv=ZrWDMTID0AMW4DNRKF44fvigJaUxxg2ESvddpUoMqyA= c=1 sm=1 a=SvYTsOw2Z4kA:10 a=IUYnjQNxkLsA:10 a=WQU8e4WWZSUA:10 a=8nJEP1OIZ-IA:10 a=CL8lFSKtTFcA:10 a=i9M/sDlu2rpZ9XS819oYzg==:17 a=6I5d2MoRAAAA:8 a=qB6NwLU-MJDBIFk5aAcA:9 a=cqd6EKI2aanlQauoPv0A:7 a=wPNLvfGTeEIA:10 a=tlJW8gxtbz4A:10 a=QodEIyiujl0dJqZw:21 a=sCCm7BgtK0Lb5hYW:21 a=i9M/sDlu2rpZ9XS819oYzg==:117 Received: from [188.126.198.129] (account mc467741@c2i.net HELO laptop002.hselasky.homeunix.org) by mailfe08.swip.net (CommuniGate Pro SMTP 5.2.19) with ESMTPA id 175461799; Mon, 05 Sep 2011 11:01:54 +0200 From: Hans Petter Selasky To: freebsd-usb@freebsd.org Date: Mon, 5 Sep 2011 10:59:15 +0200 User-Agent: KMail/1.13.5 (FreeBSD/8.2-STABLE; KDE/4.4.5; amd64; ; ) References: <36906.1460.1877-31416-1359865944-1315210148@seznam.cz> In-Reply-To: <36906.1460.1877-31416-1359865944-1315210148@seznam.cz> X-Face: *nPdTl_}RuAI6^PVpA02T?$%Xa^>@hE0uyUIoiha$pC:9TVgl.Oq, NwSZ4V"|LR.+tj}g5 %V,x^qOs~mnU3]Gn; cQLv&.N>TrxmSFf+p6(30a/{)KUU!s}w\IhQBj}[g}bj0I3^glmC( :AuzV9:.hESm-x4h240C`9=w MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201109051059.16048.hselasky@c2i.net> Cc: Kaminar Subject: Re: Problem with connecting external HDD ADATA CH11 1TB USB 3.0 X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Sep 2011 09:01:58 -0000 On Monday 05 September 2011 10:09:08 Kaminar wrote: > Hi, > > I bought external HDD ADATA CH11 1TB USB 3.0 (compatible with USB2.0). I > have problem to connect HDD to FreeBSD box. I post my problem on FreeBSD > forum (the thread on FreeBSD forum is > http://forums.freebsd.org/showthread.php?t=26082). People on forum suggest > to me to send problem here. I enclosure summary of everything of what I > observed. > > HDD: external HDD ADATA CH11 1TB USB 3.0 (compatible with USB2.0), 2.5inch > size without cable power supply. > > After HDD connection to USB2.0 on desktop PC with FreeBSD 8.1R I got error > messages: > > Code: > > kernel: usb_alloc_device: set address 2 failed (USB_ERR_STALLED, ignored) > kernel: usb_alloc_device: getting device descriptor at addr 2 failed, > USB_ERR_STALLED kernel: usbd_req_re_enumerate: addr=2, set address failed! > (USB_ERR_STALLED, ignored) kernel: usbd_req_re_enumerate: getting device > descriptor at addr 2 failed, USB_ERR_STALLED kernel: > usbd_req_re_enumerate: addr=2, set address failed! (USB_ERR_STALLED, > ignored) kernel: usbd_req_re_enumerate: getting device descriptor at addr > 2 failed, USB_ERR_STALLED kernel: ugen4.2: <(null)> at usbus4 > (disconnected) > kernel: uhub_reattach_port: could not allocate new device > > > In this thread http://forums.freebsd.org/showthread.php?t=25386 I found > somebody solved similar problem by connecting disk within USB hub. I tried > three hubs. Every USB hubs have not power supply. > > > With the first USB hub I got: > ----------------------------- > > Code: > > kernel: ugen4.2: at usbus4 > kernel: uhub9: on > usbus4 kernel: uhub9: 4 ports with 4 removable, self powered > root: Unknown USB device: vendor 0x125f product 0xa11a bus uhub9 > kernel: ugen4.3: at usbus4 > kernel: umass0: on usbus4 > kernel: umass0: SCSI over Bulk-Only; quirks = 0x0000 > kernel: umass0:14:0:-1: Attached to scbus14 > > No success. No device appeared. It looks like USB hub seems not to properly > powering HDD. The HDD probably was not spinning and there was only hearing > quiet ticking from HDD. > > After disconnecting disk I got: > > Code: > > kernel: ugen4.3: at usbus4 (disconnected) > kernel: umass0: at uhub9, port 4, addr 3 (disconnected) > kernel: (probe0:umass-sim0:0:0:0): AutoSense failed > kernel: ugen4.2: at usbus4 (disconnected) > kernel: uhub9: at uhub4, port 2, addr 2 (disconnected) > > > With the second USB hub I got: > ------------------------------ > > Code: > > kernel: ugen8.2: at usbus8 > kernel: uhub9: > on usbus8 kernel: uhub9: 4 ports with 4 removable, self powered > root: Unknown USB device: vendor 0x125f product 0xa11a bus uhub9 > kernel: ugen8.3: at usbus8 > kernel: umass0: on usbus8 > kernel: umass0: SCSI over Bulk-Only; quirks = 0x0000 > kernel: umass0:14:0:-1: Attached to scbus14 > > kernel: (probe0:umass-sim0:0:0:0): AutoSense failed > kernel: ugen8.3: at usbus8 (disconnected) > kernel: umass0: at uhub9, port 3, addr 3 (disconnected) > kernel: ugen8.2: at usbus8 (disconnected) > kernel: uhub9: at uhub8, port 2, addr 2 (disconnected) > > No success. No device appeared. > > > With the third USB hub I got: > ----------------------------- > > Code: > > kernel: ugen8.2: at usbus8 > kernel: uhub9: > on usbus8 kernel: uhub9: 4 ports with 4 removable, self powered > root: Unknown USB device: vendor 0x125f product 0xa11a bus uhub9 > kernel: ugen8.3: at usbus8 > kernel: umass0: on usbus8 > kernel: umass0: SCSI over Bulk-Only; quirks = 0x0000 > kernel: umass0:14:0:-1: Attached to scbus14 > kernel: da0 at umass-sim0 bus 0 scbus14 target 0 lun 0 > kernel: da0: Fixed Direct Access SCSI-5 device > kernel: da0: 40.000MB/s transfers > kernel: da0: 953869MB (1953525168 512 byte sectors: 255H 63S/T 121601C) > kernel: ugen8.3: at usbus8 (disconnected) > kernel: umass0: at uhub9, port 3, addr 3 (disconnected) > kernel: (da0:umass-sim0:0:0:0): lost device > kernel: (da0:umass-sim0:0:0:0): removing device entry > kernel: ugen8.2: at usbus8 (disconnected) > kernel: uhub9: at uhub8, port 2, addr 2 (disconnected) > > With the third USB hub it seems HDD is working. The disk was preformated to > FAT32. I tried to copy one small file and delete it. It works. > > But why doesn't it work if HDD is connected directly to PC or within 1st or > 2nd USB hub? The third USB hub is not mine and I am afraid it is not on > market yet. Due to I need other solution to use my external HDD. > > > Linux box (Ubuntu 10.04): > ------------------------- > > I tried it on Linux box too (on Ubuntu 10.04 which is on different computer > than my FreeBSD is installed). HDD directly plugged to computer's USB2.0 > connector was automatically mounted and it seems to work. But in messages > appeared some error: > > Code: > > usb 1-7: new high speed USB device using ehci_hcd and address 4 > usb 1-7: configuration #1 chosen from 1 choice > Initializing USB Mass Storage driver... > scsi4 : SCSI emulation for USB Mass Storage devices > usbcore: registered new interface driver usb-storage > USB Mass Storage support registered. > usb-storage: device found at 4 > usb-storage: waiting for device to settle before scanning > usb-storage: device scan complete > scsi 4:0:0:0: Direct-Access ADATA CH11 GL00 PQ: 0 ANSI: > 5 sd 4:0:0:0: Attached scsi generic sg3 type 0 > sd 4:0:0:0: [sdc] 1953525168 512-byte logical blocks: (1.00 TB/931 GiB) > sd 4:0:0:0: [sdc] Write Protect is off > sd 4:0:0:0: [sdc] Mode Sense: 23 00 00 00 > sd 4:0:0:0: [sdc] Assuming drive cache: write through > sd 4:0:0:0: [sdc] Assuming drive cache: write through > sdc: sdc1 > sd 4:0:0:0: [sdc] Assuming drive cache: write through > sd 4:0:0:0: [sdc] Attached SCSI disk > sd 4:0:0:0: [sdc] Sense Key : Recovered Error [current] [descriptor] > Descriptor sense data with sense descriptors (in hex): > 72 01 04 1d 00 00 00 0e 09 0c 00 00 00 00 00 00 > 00 4f 00 c2 00 50 > sd 4:0:0:0: [sdc] ASC=0x4 ASCQ=0x1d > > On the Internet this Linux bug is mentioned, but I didn't find any > solution. > > > Livecd FreeBSD 9.0-BETA1: > -------------------------------- > > I tried my external HDD under FreeBSD 9.0-BETA1 (same computer where my > FreeBSD 8.1R is installed). After I connected HDD to USB2.0 port, same > problem appeared as in my first post in this email. After connecting HDD to > USB3.0 I got this messages with some error: > > Code: > > ugen4.2: at usbus4 > umass0: on usbus4 > umass0: SCSI over Bulk-Only; quirks = 0x0000 > umass0:15:0:-1: Attached to scbus15 > (probe0:umass-sim0:0:0:0): REPORT LUNS. CDB: a0 0 0 0 0 0 0 0 0 10 0 0 > (probe0:umass-sim0:0:0:0): CAM status: SCSI Status Error > (probe0:umass-sim0:0:0:0): SCSI status: Check Condition > (probe0:umass-sim0:0:0:0): SCSI sense: ILLEGAL REQUEST asc:20,0 (Invalid > command operation code) da0 at umass-sim0 bus 0 scbus15 target 0 lun 0 > da0: Fixed Direct Access SCSI-5 device > da0: 400.000MB/s transfers > da0: 953869MB (1953525168 512 byte sectors: 255H 63S/T 121601C) > > It seems that HDD would probably work. I tried to mount it and write one > file. The information about error on the Internet is messy for me. > > After unplugging HDD I got: > > Code: > > ugen4.2: at usbus4 (disconnected) > umass0: at uhub4, port 1, addr 1 (disconnected) > (da0:umass-sim0:0:0:0): lost device - 0 outstanding > (da0:umass-sim0:0:0:0): removing device entry > > > Could you give me some suggestion what is wrong? Hi, Is it possible you could try a 9-BETA live CD and see if there are any differences? There has been some changes regarding how enumeration works between 8.1R and 8.2 stable / 9.X. There are many reasons that a USB device won't work. It is not always possible to fix. Thanks for all the logs. Could you dump the USB speed of your device in all the different cases using usbconfig? --HPS From owner-freebsd-usb@FreeBSD.ORG Mon Sep 5 11:07:20 2011 Return-Path: Delivered-To: freebsd-usb@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A3564106566C for ; Mon, 5 Sep 2011 11:07:20 +0000 (UTC) (envelope-from owner-bugmaster@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 908028FC19 for ; Mon, 5 Sep 2011 11:07:20 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p85B7K1h066039 for ; Mon, 5 Sep 2011 11:07:20 GMT (envelope-from owner-bugmaster@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p85B7Jc7066037 for freebsd-usb@FreeBSD.org; Mon, 5 Sep 2011 11:07:19 GMT (envelope-from owner-bugmaster@FreeBSD.org) Date: Mon, 5 Sep 2011 11:07:19 GMT Message-Id: <201109051107.p85B7Jc7066037@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: gnats set sender to owner-bugmaster@FreeBSD.org using -f From: FreeBSD bugmaster To: freebsd-usb@FreeBSD.org Cc: Subject: Current problem reports assigned to freebsd-usb@FreeBSD.org X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Sep 2011 11:07:20 -0000 Note: to view an individual PR, use: http://www.freebsd.org/cgi/query-pr.cgi?pr=(number). The following is a listing of current problems submitted by FreeBSD users. These represent problem reports covering all versions including experimental development code and obsolete releases. S Tracker Resp. Description -------------------------------------------------------------------------------- o usb/160436 usb ucom wedges machine on parity error ? o usb/160301 usb [patch] missing device usb and device ucom entries in o usb/160299 usb MicroSDHC-to-USB adapters do not work in FreeBSD 8.x o usb/160192 usb [install] Installation from USB-Stick doesn't find the o usb/159611 usb [PATCH] USB stick extrememory Snippy needs quirks o usb/159274 usb USB 3.0 Etron EJ168A does not work. f usb/159191 usb [fusefs-ntfs] write on fusefs-ntfs mounted partition r o usb/157376 usb LaCie USB disk not recognized o usb/156898 usb [keyboard] usb keyboard does not work while boot (ps2 o usb/156735 usb Need Quirk for Goflex USB Disk Drives o usb/156725 usb USB stack stall cause complete system input loss o usb/156596 usb [ehci] Extremely high interrupt rate on ehci/uhci IRQ1 o usb/156000 usb rum(4) Fatal trap 18: integer divide fault while in ke o usb/155996 usb NanoBSD not booted as Disk o usb/155784 usb Problem with Transcend StoreJet 25M3 (2AJ1) on Asus M2 o usb/155663 usb [usbdevs] [patch] Add support for Supertop Nano 1GB US o usb/155496 usb [usb][patch] support BUFFALO WLI-U2-SG54HG wireless o usb/154753 usb [usbdevs] [patch] Support for Qualcomm USB modem/stora o usb/154710 usb [ugen] Conexant USB Modem is not working in 8.x. In 7. o usb/154506 usb [umass] Copying dir with large files makes FreeBSD loa o usb/154192 usb [umass] In Garmin Oregon GPS, only the first umass dev o i386/153851 usb [keyboard] keyboard issues on new Intel Mother boards. o usb/153703 usb [keyboard] My USB keyboard can not be used in 8-STABLE o usb/153609 usb [zyd] [panic] kernel: Fatal trap 12: page fault while o usb/153599 usb [usbdevs] [patch] Feiya Elango USB MicroSD reader sync o usb/153149 usb [umass] USB stick quirk regression [regression] o usb/152075 usb [usb8] [ehci] [request] Add quirk for CS5536 USB o usb/150892 usb [zyd] Whenever network contacted in any shape, way or o usb/150189 usb [run] [usb8] [patch] if_run appears to corrupt IP traf p usb/149934 usb [patch] [usb8] Transcend JetFlash V85 poor performance p usb/149900 usb [uftdi] [patch] FreeBSD 8.1 uftdi patch to support usb p usb/149764 usb [u3g] [patch] usbdevs update: Huawei K3765 3G modem o usb/149283 usb [uftdi] avrdude unable to talk to Arduino board (via u o usb/149162 usb [ural] ASUS WL-167g doesn't work in 8.1 (continue of 1 s usb/148702 usb [usb8] [request] IO DATA USB-RSAQ5 support on FreeBSD- o usb/148080 usb usbconfig(8) sometimes does not turn off the device o usb/147516 usb [umass] [usb67] kernel unable to deal with Olympus USB o i386/147475 usb [install] FreeBSD 8.x does not install on ASUS K8N4-E p usb/146871 usb [usbdevs] [usb8] [patch] provide descriprive string fo o usb/146840 usb [hang] FreeBSD 7.2 / 7.3 / 8.0 hang at startup after e o usb/146153 usb [axe] [usb8] Hosts in network doesn't receive any pack f usb/146054 usb [urtw] [usb8] urtw driver potentially out of date f usb/145513 usb [usb8] New USB stack: no new devices after forced usb p usb/145455 usb [usb8] [patch] USB debug support cannot be disabled o usb/145415 usb [umass] [usb8] USB card reader does not create slices a usb/145184 usb GENERIC can't mount root from USB on Asus EEE o usb/145165 usb [keyboard] [usb8] ukbd_set_leds_callback: error=USB_ER f kern/144938 usb [keyboard] [boot] Boot Failure with Apple (MB869LL/A) o usb/144387 usb [run] [panic] if_run panic o usb/144043 usb [umass] [usb8] USB DLT tape drive throws random errors a usb/143790 usb [boot] [cam] can not boot from usb hdd f usb/143620 usb [cdce] [usb8] the module if_cdce doesn't support my Op f usb/143294 usb [usb8] copying process stops at some time (10 - 50 sec o usb/143286 usb [ukbd] [usb8] [boot] boot failures on RELENG_8 system p usb/143186 usb [usbdevs] [usb8] [patch] add USB device IDs for Google a usb/143139 usb [umass] [usb8] [patch] Quirk for Century EX35SW4_SB4 J o usb/143045 usb [umass] [usb8] [patch] mounting Fujitsu 2600Z camera d o usb/142991 usb [uftdi] [usb67] [patch] Patch to add Crystalfontz 533 f usb/142989 usb [usb8] canon eos 50D attaches but detaches after few s f usb/142957 usb [umass] [usb8] [patch] patch for USB disk SYNCHRONIZE o usb/142719 usb [urtw] [usb8] AirLive WL-1600USB (RTL8187L chipset) fa o usb/142713 usb [usb67] [panic] Kernel Panik when connecting an IPhone f usb/142276 usb [umass] [usb8] Cache Synchronization Error with Olympu o usb/142229 usb [ums] [usb8] [hang] connecting a USB mouse to a Dell P f usb/141680 usb [uath] [usb8] Netgear WG111T not working with uath dri o usb/141664 usb [pcm] [usb8] Logitech USB microphone failure [regressi o usb/141474 usb [boot] [usb8] FreeBSD 8.0 can not install from USB CDR o usb/141327 usb [ukbd] [usb67] USB kbd not working with 7.1+PAE on IBM o usb/141212 usb [ukbd] [usb8] ukbd_set_leds_callback:700: error=USB_ER o kern/141011 usb [usb8] Encrypted root, geli password at boot; enter ke o usb/140920 usb [install] [usb8] USB based install fails on 8.0-RELEAS o usb/140893 usb [urtw] [usb8] WPA2 not working on rtl8187b o kern/140849 usb [ums] [usb8] USB mouse doesn't work under FreeBSD 8.0- a usb/140810 usb [uftdi] [usb8] 8.X copy and paste problem / tty overfl o usb/140477 usb [umass] [usb8] [patch] allow boot-time attachment of d o usb/140236 usb [msdosfs] [usb8] Labels wiped on external Journaled US o usb/140160 usb [usb8] [acpi] USB ports are no longer "active" after A s usb/139990 usb [panic] [patch] [usb67] Kernel frequently panics after a usb/139598 usb [umass] [usb8] CAM reports "xptioctl: put "device pass o usb/139243 usb [uhci] [usb67] unplug prolific USB serial -> uhci_abor f usb/138882 usb [ohci] [panic] [usb67] Can't install FreeBSD 7.2 due t o usb/138798 usb [boot] [usb8] 8.0-BETA4 can't boot from USB flash driv o usb/138659 usb [usb8][uftdi] driver broken in RELENG_8/CURRENT s usb/138570 usb [usb67] [panic] USB mass device panics current 7.2-STA o usb/138175 usb [usb67] [boot] System cannot boot, when USB reader wit o usb/138124 usb [snd_uaudio] [usb8] Axed uaudio functionality in the u o usb/138119 usb [usb67] [usb8] MultiBay CDROM (probably on USB bus) is o usb/137872 usb [usb67] [boot] slow booting on usb flash drive o usb/137806 usb [ukbd] [usb67] USB keyboard doesn't work until it's un o usb/137763 usb [usb67][ukbd] Logitech wireless keyboard media keys no o usb/137377 usb [usb8] request support for Huawei E180 o usb/137341 usb [usb8][rum] driver if_rum doesn't work at all and thro f usb/137190 usb [usb8][patch] inhibit spurious button releases for som o usb/137189 usb [usb8][patch] create and use sysctl nodes for HID repo p usb/137188 usb [usb8][patch] correctly handle USB report descriptors o usb/137129 usb [ums] [usb8] SteelSeries Ikari USB laser mouse not att p usb/136761 usb [usbdevs][usb67][patch] Teach usbdevs / u3g(4) about H o usb/135938 usb [aue] [usb67] aue driver only passes traffic in promis o usb/135542 usb [keyboard] boot loader does not work with a usb keyboa o usb/135348 usb [umass] [patch] USB Drive Hangs with ZFS (JMicron USB2 o usb/135206 usb machine reboots when inserted USB device f usb/135200 usb SAMSUNG i740 usb mass: Synchronize cache failed, statu o usb/135182 usb UMASS quirk - Olympus FE20 camera o usb/134950 usb Lowering DTR for USB-modem via ubsa is not possible o usb/134299 usb Kernel Panic plugging in MF626 USB UMTS Stick u3g o usb/134193 usb System freeze on usb MP3 player insertion o usb/134085 usb [umass] Adding usb quirk for Sony USB flash drive o usb/133989 usb [usb8] [ukbd] USB keyboard dead at mountroot> prompt o usb/133712 usb [ural] [patch] RE: Fixed an issue with ural(4) that wa o usb/133390 usb umass crashes system in 7.1 when Olympus D-540 attache o usb/133296 usb [rum] driver not working properly in hostap mode o usb/132594 usb USB subsystem causes page fault and crashes o usb/132080 usb [patch] [usb] [rum] [panic] Kernel panic after NOMEM c o usb/132066 usb [ukbd] Keyboard failure USB keyboard DELL 760 o usb/132036 usb [panic] page fault when connecting Olympus C740 camera o usb/131583 usb [umass] Failure when detaching umass Device o usb/131576 usb [aue] ADMtek USB To LAN Converter can't send data o usb/131521 usb Registering Belkin UPS to usb_quirks.c p usb/131123 usb [patch] [usb67] re-add UQ_ASSUME_CM_OVER_DATA USB quir o usb/131074 usb no run-time detection of usb devices plugged into exte o usb/130736 usb Page fault unplugging USB stick o usb/130230 usb [patch] [quirk] [usb67] [usb] [cam] [umass] Samsung El o usb/130208 usb Boot process severely hampered by umass0 error o usb/130122 usb [usb8] DVD drive detects as 'da' device f usb/129766 usb [usb] [panic] plugging in usb modem HUAWEI E226 panics o usb/129500 usb [umass] [panic] FreeBSD Crashes when connecting SanDis o usb/129311 usb [usb] [panic] Instant crash with an USB card reader s usb/128990 usb [usb] u3g does not handle RTS/CTS available on for exa o usb/128977 usb [usb67] [patch] uaudio is not full duplex p usb/128803 usb [usbdevs] [patch] Quirk for I-Tuner Networks USBLCD4X2 o usb/128485 usb [umodem] [patch] Nokia N80 modem support o usb/128425 usb [umass] Cannot Connect Maxtor Onetouch 4 USB drive o usb/128418 usb [panic] [rum] loading if_rum causes panic, looks like o usb/127926 usb [boot] USB Timeout during bootup s usb/127453 usb [request] ubsa, uark, ubser, uftdi, and friends should o usb/127342 usb [boot] [panic] enabling usb keyboard and mouse support o usb/127248 usb [ucom] panic while uplcom devices attach and detach o usb/126884 usb [ugen] [patch] Bug in buffer handling in ugen.c o usb/126848 usb [usb]: USB Keyboard hangs during Installation o usb/126740 usb [ulpt] doesn't work on 7.0-RELEASE, 10 second stall be o usb/126519 usb [usb] [panic] panic when plugging in an iphone o kern/126396 usb [panic] kernel panic after unplug USB Bluetooth device o usb/125631 usb [ums] [panic] kernel panic during bootup while 'Logite o usb/125510 usb [panic] repeated plug and unplug of USB mass storage d o usb/125450 usb [panic] Removing USB flash card while being accessed c o usb/125088 usb [keyboard] Touchpad not detected on Adesso AKB-430UG U o usb/124980 usb [panic] kernel panic on detaching unmounted umass devi o kern/124777 usb [ucom] USB cua devices don't revert to tty devices whe o usb/124758 usb [rum] [panic] rum panics SMP kernel o usb/124708 usb [panic] Kernel panic on USB KVM reattach o kern/124130 usb [usb] gmirror fails to start usb devices that were pre o usb/123969 usb [usb] Supermicro H8SMi-2 usb problem: port reset faile o usb/123714 usb [usb] [panic] Panic when hald-storage-probe runs with o usb/123691 usb usbd(8): usbd hangs o usb/123690 usb [usb] [panic] Panic on USB device insertion when usb l o usb/123611 usb [usb] BBB reset failed, STALLED from Imation/Mitsumi U o usb/122992 usb [umass] [patch] MotoROKR Z6 Phone not recognised by um o usb/122936 usb [ucom] [ubsa] Device does not receive interrupt o usb/122905 usb [ubsa] [patch] add Huawei E220 to ubsa s usb/122819 usb [usb67] [patch] Patch to provide dynamic additions to o usb/122813 usb [udbp] [request] udbp driver should be removed in favo o usb/122547 usb [ehci] USB Printer not being recognized after reboot o usb/122539 usb [ohci] [panic] AnyDATA ADU-E1000D - kernel panic: ohci o usb/122483 usb [panic] [ulpt] Repeatable panic in 7.0-STABLE o usb/122119 usb [umass] umass device causes creation of daX but not da o usb/121755 usb [ohci] [patch] Fix panic after ohci/uhub cardbus devic o usb/121734 usb [ugen] ugen HP1022 printer device not working since up o usb/121708 usb [keyboard] nforce 650i mobo w/ usb keyboard infinite k o usb/121474 usb [cam] [patch] QUIRK: SAMSUNG HM250JI in LaCie usb hard o usb/121275 usb [boot] [panic] FreeBSD fails to boot with usb legacy s f usb/121232 usb [usb67] [panic] USB CardBus card removal causes reboot o usb/121169 usb [umass] Issues with usb mp3 player o usb/121045 usb [uftdi] [patch] Add support for PC-OP-RS1 and KURO-RS f usb/120786 usb [usb] [panic] Kernel panic when forced umount of a det o usb/120729 usb [panic] fault while in kernel mode with connecting USB o usb/120321 usb [hang] System hangs when transferring data to WD MyBoo o usb/120283 usb [panic] Automation reboot with wireless keyboard & mou o usb/120034 usb [hang] 6.2 & 6.3 hangs on boot at usb0: OHCI with 1.5 o usb/119977 usb [ums] Mouse does not work in a Cherry-USB keyboard/mou o usb/119653 usb [cam] [patch] iriver s7 player sync cache error patch o usb/119633 usb [umass] umass0: BBB reset failed, IOERROR [regression] o usb/119509 usb [usb] USB flaky on Dell Optiplex 755 o usb/119389 usb [umass] Sony DSC-W1 CBI reset failed, STALLED [regress o usb/119227 usb [ubsa] [patch] ubsa buffer is too small; should be tun o usb/119201 usb [cam] [patch] Quirks for Olympus FE-210 camera, LG and o usb/118480 usb [umass] Timeout in USB mass storage freezes vfs layer o usb/118353 usb [panic] [ppp] repeatable kernel panic during ppp(4) se o usb/118141 usb [ucom] usb serial and nokia phones ucomreadcb ucomread o usb/118140 usb [ucom] [patch] quick hack for ucom to get it behave wi o usb/118098 usb [umass] 6th gen iPod causes problems when disconnectin o usb/117955 usb [umass] [panic] inserting minolta dimage a2 crashes OS o usb/117946 usb [panic] D-Link DUB-E100 rev. B1 crashes FreeBSD 7.0-BE o usb/117938 usb [ums] [patch] Adding support for MS WL Natural and MS o usb/117911 usb [ums] [request] Mouse Gembird MUSWC not work o usb/117893 usb [umass] Lacie USB DVD writing failing o usb/117613 usb [uhci] [irq] uhci interrupt storm & USB leaked memory o usb/117598 usb [snd_uaudio] [patch] Not possible to record with Plant o usb/117313 usb [umass] [panic] panic on usb camera insertion o usb/117200 usb [ugen] ugen0 prints strange string on attach if detach o usb/117183 usb [panic] USB/fusefs -- panic while transferring large a p usb/116947 usb [ukbd] [patch] [regression] enable boot protocol on th o usb/116561 usb [umodem] [panic] RELENG_6 umodem panic "trying to slee o usb/116282 usb [ulpt] Cannot print on USB HP LJ1018 or LJ1300 o usb/115935 usb [usbdevs] [patch] kernel counterproductively attaches o usb/115933 usb [uftdi] [patch] RATOC REX-USB60F (usb serial converter o usb/115400 usb [ehci] Problem with EHCI on ASUS M2N4-SLI o usb/115298 usb [ulpt] [panic] Turning off USB printer panics kernel o usb/114916 usb [umass] [patch] USB Maxtor drive (L300RO) requires qui o kern/114780 usb [uplcom] [panic] Panics while stress testing the uplco o usb/114682 usb [umass] generic USB media-card reader unusable o usb/114310 usb [libusb] [patch] [panic] USB hub attachment panics ker o usb/114068 usb [usb67] [usb8] [umass] [patch] Problem with connection o conf/114013 usb [patch] WITHOUT_USB allow to compil a lot of USB stuff s usb/113060 usb [usb67] [ulpt] [patch] Samsung printer not working in o usb/110856 usb [usb67] [ugen] [patch] interrupt in msgs are truncated o usb/107827 usb [usb67] [ohci] [panic] ohci_add_done addr not found o usb/107388 usb [usb67] [usb8] [new driver] [patch] add utoppy device o usb/106041 usb [usb67] [usb8] [request] FreeBSD does not recognise Mu o usb/105361 usb [usb67] [panic] Kernel panic during unmounting mass st s usb/103917 usb [usb67] [uhub] USB driver reports "Addr 0 should never o usb/103418 usb [usb67] [usb8] [patch] [request] usbhidctl(8) add abil o usb/103046 usb [usb67] [ulpt] [patch] ulpt event driven I/O with sele o usb/101761 usb [usb67] [patch] [request] usb.h: increase maximal size o usb/100746 usb [usb67] [ukbd] system does not boot due to USB keyboar o usb/99431 usb [keyboard] FreeBSD on MSI 6566E (Intel 845E motherboar o kern/99200 usb [usb67] SMP-Kernel crashes reliably when Bluetooth con o usb/98343 usb [boot] BBB reset failed errors with Creative Muvo MP3 o usb/97472 usb [cam] [patch] add support for Olympus C150,D390 s usb/97286 usb [mouse] [request] MS Wireless Intellimouse Explorer 2. o usb/97175 usb [umass] [hang] USB cardreader hangs system o usb/96457 usb [umass] [panic] fatback on umass = reboot o usb/96381 usb [cam] [patch] add a quirk table entry for a flash ram o usb/96224 usb [usb] [msdosfs] mount_msdosfs cause page fault in sync s usb/96120 usb [ums] [request] USB mouse not always detected s usb/95636 usb [umass] [boot] 5 minute delay at boot when using VT620 o usb/95562 usb [umass] Write Stress in USB Mass drive causes "vinvalb f usb/95348 usb [keyboard] USB keyboard unplug causes noise on screen o usb/95037 usb [umass] USB disk not recognized on hot-plug. o usb/94897 usb [panic] Kernel Panic when cleanly unmounting USB disk o usb/94717 usb [ulpt] Reading from /dev/ulpt can break work of a UHCI o usb/94384 usb [panic] kernel panic with usb2 hardware o usb/93872 usb [cam] [patch] SCSI quirk required for ELTA 8061 OL USB o usb/93828 usb [ohci] [panic] ohci causes panic on boot (HP Pavillion o usb/93389 usb [umass] [patch] Digital Camera Pentax S60 don't work o usb/92852 usb [ums] [patch] Vertical scroll not working properly on o usb/92171 usb [panic] panic unplugging Vodafone Mobile Connect (UMTS o usb/92142 usb [uhub] SET_ADDR_FAILED and SHORT_XFER errors from usb o usb/92083 usb [ural] [panic] panic using WPA on ural NIC in 6.0-RELE o usb/92052 usb [ulpt] usbd causes defunct process with busy file-hand o usb/91906 usb [ehci] [hang] FreeBSD hangs while booting with USB leg f usb/91896 usb camcontrol(8): Serial Number of USB Memory Sticks is n o usb/91811 usb [umass] Compact Flash in HP Photosmart 2610 return " o usb/91546 usb [umodem] [patch] Nokia 6630 mobile phone does not work o usb/91538 usb [ulpt] [patch] Unable to print to EPSON CX3500 o usb/91283 usb [boot] [regression] booting very slow with usb devices o usb/91238 usb [umass] USB tape unit fails to write a second tape fil o usb/90700 usb [umass] [panic] Kernel panic on connect/mount/use umas o usb/89954 usb [umass] [panic] USB Disk driver race condition? s usb/89003 usb [request] LaCie Firewire drive not properly supported o usb/88743 usb [hang] [regression] USB makes kernel hang at boot (reg o usb/88408 usb [axe] axe0 read PHY failed o usb/87648 usb [mouse] Logitech USB-optical mouse problem. f usb/87224 usb [usb] Cannot mount USB Zip750 o usb/86767 usb [umass] [patch] bogus "slice starts beyond end of the o usb/86298 usb [mouse] Known good USB mouse won't work with correct s s usb/85067 usb [uscanner] Cannot attach ScanJet 4300C to usb device s usb/84336 usb [usb] [reboot] instant system reboot when unmounting a o usb/83977 usb [ucom] [panic] ucom1: open bulk out error (addr 2): IN o usb/83863 usb [ugen] Communication problem between opensc/openct via o usb/83756 usb [ums] [patch] Microsoft Intellimouse Explorer 4.0A doe o usb/83563 usb [umass] [panic] Page Fault while detaching Mpman Usb d o usb/83504 usb [kernel] [patch] SpeedTouch USB stop working on recent s usb/82569 usb [umass] [panic] USB mass storage plug/unplug causes sy o usb/82520 usb [udbp] [reboot] Reboot when USL101 connected o usb/82350 usb [ucom] [panic] null pointer dereference in USB stack o usb/81621 usb [ehci] [hang] external hd hangs under load on ehci o usb/80935 usb [uvisor] [patch] uvisor.c is not work with CLIE TH55. s usb/80777 usb [request] usb_rem_task() should wait for callback to c s usb/80776 usb [udav] [request] UDAV device driver shouldn't use usb_ o usb/80774 usb [patch] have "usbd_find_desc" in line with the other " o usb/80361 usb [umass] [patch] mounting of Dell usb-stick fails f usb/80040 usb [sound] [hang] Use of sound mixer causes system freeze o usb/79723 usb [usb] [request] prepare for high speed isochronous tra o usb/78984 usb [umass] [patch] Creative MUVO umass failure f usb/77294 usb [ucom] [panic] ucom + ulpcom panic o usb/76653 usb [umass] [patch] Problem with Asahi Optical usb device f usb/76395 usb [uhci] USB printer does not work, usbdevs says "addr 0 s usb/75928 usb [umass] [request] Cytronix SmartMedia card (SMC) reade o usb/75800 usb [ucom] ucom1: init failed STALLED error in time of syn o usb/75764 usb [umass] [patch] "umass0: Phase Error" - no device for f usb/75705 usb [umass] [panic] da0 attach / Optio S4 (with backtrace) f usb/74771 usb [umass] [hang] mounting write-protected umass device a s usb/74453 usb [umass] [patch] Q-lity CD-RW USB ECW-043 (ScanLogic SL o usb/74211 usb [umass] USB flash drive causes CAM status 0x4 on 4.10R o usb/73307 usb [panic] Kernel panics on USB disconnect o usb/71417 usb [ugen] Cryptoflex e-gate USB token (ugen0) communicati o usb/71416 usb [ugen] Cryptoflex e-gate USB token (ugen0) detach is n o usb/71280 usb [aue] aue0 device (linksys usb100tx) doesn't work in 1 o usb/71155 usb [ulpt] misbehaving usb-printer hangs processes, causes o usb/69006 usb [usbdevs] [patch] Apple Cinema Display hangs USB ports o usb/67301 usb [uftdi] [panic] RTS and system panic o usb/66547 usb [ucom] Palm Tungsten T USB does not initialize correct o usb/63621 usb [umass] [panic] USB MemoryStick Reader stalls/crashes s usb/62257 usb [umass] [request] card reader UCR-61S2B is only half-s s bin/57255 usb [patch] usbd(8) and multi-function devices s usb/52026 usb [usb] [request] umass driver support for InSystem ISD2 s usb/51958 usb [urio] [patch] update for urio driver o usb/40948 usb [umass] [request] USB HP CDW8200 does not work o usb/30929 usb [usb] [patch] use usbd to initialize USB ADSL modem 309 problems total. From owner-freebsd-usb@FreeBSD.ORG Mon Sep 5 14:40:04 2011 Return-Path: Delivered-To: freebsd-usb@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EF468106566B for ; Mon, 5 Sep 2011 14:40:03 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id CFDEC8FC08 for ; Mon, 5 Sep 2011 14:40:03 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p85Ee3io066635 for ; Mon, 5 Sep 2011 14:40:03 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p85Ee3rC066634; Mon, 5 Sep 2011 14:40:03 GMT (envelope-from gnats) Date: Mon, 5 Sep 2011 14:40:03 GMT Message-Id: <201109051440.p85Ee3rC066634@freefall.freebsd.org> To: freebsd-usb@FreeBSD.org From: dfilter@FreeBSD.ORG (dfilter service) Cc: Subject: Re: usb/160299: commit references a PR X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: dfilter service List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Sep 2011 14:40:04 -0000 The following reply was made to PR usb/160299; it has been noted by GNATS. From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: usb/160299: commit references a PR Date: Mon, 5 Sep 2011 14:38:12 +0000 (UTC) Author: hselasky Date: Mon Sep 5 14:37:59 2011 New Revision: 225400 URL: http://svn.freebsd.org/changeset/base/225400 Log: Some USB mass storage devices requires that the sense information is retrieved after a failed SCSI command to continue normal operation. Else this sense information is retrived at the next SCSI command. Approved by: re (kib) Reported by: Alex Kozlov MFC after: 1 week PR: usb/160299 Modified: head/sys/dev/usb/usb_msctest.c Modified: head/sys/dev/usb/usb_msctest.c ============================================================================== --- head/sys/dev/usb/usb_msctest.c Mon Sep 5 12:39:15 2011 (r225399) +++ head/sys/dev/usb/usb_msctest.c Mon Sep 5 14:37:59 2011 (r225400) @@ -1,6 +1,6 @@ /* $FreeBSD$ */ /*- - * Copyright (c) 2008 Hans Petter Selasky. All rights reserved. + * Copyright (c) 2008,2011 Hans Petter Selasky. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -83,7 +83,10 @@ enum { DIR_NONE, }; +#define SCSI_MAX_LEN 0x100 #define SCSI_INQ_LEN 0x24 +#define SCSI_SENSE_LEN 0xFF + static uint8_t scsi_test_unit_ready[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; static uint8_t scsi_inquiry[] = { 0x12, 0x00, 0x00, 0x00, SCSI_INQ_LEN, 0x00 }; static uint8_t scsi_rezero_init[] = { 0x01, 0x00, 0x00, 0x00, 0x00, 0x00 }; @@ -98,6 +101,8 @@ static uint8_t scsi_huawei_eject[] = { 0 static uint8_t scsi_tct_eject[] = { 0x06, 0xf5, 0x04, 0x02, 0x52, 0x70 }; static uint8_t scsi_sync_cache[] = { 0x35, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; +static uint8_t scsi_request_sense[] = { 0x03, 0x00, 0x00, 0x00, 0x12, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; #define BULK_SIZE 64 /* dummy */ #define ERR_CSW_FAILED -1 @@ -151,7 +156,7 @@ struct bbb_transfer { uint8_t status_try; int error; - uint8_t buffer[256]; + uint8_t buffer[SCSI_MAX_LEN] __aligned(4); }; static usb_callback_t bbb_command_callback; @@ -661,6 +666,32 @@ usb_msc_auto_quirk(struct usb_device *ud usbd_add_dynamic_quirk(udev, UQ_MSC_NO_SYNC_CACHE); } + /* clear sense status of any failed commands on the device */ + + err = bbb_command_start(sc, DIR_IN, 0, sc->buffer, + SCSI_INQ_LEN, &scsi_inquiry, sizeof(scsi_inquiry), + USB_MS_HZ); + + DPRINTF("Inquiry = %d\n", err); + + if (err != 0) { + + if (err != ERR_CSW_FAILED) + goto error; + } + + err = bbb_command_start(sc, DIR_IN, 0, sc->buffer, + SCSI_SENSE_LEN, &scsi_request_sense, + sizeof(scsi_request_sense), USB_MS_HZ); + + DPRINTF("Request sense = %d\n", err); + + if (err != 0) { + + if (err != ERR_CSW_FAILED) + goto error; + } + done: bbb_detach(sc); return (0); _______________________________________________ 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 owner-freebsd-usb@FreeBSD.ORG Mon Sep 5 15:52:15 2011 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 50B351065678 for ; Mon, 5 Sep 2011 15:52:15 +0000 (UTC) (envelope-from Kaminar@seznam.cz) Received: from mxl1.seznam.cz (mxl1.seznam.cz [77.75.72.44]) by mx1.freebsd.org (Postfix) with ESMTP id 8906C8FC08 for ; Mon, 5 Sep 2011 15:52:14 +0000 (UTC) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=seznam.cz; h=In-Reply-To:Received:Date:To:From:Subject:Mime-Version:Message-Id:Content-Transfer-Encoding:Content-Type:X-Country:X-Abuse:X-Seznam-User; b=DP/CeSlHKBu8Zqptu9ydZeeTKgG8RbI9HNKxRsRZ8M2WAW2tHMXC0xdHUk9PetQmc AELGwEdj57S/S/0TmxbXVjK12I/v2IwLl2TamqsEmd29oWl6sHsbvcIUIL0zD+9eutM epWfvuMsUywljeeLgDrE83xQnsiv/uOp1qt1K7I= In-Reply-To: <201109051059.16048.hselasky@c2i.net> Received: from ( [85.132.159.231]) by email.seznam.cz (Email.Seznam.cz) with HTTP for Kaminar@seznam.cz; Mon, 5 Sep 2011 17:47:00 +0200 (CEST) Date: Mon, 05 Sep 2011 17:52:12 +0200 (CEST) To: freebsd-usb@freebsd.org From: Kaminar Mime-Version: 1.0 Message-Id: <36918.1358.990-2999-1508145750-1315237932@seznam.cz> Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="iso-8859-2" X-Country: -- X-Abuse: abuse@seznam.cz X-Seznam-User: Kaminar@seznam.cz Subject: Re: Problem with connecting external HDD ADATA CH11 1TB USB 3.0 X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Sep 2011 15:52:15 -0000 > Od: Hans Petter Selasky > P=F8edm=ECt: Re: Problem with connecting external HDD ADATA CH11 1TB = USB 3.0 > Datum: 05.9.2011 11:02:15 > ---------------------------------------- > On Monday 05 September 2011 10:09:08 Kaminar wrote: > > Hi, > > > > I bought external HDD ADATA CH11 1TB USB 3.0 (compatible with USB2.= 0). I > > have problem to connect HDD to FreeBSD box. I post my problem on Fr= eeBSD > > forum (the thread on FreeBSD forum is > > http://forums.freebsd.org/showthread.php?t=3D26082). People on foru= m suggest > > to me to send problem here. I enclosure summary of everything of wh= at I > > observed. > > > > HDD: external HDD ADATA CH11 1TB USB 3.0 (compatible with USB2.0), = 2.5inch > > size without cable power supply. > > > > After HDD connection to USB2.0 on desktop PC with FreeBSD 8.1R I go= t error > > messages: > > > > Code: > > > > kernel: usb_alloc_device: set address 2 failed (USB_ERR_STALLED, ig= nored) > > kernel: usb_alloc_device: getting device descriptor at addr 2 faile= d, > > USB_ERR_STALLED kernel: usbd_req_re_enumerate: addr=3D2, set addres= s failed! > > (USB_ERR_STALLED, ignored) kernel: usbd_req_re_enumerate: getting d= evice > > descriptor at addr 2 failed, USB_ERR_STALLED kernel: > > usbd_req_re_enumerate: addr=3D2, set address failed! (USB_ERR_STALL= ED, > > ignored) kernel: usbd_req_re_enumerate: getting device descriptor a= t addr > > 2 failed, USB_ERR_STALLED kernel: ugen4.2: <(null)> at usbus4 > > (disconnected) > > kernel: uhub_reattach_port: could not allocate new device > > > > > > In this thread http://forums.freebsd.org/showthread.php?t=3D25386 I= found > > somebody solved similar problem by connecting disk within USB hub. = I tried > > three hubs. Every USB hubs have not power supply. > > > > > > With the first USB hub I got: > > ----------------------------- > > > > Code: > > > > kernel: ugen4.2: at usbus4 > > kernel: uhub9: on > > usbus4 kernel: uhub9: 4 ports with 4 removable, self powered > > root: Unknown USB device: vendor 0x125f product 0xa11a bus uhub9 > > kernel: ugen4.3: at usbus4 > > kernel: umass0: on u= sbus4 > > kernel: umass0: SCSI over Bulk-Only; quirks =3D 0x0000 > > kernel: umass0:14:0:-1: Attached to scbus14 > > > > No success. No device appeared. It looks like USB hub seems not to = properly > > powering HDD. The HDD probably was not spinning and there was only = hearing > > quiet ticking from HDD. > > > > After disconnecting disk I got: > > > > Code: > > > > kernel: ugen4.3: at usbus4 (disconnected) > > kernel: umass0: at uhub9, port 4, addr 3 (disconnected) > > kernel: (probe0:umass-sim0:0:0:0): AutoSense failed > > kernel: ugen4.2: at usbus4 (disconnected) > > kernel: uhub9: at uhub4, port 2, addr 2 (disconnected) > > > > > > With the second USB hub I got: > > ------------------------------ > > > > Code: > > > > kernel: ugen8.2: at usbus8 > > kernel: uhub9: > > on usbus8 kernel: uhub9: 4 ports with 4 removable, self powered > > root: Unknown USB device: vendor 0x125f product 0xa11a bus uhub9 > > kernel: ugen8.3: at usbus8 > > kernel: umass0: on u= sbus8 > > kernel: umass0: SCSI over Bulk-Only; quirks =3D 0x0000 > > kernel: umass0:14:0:-1: Attached to scbus14 > > > > kernel: (probe0:umass-sim0:0:0:0): AutoSense failed > > kernel: ugen8.3: at usbus8 (disconnected) > > kernel: umass0: at uhub9, port 3, addr 3 (disconnected) > > kernel: ugen8.2: at usbus8 (disconnected) > > kernel: uhub9: at uhub8, port 2, addr 2 (disconnected) > > > > No success. No device appeared. > > > > > > With the third USB hub I got: > > ----------------------------- > > > > Code: > > > > kernel: ugen8.2: at usbus8 > > kernel: uhub9: > > on usbus8 kernel: uhub9: 4 ports with 4 removable, self powered > > root: Unknown USB device: vendor 0x125f product 0xa11a bus uhub9 > > kernel: ugen8.3: at usbus8 > > kernel: umass0: on u= sbus8 > > kernel: umass0: SCSI over Bulk-Only; quirks =3D 0x0000 > > kernel: umass0:14:0:-1: Attached to scbus14 > > kernel: da0 at umass-sim0 bus 0 scbus14 target 0 lun 0 > > kernel: da0: Fixed Direct Access SCSI-5 device > > kernel: da0: 40.000MB/s transfers > > kernel: da0: 953869MB (1953525168 512 byte sectors: 255H 63S/T 1216= 01C) > > kernel: ugen8.3: at usbus8 (disconnected) > > kernel: umass0: at uhub9, port 3, addr 3 (disconnected) > > kernel: (da0:umass-sim0:0:0:0): lost device > > kernel: (da0:umass-sim0:0:0:0): removing device entry > > kernel: ugen8.2: at usbus8 (disconnected) > > kernel: uhub9: at uhub8, port 2, addr 2 (disconnected) > > > > With the third USB hub it seems HDD is working. The disk was prefor= mated to > > FAT32. I tried to copy one small file and delete it. It works. > > > > But why doesn't it work if HDD is connected directly to PC or withi= n 1st or > > 2nd USB hub? The third USB hub is not mine and I am afraid it is no= t on > > market yet. Due to I need other solution to use my external HDD. > > > > > > Linux box (Ubuntu 10.04): > > ------------------------- > > > > I tried it on Linux box too (on Ubuntu 10.04 which is on different = computer > > than my FreeBSD is installed). HDD directly plugged to computer's U= SB2.0 > > connector was automatically mounted and it seems to work. But in me= ssages > > appeared some error: > > > > Code: > > > > usb 1-7: new high speed USB device using ehci_hcd and address 4 > > usb 1-7: configuration #1 chosen from 1 choice > > Initializing USB Mass Storage driver... > > scsi4 : SCSI emulation for USB Mass Storage devices > > usbcore: registered new interface driver usb-storage > > USB Mass Storage support registered. > > usb-storage: device found at 4 > > usb-storage: waiting for device to settle before scanning > > usb-storage: device scan complete > > scsi 4:0:0:0: Direct-Access ADATA CH11 GL00 PQ: = 0 ANSI: > > 5 sd 4:0:0:0: Attached scsi generic sg3 type 0 > > sd 4:0:0:0: [sdc] 1953525168 512-byte logical blocks: (1.00 TB/931 = GiB) > > sd 4:0:0:0: [sdc] Write Protect is off > > sd 4:0:0:0: [sdc] Mode Sense: 23 00 00 00 > > sd 4:0:0:0: [sdc] Assuming drive cache: write through > > sd 4:0:0:0: [sdc] Assuming drive cache: write through > > sdc: sdc1 > > sd 4:0:0:0: [sdc] Assuming drive cache: write through > > sd 4:0:0:0: [sdc] Attached SCSI disk > > sd 4:0:0:0: [sdc] Sense Key : Recovered Error [current] [descriptor= ] > > Descriptor sense data with sense descriptors (in hex): > > 72 01 04 1d 00 00 00 0e 09 0c 00 00 00 00 00 00 > > 00 4f 00 c2 00 50 > > sd 4:0:0:0: [sdc] ASC=3D0x4 ASCQ=3D0x1d > > > > On the Internet this Linux bug is mentioned, but I didn't find any > > solution. > > > > > > Livecd FreeBSD 9.0-BETA1: > > -------------------------------- > > > > I tried my external HDD under FreeBSD 9.0-BETA1 (same computer wher= e my > > FreeBSD 8.1R is installed). After I connected HDD to USB2.0 port, s= ame > > problem appeared as in my first post in this email. After connectin= g HDD to > > USB3.0 I got this messages with some error: > > > > Code: > > > > ugen4.2: at usbus4 > > umass0: on usbus4 > > umass0: SCSI over Bulk-Only; quirks =3D 0x0000 > > umass0:15:0:-1: Attached to scbus15 > > (probe0:umass-sim0:0:0:0): REPORT LUNS. CDB: a0 0 0 0 0 0 0 0 0 10 = 0 0 > > (probe0:umass-sim0:0:0:0): CAM status: SCSI Status Error > > (probe0:umass-sim0:0:0:0): SCSI status: Check Condition > > (probe0:umass-sim0:0:0:0): SCSI sense: ILLEGAL REQUEST asc:20,0 (In= valid > > command operation code) da0 at umass-sim0 bus 0 scbus15 target 0 lu= n 0 > > da0: Fixed Direct Access SCSI-5 device > > da0: 400.000MB/s transfers > > da0: 953869MB (1953525168 512 byte sectors: 255H 63S/T 121601C) > > > > It seems that HDD would probably work. I tried to mount it and writ= e one > > file. The information about error on the Internet is messy for me. > > > > After unplugging HDD I got: > > > > Code: > > > > ugen4.2: at usbus4 (disconnected) > > umass0: at uhub4, port 1, addr 1 (disconnected) > > (da0:umass-sim0:0:0:0): lost device - 0 outstanding > > (da0:umass-sim0:0:0:0): removing device entry > > > > > > Could you give me some suggestion what is wrong? > > Hi, > > Is it possible you could try a 9-BETA live CD and see if there are an= y > differences? There has been some changes regarding how enumeration wo= rks > between 8.1R and 8.2 stable / 9.X. > > There are many reasons that a USB device won't work. It is not always= possible > to fix. > > Thanks for all the logs. Could you dump the USB speed of your device = in all > the different cases using usbconfig? > > --HPS There is result from 9-BETA1 (amd64) when HDD was plugged to USB3.0: # usbconfig -d 4.2 ugen4.2: at usbus4, cfg=3D0 md=3DHOST spd=3DSUPER (5.0Gbp= s) pwr=3DON Regards, Karel From owner-freebsd-usb@FreeBSD.ORG Mon Sep 5 15:54:31 2011 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1ED2C1065670 for ; Mon, 5 Sep 2011 15:54:30 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe08.c2i.net [212.247.154.226]) by mx1.freebsd.org (Postfix) with ESMTP id 970418FC12 for ; Mon, 5 Sep 2011 15:54:29 +0000 (UTC) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.1 cv=ZrWDMTID0AMW4DNRKF44fvigJaUxxg2ESvddpUoMqyA= c=1 sm=1 a=SvYTsOw2Z4kA:10 a=IUYnjQNxkLsA:10 a=WQU8e4WWZSUA:10 a=-CRmgG0JhlAA:10 a=CL8lFSKtTFcA:10 a=i9M/sDlu2rpZ9XS819oYzg==:17 a=8kQB0OdkAAAA:8 a=VKMe13jy5aRqXijMjrYA:9 a=jiObf9B0YAUA:10 a=9aOQ2cSd83gA:10 a=i9M/sDlu2rpZ9XS819oYzg==:117 Received: from [188.126.198.129] (account mc467741@c2i.net HELO laptop002.hselasky.homeunix.org) by mailfe08.swip.net (CommuniGate Pro SMTP 5.2.19) with ESMTPA id 175678791; Mon, 05 Sep 2011 17:54:26 +0200 From: Hans Petter Selasky To: freebsd-usb@freebsd.org Date: Mon, 5 Sep 2011 17:51:45 +0200 User-Agent: KMail/1.13.5 (FreeBSD/8.2-STABLE; KDE/4.4.5; amd64; ; ) References: <36918.1358.990-2999-1508145750-1315237932@seznam.cz> In-Reply-To: <36918.1358.990-2999-1508145750-1315237932@seznam.cz> X-Face: *nPdTl_}RuAI6^PVpA02T?$%Xa^>@hE0uyUIoiha$pC:9TVgl.Oq,NwSZ4V" =?utf-8?q?=7CLR=2E+tj=7Dg5=0A=09=25V?=,x^qOs~mnU3]Gn; cQLv&.N>TrxmSFf+p6(30a/{)KUU!s}w\IhQBj}[g}bj0I3^glmC( =?utf-8?q?=0A=09=3AAuzV9=3A=2EhESm-x4h240C=609=3Dw?= MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable Message-Id: <201109051751.45352.hselasky@c2i.net> Cc: Kaminar Subject: Re: Problem with connecting external HDD ADATA CH11 1TB USB 3.0 X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Sep 2011 15:54:31 -0000 On Monday 05 September 2011 17:52:12 Kaminar wrote: > > Od: Hans Petter Selasky > > P=F8edm=ECt: Re: Problem with connecting external HDD ADATA CH11 1TB US= B 3.0 > > Datum: 05.9.2011 11:02:15 > > ---------------------------------------- > > --HPS >=20 > There is result from 9-BETA1 (amd64) when HDD was plugged to USB3.0: >=20 > # usbconfig -d 4.2 > ugen4.2: at usbus4, cfg=3D0 md=3DHOST spd=3DSUPER (5.0Gbps)= pwr=3DON >=20 Does 9-BETA1 works better than 8.1R ? =2D-HPS From owner-freebsd-usb@FreeBSD.ORG Thu Sep 8 21:07:35 2011 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8AB441065670; Thu, 8 Sep 2011 21:07:35 +0000 (UTC) (envelope-from Gabor@Zahemszky.HU) Received: from relay03.digicable.hu (relay03.digicable.hu [92.249.128.185]) by mx1.freebsd.org (Postfix) with ESMTP id 504F08FC17; Thu, 8 Sep 2011 21:07:30 +0000 (UTC) Received: from [94.21.8.117] (helo=Picasso.Zahemszky.HU) by relay03.digicable.hu with esmtpa id 1R1lSD-0004Ot-54 ; Thu, 08 Sep 2011 22:44:09 +0200 Date: Thu, 8 Sep 2011 22:44:05 +0200 From: Zahemszky =?ISO-8859-2?Q?G=E1bor?= To: freebsd-usb@freebsd.org, hselasky@FreeBSD.org Message-ID: <20110908224405.4fcaf8ab@Picasso.Zahemszky.HU> Organization: Zahemszky Bt. X-Mailer: Claws Mail 3.7.8 (GTK+ 2.22.1; amd64-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-2 Content-Transfer-Encoding: quoted-printable X-Original: 94.21.8.117 Cc: Subject: FreeBSD and unidentified iPod Touch X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Sep 2011 21:07:35 -0000 Hi! My son has got an iPod Touch (3rd generation, 8GB). We van use iTunes on Windows, bu we cannot reach it on FreeBSD 8.2R, amd64. When we connect i= t, we got the following output: Sep 8 22:22:29 Picasso root: Unknown USB device: vendor 0x05ac product 0x1= 293 bus uhub2 Sep 8 22:22:29 Picasso kernel: ugen2.2: at usbus2 # usbconfig ... ugen2.2: at usbus2, cfg=3D0 md=3DHOST spd=3DHIGH (480Mbps= ) pwr=3DON # usbconfig -d ugen2.2 dump_device_desc ugen2.2: at usbus2, cfg=3D0 md=3DHOST spd=3DHIGH (480Mbps= ) pwr=3DON bLength =3D 0x0012=20 bDescriptorType =3D 0x0001=20 bcdUSB =3D 0x0200=20 bDeviceClass =3D 0x0000=20 bDeviceSubClass =3D 0x0000=20 bDeviceProtocol =3D 0x0000=20 bMaxPacketSize0 =3D 0x0040=20 idVendor =3D 0x05ac=20 idProduct =3D 0x1293=20 bcdDevice =3D 0x0001=20 iManufacturer =3D 0x0001 iProduct =3D 0x0002 iSerialNumber =3D 0x0003 <63160800ecbe33eb705dd1291c8a0f78547ea5b3> bNumConfigurations =3D 0x0003=20 Is it possible to use some of the usb_quirks, or something other to see tha= t machine az an umass device? By the way, I didn't find the identification information of that machine, i= n /usr/src/sys/dev/usb/usbdevs on my 8.2 machine. Vendor ID: 0x05ac Product ID: 0x1293 It's model: MC086BT OS Version: 4.2.1(8C148) Thanks, G=E1bor Zahemszky < Gabor at Zahemszky dot HU > --=20 #!/bin/ksh # # See my GPG key at http://www.Zahemszky.HU # Z=3D'21N16I25C25E30, 40M30E33E25T15U!'; IFS=3D' ABCDEFGHIJKLMNOPQRSTUVWXYZ '; set -- $Z;for i;{ [[ $i =3D ? ]]&&print $i&&break; [[ $i =3D ??? ]]&&j=3D$i&&i=3D${i%?}; typeset -i40 i=3D8#$i;print -n ${i#???}; [[ "$j" =3D ??? ]]&&print -n "${j#??} "&&j=3D;typeset +i i;}; IFS=3D' 0123456789 ';set -- $Z;for i;{ [[ $i =3D , ]]&&i=3D2; [[ $i =3D ?? ]]||typeset -l i;j=3D"$j $i";typeset +l i;};print "$j" From owner-freebsd-usb@FreeBSD.ORG Thu Sep 8 21:29:43 2011 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4C46C1065670 for ; Thu, 8 Sep 2011 21:29:43 +0000 (UTC) (envelope-from hselasky@freebsd.org) Received: from swip.net (mailfe07.c2i.net [212.247.154.194]) by mx1.freebsd.org (Postfix) with ESMTP id C84F58FC13 for ; Thu, 8 Sep 2011 21:29:42 +0000 (UTC) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.1 cv=G3me67YS4qRPZcaDO6kWttTShkFAyiMG89AbsUJ8MxU= c=1 sm=1 a=SvYTsOw2Z4kA:10 a=TOkcEKrQ1KoA:10 a=dBRESv0yCI8A:10 a=-CRmgG0JhlAA:10 a=CL8lFSKtTFcA:10 a=i9M/sDlu2rpZ9XS819oYzg==:17 a=6I5d2MoRAAAA:8 a=F5b2803eTLN3NgnPhYwA:9 a=VV28H-TGMV6Eti3tYcoA:7 a=jiObf9B0YAUA:10 a=i9M/sDlu2rpZ9XS819oYzg==:117 Received: from [188.126.198.129] (account mc467741@c2i.net HELO laptop002.hselasky.homeunix.org) by mailfe07.swip.net (CommuniGate Pro SMTP 5.2.19) with ESMTPA id 177024445; Thu, 08 Sep 2011 23:29:39 +0200 Received-SPF: softfail receiver=mailfe07.swip.net; client-ip=188.126.198.129; envelope-from=hselasky@freebsd.org From: Hans Petter Selasky To: freebsd-usb@freebsd.org Date: Thu, 8 Sep 2011 23:26:56 +0200 User-Agent: KMail/1.13.5 (FreeBSD/8.2-STABLE; KDE/4.4.5; amd64; ; ) References: <20110908224405.4fcaf8ab@Picasso.Zahemszky.HU> In-Reply-To: <20110908224405.4fcaf8ab@Picasso.Zahemszky.HU> X-Face: *nPdTl_}RuAI6^PVpA02T?$%Xa^>@hE0uyUIoiha$pC:9TVgl.Oq,NwSZ4V" =?iso-8859-1?q?=7CLR=2E+tj=7Dg5=0A=09=25V?=,x^qOs~mnU3]Gn; cQLv&.N>TrxmSFf+p6(30a/{)KUU!s}w\IhQBj}[g}bj0I3^glmC( =?iso-8859-1?q?=0A=09=3AAuzV9=3A=2EhESm-x4h240C=609=3Dw?= MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable Message-Id: <201109082326.56937.hselasky@freebsd.org> Cc: Zahemszky =?iso-8859-2?q?G=E1bor?= Subject: Re: FreeBSD and unidentified iPod Touch X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Sep 2011 21:29:43 -0000 On Thursday 08 September 2011 22:44:05 Zahemszky G=E1bor wrote: > Hi! >=20 > My son has got an iPod Touch (3rd generation, 8GB). We van use iTunes > on Windows, bu we cannot reach it on FreeBSD 8.2R, amd64. When we connect > it, we got the following output: >=20 > Sep 8 22:22:29 Picasso root: Unknown USB device: vendor 0x05ac product > 0x1293 bus uhub2 Sep 8 22:22:29 Picasso kernel: ugen2.2: at > usbus2 >=20 > # usbconfig > ... > ugen2.2: at usbus2, cfg=3D0 md=3DHOST spd=3DHIGH (480Mb= ps) > pwr=3DON >=20 > # usbconfig -d ugen2.2 dump_device_desc > ugen2.2: at usbus2, cfg=3D0 md=3DHOST spd=3DHIGH (480Mb= ps) > pwr=3DON >=20 > bLength =3D 0x0012 > bDescriptorType =3D 0x0001 > bcdUSB =3D 0x0200 > bDeviceClass =3D 0x0000 > bDeviceSubClass =3D 0x0000 > bDeviceProtocol =3D 0x0000 > bMaxPacketSize0 =3D 0x0040 > idVendor =3D 0x05ac > idProduct =3D 0x1293 > bcdDevice =3D 0x0001 > iManufacturer =3D 0x0001 > iProduct =3D 0x0002 > iSerialNumber =3D 0x0003 <63160800ecbe33eb705dd1291c8a0f78547ea5b3> Hi, > bNumConfigurations =3D 0x0003 ^^^ your device has multiple configurations. Try: usbconfig -d 2.2 set_config 1 or usbconfig -d 2.2 set_config 2 A umass device should appear if the device has support for that. Else it is= =20 also likely that the PTP protocol is used. There are several tools in ports= =20 that can access this USB protocol. http://www.freebsd.org/cgi/ports.cgi?query=3Dipod&stype=3Dall&sektion=3Dall Especially the usbmuxd. =2D-HPS From owner-freebsd-usb@FreeBSD.ORG Thu Sep 8 21:29:53 2011 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 942F5106564A for ; Thu, 8 Sep 2011 21:29:53 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe01.c2i.net [212.247.154.2]) by mx1.freebsd.org (Postfix) with ESMTP id D68CC8FC08 for ; Thu, 8 Sep 2011 21:29:52 +0000 (UTC) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.1 cv=wJvnH89EauZH5CtPccDXCoR3S15XcsUHhRLViNeYhtc= c=1 sm=1 a=TOkcEKrQ1KoA:10 a=WQU8e4WWZSUA:10 a=-CRmgG0JhlAA:10 a=CL8lFSKtTFcA:10 a=i9M/sDlu2rpZ9XS819oYzg==:17 a=6I5d2MoRAAAA:8 a=F5b2803eTLN3NgnPhYwA:9 a=VV28H-TGMV6Eti3tYcoA:7 a=jiObf9B0YAUA:10 a=i9M/sDlu2rpZ9XS819oYzg==:117 Received: from [188.126.198.129] (account mc467741@c2i.net HELO laptop002.hselasky.homeunix.org) by mailfe01.swip.net (CommuniGate Pro SMTP 5.2.19) with ESMTPA id 177909880; Thu, 08 Sep 2011 23:29:50 +0200 To: freebsd-usb@freebsd.org From: Hans Petter Selasky X-Face: *nPdTl_}RuAI6^PVpA02T?$%Xa^>@hE0uyUIoiha$pC:9TVgl.Oq,NwSZ4V" =?iso-8859-2?q?=7CLR=2E+tj=7Dg5=0A=09=25V?=,x^qOs~mnU3]Gn; cQLv&.N>TrxmSFf+p6(30a/{)KUU!s}w\IhQBj}[g}bj0I3^glmC( =?iso-8859-2?q?=0A=09=3AAuzV9=3A=2EhESm-x4h240C=609=3Dw?= Date: Thu, 8 Sep 2011 23:27:08 +0200 MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable Message-Id: <201109082327.08501.hselasky@c2i.net> Cc: Zahemszky =?iso-8859-2?q?G=E1bor?= Subject: Re: FreeBSD and unidentified iPod Touch X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Sep 2011 21:29:53 -0000 On Thursday 08 September 2011 22:44:05 Zahemszky G=E1bor wrote: > Hi! >=20 > My son has got an iPod Touch (3rd generation, 8GB). We van use iTunes > on Windows, bu we cannot reach it on FreeBSD 8.2R, amd64. When we connect > it, we got the following output: >=20 > Sep 8 22:22:29 Picasso root: Unknown USB device: vendor 0x05ac product > 0x1293 bus uhub2 Sep 8 22:22:29 Picasso kernel: ugen2.2: at > usbus2 >=20 > # usbconfig > ... > ugen2.2: at usbus2, cfg=3D0 md=3DHOST spd=3DHIGH (480Mb= ps) > pwr=3DON >=20 > # usbconfig -d ugen2.2 dump_device_desc > ugen2.2: at usbus2, cfg=3D0 md=3DHOST spd=3DHIGH (480Mb= ps) > pwr=3DON >=20 > bLength =3D 0x0012 > bDescriptorType =3D 0x0001 > bcdUSB =3D 0x0200 > bDeviceClass =3D 0x0000 > bDeviceSubClass =3D 0x0000 > bDeviceProtocol =3D 0x0000 > bMaxPacketSize0 =3D 0x0040 > idVendor =3D 0x05ac > idProduct =3D 0x1293 > bcdDevice =3D 0x0001 > iManufacturer =3D 0x0001 > iProduct =3D 0x0002 > iSerialNumber =3D 0x0003 <63160800ecbe33eb705dd1291c8a0f78547ea5b3> Hi, > bNumConfigurations =3D 0x0003 ^^^ your device has multiple configurations. Try: usbconfig -d 2.2 set_config 1 or usbconfig -d 2.2 set_config 2 A umass device should appear if the device has support for that. Else it is= =20 also likely that the PTP protocol is used. There are several tools in ports= =20 that can access this USB protocol. http://www.freebsd.org/cgi/ports.cgi?query=3Dipod&stype=3Dall&sektion=3Dall Especially the usbmuxd. =2D-HPS From owner-freebsd-usb@FreeBSD.ORG Thu Sep 8 21:31:06 2011 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 384E4106566C; Thu, 8 Sep 2011 21:31:06 +0000 (UTC) (envelope-from gpalmer@freebsd.org) Received: from noop.in-addr.com (noop.in-addr.com [208.58.23.51]) by mx1.freebsd.org (Postfix) with ESMTP id C975D8FC08; Thu, 8 Sep 2011 21:31:05 +0000 (UTC) Received: from gjp by noop.in-addr.com with local (Exim 4.76 (FreeBSD)) (envelope-from ) id 1R1lzc-0008P7-UL; Thu, 08 Sep 2011 17:18:40 -0400 Date: Thu, 8 Sep 2011 17:18:40 -0400 From: Gary Palmer To: Zahemszky G?bor Message-ID: <20110908211840.GC42938@in-addr.com> References: <20110908224405.4fcaf8ab@Picasso.Zahemszky.HU> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110908224405.4fcaf8ab@Picasso.Zahemszky.HU> X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: gpalmer@freebsd.org X-SA-Exim-Scanned: No (on noop.in-addr.com); SAEximRunCond expanded to false Cc: hselasky@FreeBSD.org, freebsd-usb@freebsd.org Subject: Re: FreeBSD and unidentified iPod Touch X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Sep 2011 21:31:06 -0000 On Thu, Sep 08, 2011 at 10:44:05PM +0200, Zahemszky G?bor wrote: > Hi! > > My son has got an iPod Touch (3rd generation, 8GB). We van use iTunes > on Windows, bu we cannot reach it on FreeBSD 8.2R, amd64. When we connect it, we > got the following output: > > Sep 8 22:22:29 Picasso root: Unknown USB device: vendor 0x05ac product 0x1293 bus uhub2 > Sep 8 22:22:29 Picasso kernel: ugen2.2: at usbus2 > > # usbconfig > ... > ugen2.2: at usbus2, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON > > # usbconfig -d ugen2.2 dump_device_desc > ugen2.2: at usbus2, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON > > bLength = 0x0012 > bDescriptorType = 0x0001 > bcdUSB = 0x0200 > bDeviceClass = 0x0000 > bDeviceSubClass = 0x0000 > bDeviceProtocol = 0x0000 > bMaxPacketSize0 = 0x0040 > idVendor = 0x05ac > idProduct = 0x1293 > bcdDevice = 0x0001 > iManufacturer = 0x0001 > iProduct = 0x0002 > iSerialNumber = 0x0003 <63160800ecbe33eb705dd1291c8a0f78547ea5b3> > bNumConfigurations = 0x0003 > > Is it possible to use some of the usb_quirks, or something other to see that machine az an umass device? iPod Touch is no longer a mass storage device, unlike earlier iPod models with the hard drives inside. It uses a proprietary communications system for updates from iTunes. There might be something in ports which allows communication Regards, Gary From owner-freebsd-usb@FreeBSD.ORG Fri Sep 9 07:50:07 2011 Return-Path: Delivered-To: freebsd-usb@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 12874106564A for ; Fri, 9 Sep 2011 07:50:07 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 012B28FC0A for ; Fri, 9 Sep 2011 07:50:07 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p897o63n053046 for ; Fri, 9 Sep 2011 07:50:06 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p897o6jb053044; Fri, 9 Sep 2011 07:50:06 GMT (envelope-from gnats) Date: Fri, 9 Sep 2011 07:50:06 GMT Message-Id: <201109090750.p897o6jb053044@freefall.freebsd.org> To: freebsd-usb@FreeBSD.org From: dfilter@FreeBSD.ORG (dfilter service) Cc: Subject: Re: usb/160299: commit references a PR X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: dfilter service List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 09 Sep 2011 07:50:07 -0000 The following reply was made to PR usb/160299; it has been noted by GNATS. From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: usb/160299: commit references a PR Date: Fri, 9 Sep 2011 07:44:24 +0000 (UTC) Author: hselasky Date: Fri Sep 9 07:44:14 2011 New Revision: 225458 URL: http://svn.freebsd.org/changeset/base/225458 Log: MFC r225350 and r225400: This patch adds automatic detection of USB mass storage devices which does not support the no synchronize cache SCSI command. The __FreeBSD_version version macro has been bumped and external kernel modules needs to be recompiled after this patch. PR: usb/160299 Modified: stable/8/sys/dev/usb/quirk/usb_quirk.c stable/8/sys/dev/usb/storage/umass.c stable/8/sys/dev/usb/usb_device.c stable/8/sys/dev/usb/usb_device.h stable/8/sys/dev/usb/usb_dynamic.c stable/8/sys/dev/usb/usb_dynamic.h stable/8/sys/dev/usb/usb_freebsd.h stable/8/sys/dev/usb/usb_msctest.c stable/8/sys/dev/usb/usb_msctest.h stable/8/sys/dev/usb/usbdi.h stable/8/sys/sys/param.h Directory Properties: 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/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- stable/8/sys/dev/usb/quirk/usb_quirk.c Fri Sep 9 04:42:11 2011 (r225457) +++ stable/8/sys/dev/usb/quirk/usb_quirk.c Fri Sep 9 07:44:14 2011 (r225458) @@ -148,12 +148,10 @@ static struct usb_quirk_entry usb_quirks UQ_MSC_FORCE_PROTO_SCSI), USB_QUIRK(AIPTEK, POCKETCAM3M, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI), - USB_QUIRK(AIPTEK2, SUNPLUS_TECH, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(ALCOR, SDCR_6335, 0x0000, 0xffff, UQ_MSC_NO_TEST_UNIT_READY, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(ALCOR, SDCR_6362, 0x0000, 0xffff, UQ_MSC_NO_TEST_UNIT_READY, UQ_MSC_NO_SYNC_CACHE), - USB_QUIRK(ALCOR, AU6390, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(ALCOR, UMCR_9361, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_GETMAXLUN), USB_QUIRK(ALCOR, TRANSCEND, 0x0000, 0xffff, UQ_MSC_NO_GETMAXLUN, @@ -173,14 +171,12 @@ static struct usb_quirk_entry usb_quirks USB_QUIRK(CENTURY, EX35QUAT, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_FORCE_SHORT_INQ, UQ_MSC_NO_START_STOP, UQ_MSC_IGNORE_RESIDUE), - USB_QUIRK(CENTURY, EX35SW4_SB4, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(CYPRESS, XX6830XX, 0x0000, 0xffff, UQ_MSC_NO_GETMAXLUN, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(DESKNOTE, UCR_61S2B, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI), USB_QUIRK(DMI, CFSM_RW, 0x0000, 0xffff, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_GETMAXLUN), - USB_QUIRK(DMI, DISK, 0x000, 0xffff, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(EPSON, STYLUS_875DC, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_CBI, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_INQUIRY), USB_QUIRK(EPSON, STYLUS_895, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, @@ -188,7 +184,6 @@ static struct usb_quirk_entry usb_quirks USB_QUIRK(FEIYA, 5IN1, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI), USB_QUIRK(FREECOM, DVD, 0x0000, 0xffff, UQ_MSC_FORCE_PROTO_SCSI), - USB_QUIRK(FREECOM, HDD, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(FUJIPHOTO, MASS0100, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_CBI_I, UQ_MSC_FORCE_PROTO_ATAPI, UQ_MSC_NO_RS_CLEAR_UA, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(GENESYS, GL641USB2IDE, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, @@ -232,7 +227,6 @@ static struct usb_quirk_entry usb_quirks USB_QUIRK(IOMEGA, ZIP100, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_TEST_UNIT_READY), /* XXX ZIP drives can also use ATAPI */ - USB_QUIRK(JMICRON, JM20336, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(JMICRON, JM20337, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_SYNC_CACHE), @@ -279,8 +273,6 @@ static struct usb_quirk_entry usb_quirks UQ_MSC_FORCE_PROTO_ATAPI), USB_QUIRK(MYSON, HEDEN, 0x0000, 0xffff, UQ_MSC_IGNORE_RESIDUE, UQ_MSC_NO_SYNC_CACHE), - USB_QUIRK(MYSON, HEDEN_8813, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), - USB_QUIRK(MYSON, STARREADER, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(NEODIO, ND3260, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_FORCE_SHORT_INQ), USB_QUIRK(NETAC, CF_CARD, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, @@ -317,7 +309,6 @@ static struct usb_quirk_entry usb_quirks USB_QUIRK(PANASONIC, KXLCB35AN, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI), USB_QUIRK(PANASONIC, LS120CAM, 0x0000, 0xffff, UQ_MSC_FORCE_PROTO_UFI), - USB_QUIRK(PHILIPS, SPE3030CC, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(PLEXTOR, 40_12_40U, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_TEST_UNIT_READY), USB_QUIRK(PNY, ATTACHE2, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, @@ -328,7 +319,6 @@ static struct usb_quirk_entry usb_quirks USB_QUIRK_VP(USB_VENDOR_SAMSUNG_TECHWIN, USB_PRODUCT_SAMSUNG_TECHWIN_DIGIMAX_410, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_INQUIRY), - USB_QUIRK(SAMSUNG, YP_U4, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), USB_QUIRK(SANDISK, SDDR05A, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_CBI, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_READ_CAP_OFFBY1, UQ_MSC_NO_GETMAXLUN), @@ -448,12 +438,6 @@ static struct usb_quirk_entry usb_quirks UQ_MSC_FORCE_PROTO_ATAPI), USB_QUIRK(MEIZU, M6_SL, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_INQUIRY, UQ_MSC_NO_SYNC_CACHE), - USB_QUIRK(ACTIONS, MP4, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, - UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_SYNC_CACHE), - USB_QUIRK(ASUS, GMSC, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), - USB_QUIRK(CHIPSBANK, USBMEMSTICK, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), - USB_QUIRK(CHIPSBANK, USBMEMSTICK1, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), - USB_QUIRK(NEWLINK, USB2IDEBRIDGE, 0x0000, 0xffff, UQ_MSC_NO_SYNC_CACHE), /* Non-standard USB MIDI devices */ USB_QUIRK(ROLAND, UM1, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), @@ -567,9 +551,9 @@ usb_test_quirk_by_info(const struct usbd uint16_t x; uint16_t y; - if (quirk == UQ_NONE) { - return (0); - } + if (quirk == UQ_NONE) + goto done; + mtx_lock(&usb_quirk_mtx); for (x = 0; x != USB_DEV_QUIRKS_MAX; x++) { @@ -603,7 +587,8 @@ usb_test_quirk_by_info(const struct usbd break; } mtx_unlock(&usb_quirk_mtx); - return (0); +done: + return (usb_test_quirk_w(info, quirk)); } static struct usb_quirk_entry * Modified: stable/8/sys/dev/usb/storage/umass.c ============================================================================== --- stable/8/sys/dev/usb/storage/umass.c Fri Sep 9 04:42:11 2011 (r225457) +++ stable/8/sys/dev/usb/storage/umass.c Fri Sep 9 07:44:14 2011 (r225458) @@ -1025,12 +1025,6 @@ umass_attach(device_t dev) sc->cam_scsi_sense.opcode = REQUEST_SENSE; sc->cam_scsi_test_unit_ready.opcode = TEST_UNIT_READY; - /* - * some devices need a delay after that the configuration value is - * set to function properly: - */ - usb_pause_mtx(NULL, hz); - /* register the SIM */ err = umass_cam_attach_sim(sc); if (err) { Modified: stable/8/sys/dev/usb/usb_device.c ============================================================================== --- stable/8/sys/dev/usb/usb_device.c Fri Sep 9 04:42:11 2011 (r225457) +++ stable/8/sys/dev/usb/usb_device.c Fri Sep 9 07:44:14 2011 (r225458) @@ -1239,7 +1239,9 @@ static void usb_init_attach_arg(struct usb_device *udev, struct usb_attach_arg *uaa) { - bzero(uaa, sizeof(*uaa)); + uint8_t x; + + memset(uaa, 0, sizeof(*uaa)); uaa->device = udev; uaa->usb_mode = udev->flags.usb_mode; @@ -1254,6 +1256,9 @@ usb_init_attach_arg(struct usb_device *u uaa->info.bDeviceProtocol = udev->ddesc.bDeviceProtocol; uaa->info.bConfigIndex = udev->curr_config_index; uaa->info.bConfigNum = udev->curr_config_no; + + for (x = 0; x != USB_MAX_AUTO_QUIRK; x++) + uaa->info.autoQuirk[x] = udev->autoQuirk[x]; } /*------------------------------------------------------------------------* @@ -1850,6 +1855,20 @@ repeat_set_config: } } } + if (set_config_failed == 0 && config_index == 0 && + usb_test_quirk(&uaa, UQ_MSC_NO_SYNC_CACHE) == 0) { + + /* + * Try to figure out if there are any MSC quirks we + * should apply automatically: + */ + err = usb_msc_auto_quirk(udev, 0); + + if (err != 0) { + set_config_failed = 1; + goto repeat_set_config; + } + } config_done: DPRINTF("new dev (addr %d), udev=%p, parent_hub=%p\n", @@ -2773,3 +2792,16 @@ usbd_set_pnpinfo(struct usb_device *udev return (0); /* success */ } +usb_error_t +usbd_add_dynamic_quirk(struct usb_device *udev, uint16_t quirk) +{ + uint8_t x; + + for (x = 0; x != USB_MAX_AUTO_QUIRK; x++) { + if (udev->autoQuirk[x] == 0) { + udev->autoQuirk[x] = quirk; + return (0); /* success */ + } + } + return (USB_ERR_NOMEM); +} Modified: stable/8/sys/dev/usb/usb_device.h ============================================================================== --- stable/8/sys/dev/usb/usb_device.h Fri Sep 9 04:42:11 2011 (r225457) +++ stable/8/sys/dev/usb/usb_device.h Fri Sep 9 07:44:14 2011 (r225458) @@ -149,6 +149,7 @@ struct usb_device { uint16_t power; /* mA the device uses */ uint16_t langid; /* language for strings */ + uint16_t autoQuirk[USB_MAX_AUTO_QUIRK]; /* dynamic quirks */ uint8_t address; /* device addess */ uint8_t device_index; /* device index in "bus->devices" */ Modified: stable/8/sys/dev/usb/usb_dynamic.c ============================================================================== --- stable/8/sys/dev/usb/usb_dynamic.c Fri Sep 9 04:42:11 2011 (r225457) +++ stable/8/sys/dev/usb/usb_dynamic.c Fri Sep 9 07:44:14 2011 (r225458) @@ -50,12 +50,12 @@ #include #include #include +#include /* function prototypes */ static usb_handle_req_t usb_temp_get_desc_w; static usb_temp_setup_by_index_t usb_temp_setup_by_index_w; static usb_temp_unsetup_t usb_temp_unsetup_w; -static usb_test_quirk_t usb_test_quirk_w; static usb_quirk_ioctl_t usb_quirk_ioctl_w; /* global variables */ @@ -72,9 +72,19 @@ usb_temp_setup_by_index_w(struct usb_dev return (USB_ERR_INVAL); } -static uint8_t +uint8_t usb_test_quirk_w(const struct usbd_lookup_info *info, uint16_t quirk) { + uint8_t x; + + if (quirk == UQ_NONE) + return (0); /* no match */ + + for (x = 0; x != USB_MAX_AUTO_QUIRK; x++) { + if (info->autoQuirk[x] == quirk) + return (1); /* match */ + } + return (0); /* no match */ } Modified: stable/8/sys/dev/usb/usb_dynamic.h ============================================================================== --- stable/8/sys/dev/usb/usb_dynamic.h Fri Sep 9 04:42:11 2011 (r225457) +++ stable/8/sys/dev/usb/usb_dynamic.h Fri Sep 9 07:44:14 2011 (r225458) @@ -57,5 +57,6 @@ extern devclass_t usb_devclass_ptr; void usb_temp_unload(void *); void usb_quirk_unload(void *); void usb_bus_unload(void *); +usb_test_quirk_t usb_test_quirk_w; #endif /* _USB_DYNAMIC_H_ */ Modified: stable/8/sys/dev/usb/usb_freebsd.h ============================================================================== --- stable/8/sys/dev/usb/usb_freebsd.h Fri Sep 9 04:42:11 2011 (r225457) +++ stable/8/sys/dev/usb/usb_freebsd.h Fri Sep 9 07:44:14 2011 (r225458) @@ -60,6 +60,8 @@ #define USB_EP0_BUFSIZE 1024 /* bytes */ #define USB_CS_RESET_LIMIT 20 /* failures = 20 * 50 ms = 1sec */ +#define USB_MAX_AUTO_QUIRK 4 /* maximum number of dynamic quirks */ + typedef uint32_t usb_timeout_t; /* milliseconds */ typedef uint32_t usb_frlength_t; /* bytes */ typedef uint32_t usb_frcount_t; /* units */ Modified: stable/8/sys/dev/usb/usb_msctest.c ============================================================================== --- stable/8/sys/dev/usb/usb_msctest.c Fri Sep 9 04:42:11 2011 (r225457) +++ stable/8/sys/dev/usb/usb_msctest.c Fri Sep 9 07:44:14 2011 (r225458) @@ -1,6 +1,6 @@ /* $FreeBSD$ */ /*- - * Copyright (c) 2008 Hans Petter Selasky. All rights reserved. + * Copyright (c) 2008,2011 Hans Petter Selasky. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -84,7 +84,10 @@ enum { DIR_NONE, }; +#define SCSI_MAX_LEN 0x100 #define SCSI_INQ_LEN 0x24 +#define SCSI_SENSE_LEN 0xFF + static uint8_t scsi_test_unit_ready[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; static uint8_t scsi_inquiry[] = { 0x12, 0x00, 0x00, 0x00, SCSI_INQ_LEN, 0x00 }; static uint8_t scsi_rezero_init[] = { 0x01, 0x00, 0x00, 0x00, 0x00, 0x00 }; @@ -97,6 +100,10 @@ static uint8_t scsi_huawei_eject[] = { 0 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; static uint8_t scsi_tct_eject[] = { 0x06, 0xf5, 0x04, 0x02, 0x52, 0x70 }; +static uint8_t scsi_sync_cache[] = { 0x35, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 }; +static uint8_t scsi_request_sense[] = { 0x03, 0x00, 0x00, 0x00, 0x12, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; #define BULK_SIZE 64 /* dummy */ #define ERR_CSW_FAILED -1 @@ -150,7 +157,7 @@ struct bbb_transfer { uint8_t status_try; int error; - uint8_t buffer[256]; + uint8_t buffer[SCSI_MAX_LEN] __aligned(4); }; static usb_callback_t bbb_command_callback; @@ -164,7 +171,7 @@ static void bbb_done(struct bbb_transfer static void bbb_transfer_start(struct bbb_transfer *, uint8_t); static void bbb_data_clear_stall_callback(struct usb_xfer *, uint8_t, uint8_t); -static uint8_t bbb_command_start(struct bbb_transfer *, uint8_t, uint8_t, +static int bbb_command_start(struct bbb_transfer *, uint8_t, uint8_t, void *, size_t, void *, size_t, usb_timeout_t); static struct bbb_transfer *bbb_attach(struct usb_device *, uint8_t); static void bbb_detach(struct bbb_transfer *); @@ -455,7 +462,7 @@ bbb_status_callback(struct usb_xfer *xfe * 0: Success * Else: Failure *------------------------------------------------------------------------*/ -static uint8_t +static int bbb_command_start(struct bbb_transfer *sc, uint8_t dir, uint8_t lun, void *data_ptr, size_t data_len, void *cmd_ptr, size_t cmd_len, usb_timeout_t data_timeout) @@ -567,9 +574,10 @@ int usb_iface_is_cdrom(struct usb_device *udev, uint8_t iface_index) { struct bbb_transfer *sc; - usb_error_t err; - uint8_t timeout, is_cdrom; + uint8_t timeout; + uint8_t is_cdrom; uint8_t sid_type; + int err; sc = bbb_attach(udev, iface_index); if (sc == NULL) @@ -596,6 +604,114 @@ usb_iface_is_cdrom(struct usb_device *ud } usb_error_t +usb_msc_auto_quirk(struct usb_device *udev, uint8_t iface_index) +{ + struct bbb_transfer *sc; + uint8_t timeout; + uint8_t is_no_direct; + uint8_t sid_type; + int err; + + sc = bbb_attach(udev, iface_index); + if (sc == NULL) + return (0); + + /* + * Some devices need a delay after that the configuration + * value is set to function properly: + */ + usb_pause_mtx(NULL, hz); + + is_no_direct = 1; + for (timeout = 4; timeout; timeout--) { + err = bbb_command_start(sc, DIR_IN, 0, sc->buffer, + SCSI_INQ_LEN, &scsi_inquiry, sizeof(scsi_inquiry), + USB_MS_HZ); + + if (err == 0 && sc->actlen > 0) { + sid_type = sc->buffer[0] & 0x1F; + if (sid_type == 0x00) + is_no_direct = 0; + break; + } else if (err != ERR_CSW_FAILED) + break; /* non retryable error */ + usb_pause_mtx(NULL, hz); + } + + if (is_no_direct) { + DPRINTF("Device is not direct access.\n"); + goto done; + } + + err = bbb_command_start(sc, DIR_IN, 0, NULL, 0, + &scsi_test_unit_ready, sizeof(scsi_test_unit_ready), + USB_MS_HZ); + + if (err != 0) { + + if (err != ERR_CSW_FAILED) + goto error; + } + + err = bbb_command_start(sc, DIR_IN, 0, NULL, 0, + &scsi_sync_cache, sizeof(scsi_sync_cache), + USB_MS_HZ); + + if (err != 0) { + + if (err != ERR_CSW_FAILED) + goto error; + + DPRINTF("Device doesn't handle synchronize cache\n"); + + usbd_add_dynamic_quirk(udev, UQ_MSC_NO_SYNC_CACHE); + } + + /* clear sense status of any failed commands on the device */ + + err = bbb_command_start(sc, DIR_IN, 0, sc->buffer, + SCSI_INQ_LEN, &scsi_inquiry, sizeof(scsi_inquiry), + USB_MS_HZ); + + DPRINTF("Inquiry = %d\n", err); + + if (err != 0) { + + if (err != ERR_CSW_FAILED) + goto error; + } + + err = bbb_command_start(sc, DIR_IN, 0, sc->buffer, + SCSI_SENSE_LEN, &scsi_request_sense, + sizeof(scsi_request_sense), USB_MS_HZ); + + DPRINTF("Request sense = %d\n", err); + + if (err != 0) { + + if (err != ERR_CSW_FAILED) + goto error; + } + +done: + bbb_detach(sc); + return (0); + +error: + bbb_detach(sc); + + DPRINTF("Device did not respond, enabling all quirks\n"); + + usbd_add_dynamic_quirk(udev, UQ_MSC_NO_SYNC_CACHE); + usbd_add_dynamic_quirk(udev, UQ_MSC_NO_TEST_UNIT_READY); + + /* Need to re-enumerate the device */ + usbd_req_re_enumerate(udev, NULL); + + return (USB_ERR_STALLED); +} + +usb_error_t usb_msc_eject(struct usb_device *udev, uint8_t iface_index, int method) { struct bbb_transfer *sc; Modified: stable/8/sys/dev/usb/usb_msctest.h ============================================================================== --- stable/8/sys/dev/usb/usb_msctest.h Fri Sep 9 04:42:11 2011 (r225457) +++ stable/8/sys/dev/usb/usb_msctest.h Fri Sep 9 07:44:14 2011 (r225458) @@ -40,5 +40,7 @@ int usb_iface_is_cdrom(struct usb_device uint8_t iface_index); usb_error_t usb_msc_eject(struct usb_device *udev, uint8_t iface_index, int method); +usb_error_t usb_msc_auto_quirk(struct usb_device *udev, + uint8_t iface_index); #endif /* _USB_MSCTEST_H_ */ Modified: stable/8/sys/dev/usb/usbdi.h ============================================================================== --- stable/8/sys/dev/usb/usbdi.h Fri Sep 9 04:42:11 2011 (r225457) +++ stable/8/sys/dev/usb/usbdi.h Fri Sep 9 07:44:14 2011 (r225458) @@ -353,6 +353,7 @@ struct usbd_lookup_info { uint16_t idVendor; uint16_t idProduct; uint16_t bcdDevice; + uint16_t autoQuirk[USB_MAX_AUTO_QUIRK]; uint8_t bDeviceClass; uint8_t bDeviceSubClass; uint8_t bDeviceProtocol; @@ -475,6 +476,8 @@ void device_set_usb_desc(device_t dev); void usb_pause_mtx(struct mtx *mtx, int _ticks); usb_error_t usbd_set_pnpinfo(struct usb_device *udev, uint8_t iface_index, const char *pnpinfo); +usb_error_t usbd_add_dynamic_quirk(struct usb_device *udev, + uint16_t quirk); const struct usb_device_id *usbd_lookup_id_by_info( const struct usb_device_id *id, usb_size_t sizeof_id, Modified: stable/8/sys/sys/param.h ============================================================================== --- stable/8/sys/sys/param.h Fri Sep 9 04:42:11 2011 (r225457) +++ stable/8/sys/sys/param.h Fri Sep 9 07:44:14 2011 (r225458) @@ -58,7 +58,7 @@ * in the range 5 to 9. */ #undef __FreeBSD_version -#define __FreeBSD_version 802510 /* Master, propagated to newvers */ +#define __FreeBSD_version 802511 /* Master, propagated to newvers */ #ifdef _KERNEL #define P_OSREL_SIGSEGV 700004 _______________________________________________ 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 owner-freebsd-usb@FreeBSD.ORG Sat Sep 10 16:00:26 2011 Return-Path: Delivered-To: freebsd-usb@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A559E1065670 for ; Sat, 10 Sep 2011 16:00:26 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 9289C8FC17 for ; Sat, 10 Sep 2011 16:00:26 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p8AG0QO4041891 for ; Sat, 10 Sep 2011 16:00:26 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p8AG0QL1041879; Sat, 10 Sep 2011 16:00:26 GMT (envelope-from gnats) Date: Sat, 10 Sep 2011 16:00:26 GMT Message-Id: <201109101600.p8AG0QL1041879@freefall.freebsd.org> To: freebsd-usb@FreeBSD.org From: dfilter@FreeBSD.ORG (dfilter service) Cc: Subject: Re: usb/160299: commit references a PR X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: dfilter service List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 10 Sep 2011 16:00:26 -0000 The following reply was made to PR usb/160299; it has been noted by GNATS. From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: usb/160299: commit references a PR Date: Sat, 10 Sep 2011 15:55:46 +0000 (UTC) Author: hselasky Date: Sat Sep 10 15:55:36 2011 New Revision: 225469 URL: http://svn.freebsd.org/changeset/base/225469 Log: Refactor auto-quirk solution so that we break as few external drivers as possible. PR: usb/160299 Approved by: re (kib) Suggested by: rwatson MFC after: 0 days Modified: head/sys/dev/usb/quirk/usb_quirk.c head/sys/dev/usb/usb_device.c head/sys/dev/usb/usb_dynamic.c head/sys/dev/usb/usb_dynamic.h head/sys/dev/usb/usbdi.h head/sys/sys/param.h Modified: head/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- head/sys/dev/usb/quirk/usb_quirk.c Sat Sep 10 12:36:11 2011 (r225468) +++ head/sys/dev/usb/quirk/usb_quirk.c Sat Sep 10 15:55:36 2011 (r225469) @@ -588,7 +588,7 @@ usb_test_quirk_by_info(const struct usbd } mtx_unlock(&usb_quirk_mtx); done: - return (usb_test_quirk_w(info, quirk)); + return (0); /* no quirk match */ } static struct usb_quirk_entry * Modified: head/sys/dev/usb/usb_device.c ============================================================================== --- head/sys/dev/usb/usb_device.c Sat Sep 10 12:36:11 2011 (r225468) +++ head/sys/dev/usb/usb_device.c Sat Sep 10 15:55:36 2011 (r225469) @@ -1239,8 +1239,6 @@ static void usb_init_attach_arg(struct usb_device *udev, struct usb_attach_arg *uaa) { - uint8_t x; - memset(uaa, 0, sizeof(*uaa)); uaa->device = udev; @@ -1256,9 +1254,6 @@ usb_init_attach_arg(struct usb_device *u uaa->info.bDeviceProtocol = udev->ddesc.bDeviceProtocol; uaa->info.bConfigIndex = udev->curr_config_index; uaa->info.bConfigNum = udev->curr_config_no; - - for (x = 0; x != USB_MAX_AUTO_QUIRK; x++) - uaa->info.autoQuirk[x] = udev->autoQuirk[x]; } /*------------------------------------------------------------------------* @@ -2389,8 +2384,22 @@ uint8_t usb_test_quirk(const struct usb_attach_arg *uaa, uint16_t quirk) { uint8_t found; + uint8_t x; + + if (quirk == UQ_NONE) + return (0); + + /* search the automatic per device quirks first */ + + for (x = 0; x != USB_MAX_AUTO_QUIRK; x++) { + if (uaa->device->autoQuirk[x] == quirk) + return (1); + } + + /* search global quirk table, if any */ found = (usb_test_quirk_p) (&uaa->info, quirk); + return (found); } @@ -2723,7 +2732,8 @@ usbd_add_dynamic_quirk(struct usb_device uint8_t x; for (x = 0; x != USB_MAX_AUTO_QUIRK; x++) { - if (udev->autoQuirk[x] == 0) { + if (udev->autoQuirk[x] == 0 || + udev->autoQuirk[x] == quirk) { udev->autoQuirk[x] = quirk; return (0); /* success */ } Modified: head/sys/dev/usb/usb_dynamic.c ============================================================================== --- head/sys/dev/usb/usb_dynamic.c Sat Sep 10 12:36:11 2011 (r225468) +++ head/sys/dev/usb/usb_dynamic.c Sat Sep 10 15:55:36 2011 (r225469) @@ -50,12 +50,12 @@ #include #include #include -#include /* function prototypes */ static usb_handle_req_t usb_temp_get_desc_w; static usb_temp_setup_by_index_t usb_temp_setup_by_index_w; static usb_temp_unsetup_t usb_temp_unsetup_w; +static usb_test_quirk_t usb_test_quirk_w; static usb_quirk_ioctl_t usb_quirk_ioctl_w; /* global variables */ @@ -72,19 +72,9 @@ usb_temp_setup_by_index_w(struct usb_dev return (USB_ERR_INVAL); } -uint8_t +static uint8_t usb_test_quirk_w(const struct usbd_lookup_info *info, uint16_t quirk) { - uint8_t x; - - if (quirk == UQ_NONE) - return (0); /* no match */ - - for (x = 0; x != USB_MAX_AUTO_QUIRK; x++) { - if (info->autoQuirk[x] == quirk) - return (1); /* match */ - } - return (0); /* no match */ } Modified: head/sys/dev/usb/usb_dynamic.h ============================================================================== --- head/sys/dev/usb/usb_dynamic.h Sat Sep 10 12:36:11 2011 (r225468) +++ head/sys/dev/usb/usb_dynamic.h Sat Sep 10 15:55:36 2011 (r225469) @@ -57,6 +57,5 @@ extern devclass_t usb_devclass_ptr; void usb_temp_unload(void *); void usb_quirk_unload(void *); void usb_bus_unload(void *); -usb_test_quirk_t usb_test_quirk_w; #endif /* _USB_DYNAMIC_H_ */ Modified: head/sys/dev/usb/usbdi.h ============================================================================== --- head/sys/dev/usb/usbdi.h Sat Sep 10 12:36:11 2011 (r225468) +++ head/sys/dev/usb/usbdi.h Sat Sep 10 15:55:36 2011 (r225469) @@ -353,7 +353,6 @@ struct usbd_lookup_info { uint16_t idVendor; uint16_t idProduct; uint16_t bcdDevice; - uint16_t autoQuirk[USB_MAX_AUTO_QUIRK]; uint8_t bDeviceClass; uint8_t bDeviceSubClass; uint8_t bDeviceProtocol; Modified: head/sys/sys/param.h ============================================================================== --- head/sys/sys/param.h Sat Sep 10 12:36:11 2011 (r225468) +++ head/sys/sys/param.h Sat Sep 10 15:55:36 2011 (r225469) @@ -58,7 +58,7 @@ * in the range 5 to 9. */ #undef __FreeBSD_version -#define __FreeBSD_version 900043 /* Master, propagated to newvers */ +#define __FreeBSD_version 900044 /* Master, propagated to newvers */ #ifdef _KERNEL #define P_OSREL_SIGSEGV 700004 _______________________________________________ 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 owner-freebsd-usb@FreeBSD.ORG Sat Sep 10 17:00:25 2011 Return-Path: Delivered-To: freebsd-usb@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1750D106566C for ; Sat, 10 Sep 2011 17:00:25 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id ED4FC8FC08 for ; Sat, 10 Sep 2011 17:00:24 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p8AH0OuL096697 for ; Sat, 10 Sep 2011 17:00:24 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p8AH0O6A096696; Sat, 10 Sep 2011 17:00:24 GMT (envelope-from gnats) Date: Sat, 10 Sep 2011 17:00:24 GMT Message-Id: <201109101700.p8AH0O6A096696@freefall.freebsd.org> To: freebsd-usb@FreeBSD.org From: dfilter@FreeBSD.ORG (dfilter service) Cc: Subject: Re: usb/160299: commit references a PR X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: dfilter service List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 10 Sep 2011 17:00:25 -0000 The following reply was made to PR usb/160299; it has been noted by GNATS. From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: usb/160299: commit references a PR Date: Sat, 10 Sep 2011 16:52:30 +0000 (UTC) Author: hselasky Date: Sat Sep 10 16:52:15 2011 New Revision: 225470 URL: http://svn.freebsd.org/changeset/base/225470 Log: MFC r225469: Refactor auto-quirk solution so that we break as few external drivers as possible. PR: usb/160299 Suggested by: rwatson Modified: stable/8/sys/dev/usb/quirk/usb_quirk.c stable/8/sys/dev/usb/usb_device.c stable/8/sys/dev/usb/usb_device.h stable/8/sys/dev/usb/usb_dynamic.c stable/8/sys/dev/usb/usb_dynamic.h stable/8/sys/dev/usb/usbdi.h stable/8/sys/sys/param.h Directory Properties: 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/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- stable/8/sys/dev/usb/quirk/usb_quirk.c Sat Sep 10 15:55:36 2011 (r225469) +++ stable/8/sys/dev/usb/quirk/usb_quirk.c Sat Sep 10 16:52:15 2011 (r225470) @@ -588,7 +588,7 @@ usb_test_quirk_by_info(const struct usbd } mtx_unlock(&usb_quirk_mtx); done: - return (usb_test_quirk_w(info, quirk)); + return (0); /* no quirk match */ } static struct usb_quirk_entry * Modified: stable/8/sys/dev/usb/usb_device.c ============================================================================== --- stable/8/sys/dev/usb/usb_device.c Sat Sep 10 15:55:36 2011 (r225469) +++ stable/8/sys/dev/usb/usb_device.c Sat Sep 10 16:52:15 2011 (r225470) @@ -1239,8 +1239,6 @@ static void usb_init_attach_arg(struct usb_device *udev, struct usb_attach_arg *uaa) { - uint8_t x; - memset(uaa, 0, sizeof(*uaa)); uaa->device = udev; @@ -1256,9 +1254,6 @@ usb_init_attach_arg(struct usb_device *u uaa->info.bDeviceProtocol = udev->ddesc.bDeviceProtocol; uaa->info.bConfigIndex = udev->curr_config_index; uaa->info.bConfigNum = udev->curr_config_no; - - for (x = 0; x != USB_MAX_AUTO_QUIRK; x++) - uaa->info.autoQuirk[x] = udev->autoQuirk[x]; } /*------------------------------------------------------------------------* @@ -2389,8 +2384,22 @@ uint8_t usb_test_quirk(const struct usb_attach_arg *uaa, uint16_t quirk) { uint8_t found; + uint8_t x; + + if (quirk == UQ_NONE) + return (0); + + /* search the automatic per device quirks first */ + + for (x = 0; x != USB_MAX_AUTO_QUIRK; x++) { + if (uaa->device->autoQuirk[x] == quirk) + return (1); + } + + /* search global quirk table, if any */ found = (usb_test_quirk_p) (&uaa->info, quirk); + return (found); } @@ -2798,7 +2807,8 @@ usbd_add_dynamic_quirk(struct usb_device uint8_t x; for (x = 0; x != USB_MAX_AUTO_QUIRK; x++) { - if (udev->autoQuirk[x] == 0) { + if (udev->autoQuirk[x] == 0 || + udev->autoQuirk[x] == quirk) { udev->autoQuirk[x] = quirk; return (0); /* success */ } Modified: stable/8/sys/dev/usb/usb_device.h ============================================================================== --- stable/8/sys/dev/usb/usb_device.h Sat Sep 10 15:55:36 2011 (r225469) +++ stable/8/sys/dev/usb/usb_device.h Sat Sep 10 16:52:15 2011 (r225470) @@ -149,7 +149,6 @@ struct usb_device { uint16_t power; /* mA the device uses */ uint16_t langid; /* language for strings */ - uint16_t autoQuirk[USB_MAX_AUTO_QUIRK]; /* dynamic quirks */ uint8_t address; /* device addess */ uint8_t device_index; /* device index in "bus->devices" */ @@ -191,6 +190,8 @@ struct usb_device { #endif uint32_t clear_stall_errors; /* number of clear-stall failures */ + + uint16_t autoQuirk[USB_MAX_AUTO_QUIRK]; /* dynamic quirks */ }; /* globals */ Modified: stable/8/sys/dev/usb/usb_dynamic.c ============================================================================== --- stable/8/sys/dev/usb/usb_dynamic.c Sat Sep 10 15:55:36 2011 (r225469) +++ stable/8/sys/dev/usb/usb_dynamic.c Sat Sep 10 16:52:15 2011 (r225470) @@ -50,12 +50,12 @@ #include #include #include -#include /* function prototypes */ static usb_handle_req_t usb_temp_get_desc_w; static usb_temp_setup_by_index_t usb_temp_setup_by_index_w; static usb_temp_unsetup_t usb_temp_unsetup_w; +static usb_test_quirk_t usb_test_quirk_w; static usb_quirk_ioctl_t usb_quirk_ioctl_w; /* global variables */ @@ -72,19 +72,9 @@ usb_temp_setup_by_index_w(struct usb_dev return (USB_ERR_INVAL); } -uint8_t +static uint8_t usb_test_quirk_w(const struct usbd_lookup_info *info, uint16_t quirk) { - uint8_t x; - - if (quirk == UQ_NONE) - return (0); /* no match */ - - for (x = 0; x != USB_MAX_AUTO_QUIRK; x++) { - if (info->autoQuirk[x] == quirk) - return (1); /* match */ - } - return (0); /* no match */ } Modified: stable/8/sys/dev/usb/usb_dynamic.h ============================================================================== --- stable/8/sys/dev/usb/usb_dynamic.h Sat Sep 10 15:55:36 2011 (r225469) +++ stable/8/sys/dev/usb/usb_dynamic.h Sat Sep 10 16:52:15 2011 (r225470) @@ -57,6 +57,5 @@ extern devclass_t usb_devclass_ptr; void usb_temp_unload(void *); void usb_quirk_unload(void *); void usb_bus_unload(void *); -usb_test_quirk_t usb_test_quirk_w; #endif /* _USB_DYNAMIC_H_ */ Modified: stable/8/sys/dev/usb/usbdi.h ============================================================================== --- stable/8/sys/dev/usb/usbdi.h Sat Sep 10 15:55:36 2011 (r225469) +++ stable/8/sys/dev/usb/usbdi.h Sat Sep 10 16:52:15 2011 (r225470) @@ -353,7 +353,6 @@ struct usbd_lookup_info { uint16_t idVendor; uint16_t idProduct; uint16_t bcdDevice; - uint16_t autoQuirk[USB_MAX_AUTO_QUIRK]; uint8_t bDeviceClass; uint8_t bDeviceSubClass; uint8_t bDeviceProtocol; Modified: stable/8/sys/sys/param.h ============================================================================== --- stable/8/sys/sys/param.h Sat Sep 10 15:55:36 2011 (r225469) +++ stable/8/sys/sys/param.h Sat Sep 10 16:52:15 2011 (r225470) @@ -58,7 +58,7 @@ * in the range 5 to 9. */ #undef __FreeBSD_version -#define __FreeBSD_version 802511 /* Master, propagated to newvers */ +#define __FreeBSD_version 802512 /* Master, propagated to newvers */ #ifdef _KERNEL #define P_OSREL_SIGSEGV 700004 _______________________________________________ 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"