From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NDKru-00069r-MF for qemu-devel@nongnu.org; Wed, 25 Nov 2009 11:37:26 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NDKrp-0005xH-TA for qemu-devel@nongnu.org; Wed, 25 Nov 2009 11:37:26 -0500 Received: from [199.232.76.173] (port=58413 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NDKrp-0005wl-OD for qemu-devel@nongnu.org; Wed, 25 Nov 2009 11:37:21 -0500 Received: from mx1.redhat.com ([209.132.183.28]:2521) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NDKrp-00017u-Al for qemu-devel@nongnu.org; Wed, 25 Nov 2009 11:37:21 -0500 Message-ID: <4B0D5D36.6080100@redhat.com> Date: Wed, 25 Nov 2009 17:37:10 +0100 From: Gerd Hoffmann MIME-Version: 1.0 Subject: Re: [Qemu-devel] [sneak preview] major scsi overhaul References: <4AF4ACA5.2090701@redhat.com> <200911161853.34668.paul@codesourcery.com> <4B0BCAA1.3090400@redhat.com> <200911241351.03650.paul@codesourcery.com> In-Reply-To: <200911241351.03650.paul@codesourcery.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paul Brook Cc: qemu-devel@nongnu.org On 11/24/09 14:51, Paul Brook wrote: > On Tuesday 24 November 2009, Gerd Hoffmann wrote: >> On 11/16/09 19:53, Paul Brook wrote: >>> Capping the amount of memory required for a transfer *is* implemented, in >>> both LSI and virtio-blk. The exception being SCSI passthrough where the >>> kernel API makes it impossible. >> >> Well. Figured while doing more testing: The allowed request size is >> limited by the kernel, so scsi-generic requests larger than (currently) >> 128k fail. >> >> Now, how to handle *that*? Is there some way to signal to the guest >> that the request was to big? > > Same as real hardware. Probably also want to populate the Block Limits VPD > page appropriately Some experiements later. Linux reads the block limits vpd, but seems to ignore the hard limit. Answering large requests with "Illegal request, Invalid field in CDB" doesn't makes linux try smaller requests, instead it reports I/O errors to the syslog. Hmm. netbsd and winxp don't try large requests in the first place (they do 64k max). Other guests not tried yet. cheers, Gerd