From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NkbkS-0003eY-0w for qemu-devel@nongnu.org; Thu, 25 Feb 2010 06:19:16 -0500 Received: from [199.232.76.173] (port=60332 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NkbkR-0003e0-FP for qemu-devel@nongnu.org; Thu, 25 Feb 2010 06:19:15 -0500 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NkbkP-0007ez-Rf for qemu-devel@nongnu.org; Thu, 25 Feb 2010 06:19:14 -0500 Received: from mx1.redhat.com ([209.132.183.28]:50322) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NkbkO-0007eo-Ft for qemu-devel@nongnu.org; Thu, 25 Feb 2010 06:19:13 -0500 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o1PBJ9Kx017306 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Thu, 25 Feb 2010 06:19:09 -0500 Message-ID: <4B865CA8.4010505@redhat.com> Date: Thu, 25 Feb 2010 12:19:04 +0100 From: Gerd Hoffmann MIME-Version: 1.0 References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Re: [PATCH] scsi: Make device scsi-disk reject /dev/sg* List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Markus Armbruster Cc: qemu-devel@nongnu.org On 02/25/10 11:23, Markus Armbruster wrote: > You're supposed to use scsi-generic for that. Which rejects anything > but /dev/sg*. Well, it isn't *that* easy. The SG_IO ioctl used by scsi-generic works on tons of devices in linux, not only /dev/sg*. I've seen patches floading around which change the check bdrv_is_sg() into "try SG_IO and see if it works", which would allow to use /dev/sda with both scsi-disk and scsi-generic depending on what you want. Which makes alot of sense. Making that change needs some extra care though to avoid existing configurations switching from scsi-disk to scsi-generic unnoticed. cheers, Gerd