From owner-freebsd-scsi@FreeBSD.ORG Tue Feb 27 14:48:57 2007 Return-Path: X-Original-To: scsi@freebsd.org Delivered-To: freebsd-scsi@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 63FB416A405 for ; Tue, 27 Feb 2007 14:48:57 +0000 (UTC) (envelope-from scottl@samsco.org) Received: from pooker.samsco.org (pooker.samsco.org [168.103.85.57]) by mx1.freebsd.org (Postfix) with ESMTP id EF1FD13C4A5 for ; Tue, 27 Feb 2007 14:48:56 +0000 (UTC) (envelope-from scottl@samsco.org) Received: from phobos.samsco.home (phobos.samsco.home [192.168.254.11]) (authenticated bits=0) by pooker.samsco.org (8.13.4/8.13.4) with ESMTP id l1REmkhS041153; Tue, 27 Feb 2007 07:48:51 -0700 (MST) (envelope-from scottl@samsco.org) Message-ID: <45E444C6.40607@samsco.org> Date: Tue, 27 Feb 2007 07:48:38 -0700 From: Scott Long User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:1.8.1.2pre) Gecko/20070111 SeaMonkey/1.1 MIME-Version: 1.0 To: Matthew Jacob References: <45DE6C64.8020400@samsco.org> <20070223.100839.112608684.imp@bsdimp.com> <7579f7fb0702231017rdc246ebqeface91c9d5481e3@mail.gmail.com> <20070225.230019.1649768891.imp@bsdimp.com> <7579f7fb0702252331m7d3a61c5u224d898b4f04248c@mail.gmail.com> <45E3092A.5040404@samsco.org> <7579f7fb0702261041ld6f4a09q732bbbc419cf1c73@mail.gmail.com> In-Reply-To: <7579f7fb0702261041ld6f4a09q732bbbc419cf1c73@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-2.0.2 (pooker.samsco.org [168.103.85.57]); Tue, 27 Feb 2007 07:48:52 -0700 (MST) X-Spam-Status: No, score=-1.4 required=3.8 tests=ALL_TRUSTED autolearn=failed version=3.1.1 X-Spam-Checker-Version: SpamAssassin 3.1.1 (2006-03-10) on pooker.samsco.org Cc: "M. Warner Losh" , scsi@freebsd.org Subject: Re: Quirk for this? X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Feb 2007 14:48:57 -0000 I understand what you're saying. If you look in the umass driver, there is already a mechanism for quirks as well as a fairly large collection of quirks for bad SCSI protocol behavior from devices. These should all move up to CAM, I agree. However, what exists in CAM right now for XPORT-specific support is just a series of 'if' statements scattered around cam_xpt.c. If you moved Warner's quirk up as well as the other umass quirks, you're going to quickly make a royal mess out of cam_xpt.c. That's what I want to avoid. Once we figure out exactly what we want out of the XPORT code and get it a little more defined and organized, I think we can then start moving the quirks out of the umass driver. Until then, solving Warner's problem via umass.c is easy and doesn't complicate the end goal much at all. Scott Matthew Jacob wrote: > It may be a property specific to USB devices, but the code affected is > a property of the end target at the end of a transport, not the > transport itself. > > On 2/26/07, Scott Long wrote: >> Matthew Jacob wrote: >> >> >> >> I took a look at Linux, and they have a quirk for this. A bunch of >> >> cameras have this bug, as do iPods and a few media readers... >> >> >> > >> > So, is your take then we should have a "subtract by N" read capacity >> quirk? >> >> If it's just a USB property, I'd like to avoid adding a quirk to the CAM >> core, especially one that requires multiple arguments. >> >> Scott >> >>