From owner-freebsd-usb@FreeBSD.ORG Thu Oct 27 09:44:08 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 D25521065675 for ; Thu, 27 Oct 2011 09:44:08 +0000 (UTC) (envelope-from gperez@entel.upc.edu) Received: from dash.upc.es (dash.upc.es [147.83.2.50]) by mx1.freebsd.org (Postfix) with ESMTP id 439E98FC15 for ; Thu, 27 Oct 2011 09:44:07 +0000 (UTC) Received: from ackerman2.upc.es (ackerman2.upc.es [147.83.2.244]) by dash.upc.es (8.14.1/8.13.1) with ESMTP id p9R8D6pE019303 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Thu, 27 Oct 2011 10:13:06 +0200 Received: from portgus.lan ([147.83.40.234]) (authenticated bits=0) by ackerman2.upc.es (8.14.4/8.14.4) with ESMTP id p9R8CnC3030373 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Thu, 27 Oct 2011 10:13:05 +0200 Message-ID: <4EA9127E.80504@entel.upc.edu> Date: Thu, 27 Oct 2011 10:12:46 +0200 From: =?ISO-8859-1?Q?Gustau_P=E9rez?= User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:7.0.1) Gecko/20111018 Thunderbird/7.0.1 MIME-Version: 1.0 To: freebsd-usb@freebsd.org Content-Type: multipart/mixed; boundary="------------030105040408080408060908" X-Scanned-By: MIMEDefang 2.70 on 147.83.2.244 X-Mail-Scanned: Criba 2.0 + Clamd X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (dash.upc.es [147.83.2.50]); Thu, 27 Oct 2011 10:13:06 +0200 (CEST) Cc: Subject: Quirk for a USB mass storage device 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, 27 Oct 2011 09:44:08 -0000 This is a multi-part message in MIME format. --------------030105040408080408060908 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Hi, I'm running FreeBSD 10.0 r226042 on AMD64 and I'm having problems with the following device: umass0: on usbus0 umass0: SCSI over Bulk-Only; quirks = 0x4001 umass0: Get Max Lun not supported (USB_ERR_TIMEOUT) umass0:5:0:-1: Attached to scbus5 as you can see, UQ_MSC_NO_GETMAXLUN should be set to use the device. As it is a 64Gb mass storage I would like to use it. I tried to manually add the quirk and it worked. Later on I tried with 9.0Beta2/i386 on the same machine and the problem also appeared. So I made a patch (which works on CURRENT, did not try with STABLE) to add the quirk, which is attached. Hans: is it necessary to fill a PR with the patch or would it be enough with the inline patch? Gus --------------030105040408080408060908 Content-Type: text/plain; name="datatraveler-patch.txt" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="datatraveler-patch.txt" diff --git a/sys/dev/usb/quirk/usb_quirk.c b/sys/dev/usb/quirk/usb_quirk.c index 128fe2a..04d1dc8 100644 --- a/sys/dev/usb/quirk/usb_quirk.c +++ b/sys/dev/usb/quirk/usb_quirk.c @@ -230,6 +230,7 @@ static struct usb_quirk_entry usb_quirks[USB_DEV_QUIRKS_MAX] = { USB_QUIRK(JMICRON, JM20337, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_SYNC_CACHE), + USB_QUIRK(KINGSTON, DT200, 0x0000, 0xffff, UQ_MSC_NO_GETMAXLUN), USB_QUIRK(KYOCERA, FINECAM_L3, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_INQUIRY), USB_QUIRK(KYOCERA, FINECAM_S3X, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_CBI, diff --git a/sys/dev/usb/usbdevs b/sys/dev/usb/usbdevs index 5a4d3f4..0225694 100644 --- a/sys/dev/usb/usbdevs +++ b/sys/dev/usb/usbdevs @@ -2012,6 +2012,7 @@ product KEYSPAN UIA11 0x0202 UIA-11 remote control /* Kingston products */ product KINGSTON XX1 0x0008 Ethernet product KINGSTON KNU101TX 0x000a KNU101TX USB Ethernet +product KINGSTON DT200 0x1630 DATATRAVELER 200 /* Kawasaki products */ product KLSI DUH3E10BT 0x0008 USB Ethernet --------------030105040408080408060908--