From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1763144AbYESSQy (ORCPT ); Mon, 19 May 2008 14:16:54 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1759700AbYESSQo (ORCPT ); Mon, 19 May 2008 14:16:44 -0400 Received: from palinux.external.hp.com ([192.25.206.14]:50416 "EHLO mail.parisc-linux.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753951AbYESSQn (ORCPT ); Mon, 19 May 2008 14:16:43 -0400 Date: Mon, 19 May 2008 12:16:41 -0600 From: Matthew Wilcox To: Linus Torvalds Cc: Boaz Harrosh , Alan Stern , Maciej Rutecki , Linux Kernel Mailing List , USB list , USB Storage list , SCSI development list Subject: Re: [Re: Linux 2.6.26-rc2] Write protect on on Message-ID: <20080519181641.GE2638@parisc-linux.org> References: <4831A60A.5010308@panasas.com> <4831B2E2.8030700@panasas.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.13 (2006-08-11) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 19, 2008 at 10:27:17AM -0700, Linus Torvalds wrote: > On Mon, 19 May 2008, Boaz Harrosh wrote: > > > > Sure, inspecting other places that emulate MODE_SENSE, (And inspecting the scsi > > spec) all zeros is a very good scsi response. Alan do you want to send a fix for all > > places that initiate a MODE_SENSE command, specifically at > > scsi_scan.c::scsi_unlock_floptical() ? (Some other places do) > > I was actualyl more thinking that the safest thing to do would be to just > pre-clear the sense buffer. Then, if some driver doesn't fill it > correctly, big deal.. > > It's not like pre-clearing the bugger is a performance issue. Actually, I think it might be. I don't have any hard evidence for this right now, but I'll let you know if I do. There's certainly a lot of L2 cache misses in the scsi command submission path. I'm not arguing that speed should trump performance, just we might want to not clear the sense buffer if we know we have a non-USB device. -- Intel are signing my paycheques ... these opinions are still mine "Bill, look, we understand that you're interested in selling us this operating system, but compare it to ours. We can't possibly take such a retrograde step."