From owner-freebsd-usb@FreeBSD.ORG Wed Jan 22 12:56:40 2014 Return-Path: Delivered-To: freebsd-usb@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id D21C014B for ; Wed, 22 Jan 2014 12:56:40 +0000 (UTC) Received: from mta05.bitpro.no (mta05.bitpro.no [92.42.64.202]) by mx1.freebsd.org (Postfix) with ESMTP id 5A47515F0 for ; Wed, 22 Jan 2014 12:56:40 +0000 (UTC) Received: from mail.lockless.no (mail.lockless.no [46.29.221.38]) by mta05.bitpro.no (Postfix) with ESMTPS id 3D7ED17FC80; Wed, 22 Jan 2014 13:56:32 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by mail.lockless.no (Postfix) with ESMTP id 7BDF416053C; Wed, 22 Jan 2014 13:57:22 +0100 (CET) X-Virus-Scanned: by amavisd-new-2.6.4 (20090625) (Debian) at lockless.no Received: from mail.lockless.no ([127.0.0.1]) by localhost (mail.lockless.no [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id mlgJc9OxIdm1; Wed, 22 Jan 2014 13:57:21 +0100 (CET) Received: from laptop015.home.selasky.org (cm-176.74.213.204.customer.telag.net [176.74.213.204]) by mail.lockless.no (Postfix) with ESMTPSA id 7ECE816053B; Wed, 22 Jan 2014 13:57:21 +0100 (CET) Message-ID: <52DFC03F.6090002@bitfrost.no> Date: Wed, 22 Jan 2014 13:57:35 +0100 From: Hans Petter Selasky Organization: Bitfrost A/S User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.1.0 MIME-Version: 1.0 To: =?ISO-8859-1?Q?Gerrit_K=FChn?= , freebsd-usb@FreeBSD.org Subject: Re: ATP USB flash failure (regression?) References: <20140122134116.1c589702.gerrit.kuehn@aei.mpg.de> In-Reply-To: <20140122134116.1c589702.gerrit.kuehn@aei.mpg.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 Jan 2014 12:56:41 -0000 On 01/22/14 13:41, Gerrit Kühn wrote: > Hi all, > > I have USB-attached flash media by ATP that worked on my FreeBSD 9.2 System not too long ago: > > --- > ugen1.4: at usbus1 > umass0: on usbus1 > umass0: SCSI over Bulk-Only; quirks = 0x0100 > umass0:8:0:-1: Attached to scbus8 > da8 at umass-sim0 bus 0 scbus8 target 0 lun 0 > da8: Fixed Direct Access SCSI-0 device > da8: 40.000MB/s transfers > da8: 1960MB (4014080 512 byte sectors: 255H 63S/T 249C) > da8: quirks=0x2 > --- > > > After pulling in the most recent updates from the 9.2-stable branch, it looks like this does not work anymore: > > --- > ugen1.4: at usbus1 > umass0: on usbus1 > umass0: SCSI over Bulk-Only; quirks = 0x4101 > umass0:8:0:-1: Attached to scbus8 > (probe0:umass-sim0:0:0:0): INQUIRY. CDB: 12 00 00 00 24 00 > (probe0:umass-sim0:0:0:0): CAM status: CCB request completed with an error > (probe0:umass-sim0:0:0:0): Retrying command > Trying to mount root from ufs:/dev/mirror/root [rw]... > (probe0:umass-sim0:0:0:0): INQUIRY. CDB: 12 00 00 00 24 00 > (probe0:umass-sim0:0:0:0): CAM status: CCB request completed with an error > (probe0:umass-sim0:0:0:0): Retrying command > ZFS filesystem version: 5 > ZFS storage pool version: features support (5000) > (probe0:umass-sim0:0:0:0): INQUIRY. CDB: 12 00 00 00 24 00 > (probe0:umass-sim0:0:0:0): CAM status: CCB request completed with an error > (probe0:umass-sim0:0:0:0): Retrying command > igb0: link state changed to UP > (probe0:umass-sim0:0:0:0): INQUIRY. CDB: 12 00 00 00 24 00 > (probe0:umass-sim0:0:0:0): CAM status: CCB request completed with an error > (probe0:umass-sim0:0:0:0): Retrying command > arp: 10.117.0.1 moved from 00:1a:8c:f0:14:e1 to 00:1a:8c:f0:14:e0 on igb0 > (probe0:umass-sim0:0:0:0): INQUIRY. CDB: 12 00 00 00 24 00 > (probe0:umass-sim0:0:0:0): CAM status: CCB request completed with an error > (probe0:umass-sim0:0:0:0): Error 5, Retries exhausted > --- > > > It looks like the quieks have changed and do not work anymore now... Does anybody have an idea how to fix this? Hi, It looks like the auto-quirk code for USB mass storage, which was activated recently is changing the quirks for your device. The INQUIRY command is expected to fail. Does the device work, or are you just worried about the warnings in dmesg? You can get more information by setting: sysctl hw.usb.usb.debug=15 while plugging your device. Search for "msctest" keyword. QUIRKS 0x4101 are: #define NO_SYNCHRONIZE_CACHE 0x4000 #define NO_GETMAXLUN 0x0100 #define NO_TEST_UNIT_READY 0x0001 If you add this quirk, the msctest logic will be disabled: usbconfig -d X.Y add_quirk NO_SYNCHRONIZE_CACHE You need to replug the device after adding the quirk. See also: sys/dev/usb/quirk/usb_quirk.c For permanent quirks. --HPS