From owner-freebsd-usb@FreeBSD.ORG Mon Jan 1 00:08:02 2007 Return-Path: X-Original-To: freebsd-usb@freebsd.org Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A9A2816A403 for ; Mon, 1 Jan 2007 00:08:02 +0000 (UTC) (envelope-from nate@root.org) Received: from root.org (root.org [67.118.192.226]) by mx1.freebsd.org (Postfix) with ESMTP id 8FF7913C45E for ; Mon, 1 Jan 2007 00:08:02 +0000 (UTC) (envelope-from nate@root.org) Received: (qmail 63629 invoked from network); 31 Dec 2006 23:41:23 -0000 Received: from ppp-71-139-40-196.dsl.snfc21.pacbell.net (HELO ?10.0.5.59?) (nate-mail@71.139.40.196) by root.org with ESMTPA; 31 Dec 2006 23:41:23 -0000 Message-ID: <45984A97.3080201@root.org> Date: Sun, 31 Dec 2006 15:41:11 -0800 From: Nate Lawson User-Agent: Thunderbird 1.5.0.9 (Windows/20061207) MIME-Version: 1.0 To: Ivan Frosty References: <7fd638000612310125n672d11e9j6cfc20a080c443de@mail.gmail.com> In-Reply-To: <7fd638000612310125n672d11e9j6cfc20a080c443de@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-scsi@freebsd.org, freebsd-usb@freebsd.org Subject: Re: problem with samsung flash 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, 01 Jan 2007 00:08:02 -0000 Ivan Frosty wrote: > hello there, i have freebsd 6.1 pentiumII 355mhz processor and 128mb > of ram. everytime i put my samsung 512mb in tha usb the machine doesnt > boot it halts where the error be at if i pull it out it > boots.........then if i put it back in i get an error.......whats with > umass? i basically installed everybit and software of the unix i have > so i dont know why i get the error anyhelp will be highly appreciated! > > this is the error: > > da0 at umass-sim0 bus0 target0wn0 > da0: Removable Direct Access SCSI-0 device > da0:1.000MB/s transfers > da0:511mb(1046720 512 byte sectors:64H 32s/T s11c) > umass0:phase Error, residue = 0 > (da0:umass-sim0:0:0:0):synchronize cache failed, status == 0x4,scsi > status == 0x0 opened disk da0->5! > > thank you for your time Hi, this is a common error and should be a FAQ somewhere. Some USB devices can't handle SYNC CACHE, the command that says to write their data out to storage. Most can or reject it with an error and continue. Some hang, including yours. You can add a SCSI quirk (no sync cache). See the entries at the beginning of scsi_da.c for an example how to do it. Your string would be "SAMSUNG", "flash Disk", "*". See if that helps. As far has fixing this problem permanently, does anyone have an idea on how the experimental work went with disabling sync cache if the INQ data indicates the device doesn't cache data (similar to Linux)? Also, what do the scsi@ guys think of me adding a tunable/sysctl that is unit-specific so people can disable it without a quirk? Example: dev.da.0.no_sync_cache="1". It would be off by default, of course. -- Nate