qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Gerd Hoffmann <kraxel@redhat.com>
To: Paul Brook <paul@codesourcery.com>
Cc: qemu-devel@nongnu.org, Markus Armbruster <armbru@redhat.com>
Subject: Re: [Qemu-devel] Re: [PATCH] scsi: Make device scsi-disk reject /dev/sg*
Date: Mon, 01 Mar 2010 09:13:53 +0100	[thread overview]
Message-ID: <4B8B7741.7060707@redhat.com> (raw)
In-Reply-To: <201002280145.38065.paul@codesourcery.com>

On 02/28/10 02:45, Paul Brook wrote:
>> 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.
>
> Don't we really want to be testing !bdrv_is_block() ?

That would work for linux.  Dunno about the BSD.

cheers,
   Gerd

  reply	other threads:[~2010-03-01  8:14 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-25 10:23 [Qemu-devel] [PATCH] scsi: Make device scsi-disk reject /dev/sg* Markus Armbruster
2010-02-25 11:19 ` [Qemu-devel] " Gerd Hoffmann
2010-02-25 11:58   ` Markus Armbruster
2010-02-28  1:45   ` Paul Brook
2010-03-01  8:13     ` Gerd Hoffmann [this message]
2010-02-25 11:47 ` Michael S. Tsirkin
2010-03-09 15:01 ` [Qemu-devel] " Anthony Liguori

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4B8B7741.7060707@redhat.com \
    --to=kraxel@redhat.com \
    --cc=armbru@redhat.com \
    --cc=paul@codesourcery.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).