qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Fam Zheng <famz@redhat.com>
To: Markus Armbruster <armbru@redhat.com>
Cc: kwolf@redhat.com, qemu-block@nongnu.org,
	"Mark Cave-Ayland" <mark.cave-ayland@ilande.co.uk>,
	qemu-devel@nongnu.org, mreitz@redhat.com,
	"Hervé Poussineau" <hpoussin@reactos.org>,
	"John Snow" <jsnow@redhat.com>
Subject: Re: [Qemu-devel] [PATCH v2 8/8] hw: Drop superfluous special checks for orphaned -drive
Date: Fri, 3 Feb 2017 22:07:06 +0800	[thread overview]
Message-ID: <20170203140706.GD28271@lemon> (raw)
In-Reply-To: <87vasrl7ls.fsf@dusky.pond.sub.org>

On Fri, 02/03 14:35, Markus Armbruster wrote:
> > I guess the painpoint is "okay, what the heck does the machine support then?" -
> 
> At the place where we can reliably detect orphaned drives regardless of
> what the machine initialization code does, we have no idea.
> 
> > that "3 > 2" is the good part of the old message.
> 
> At the places that actually adopt drives, we know.  But there are many
> of them.  Just three check for orphans.  One of them gets it right
> (ide/core.c), one of them gets it wrong (mips_jazz.c), and one of them
> sets a problematic example (sun4m.c): if copied to a machine that lets
> users configure additional SCSI HBAs, it would break if=scsi for those.
> Dampens my enthusiasm for improving the error message by adding similar
> checks to all the places that adopt drives.
> 
> We could make machines declare what they support.  Better, I think.  So
> if you have a burning desire to leave your mark in git-blame for every
> machine...

Could you please remind me the situation about if=scsi across all machines? If
it is simply legacy and it's recommended to use "-drive if=none" and "-device
...", I think saying this in the error message is enough; or if "if=scsi" is a
valid way for some machines, then maybe we can declare support limits found with
your script?

Fam

> 
> > Do we have a user documentation for this? Or, can we give a hint how to figure
> > that out?
> 
> Try it out:
> 
>     for i in ide scsi floppy pflash mtd sd virtio xen
>     do
>         for ((b=0; b<4; b++))
>         do
>             for ((u=0; u<10; u++))
>             do
>                 echo q | qemu-system-x86_64 -nodefaults -S -display none -monitor stdio -drive if=$i,bus=$b,unit=$u,file=tmp.qcow2 >/dev/null
>             done
>         done
>     done
> 
> My upper bounds for bus and unit are arbitrary.

  reply	other threads:[~2017-02-03 14:07 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-26 15:09 [Qemu-devel] [PATCH v2 0/8] More sensible default for -drive interface type Markus Armbruster
2017-01-26 15:09 ` [Qemu-devel] [PATCH v2 1/8] hw: Default -drive to if=ide explicitly where it works Markus Armbruster
2017-01-26 20:02   ` Thomas Huth
2017-01-27  6:55     ` Markus Armbruster
2017-01-27 10:21       ` Yongbok Kim
2017-01-27 10:31         ` [Qemu-devel] MIPS machines (was: [PATCH v2 1/8] hw: Default -drive to if=ide explicitly where it works) Thomas Huth
2017-01-27 11:01           ` [Qemu-devel] MIPS machines Yongbok Kim
2017-01-26 15:09 ` [Qemu-devel] [PATCH v2 2/8] hw/arm/cubieboard hw/arm/xlnx-ep108: Fix units_per_default_bus Markus Armbruster
2017-01-27 18:33   ` Alistair Francis
2017-01-26 15:09 ` [Qemu-devel] [PATCH v2 3/8] hw: Default -drive to if=none instead of ide when ide cannot work Markus Armbruster
2017-01-26 15:22   ` Laurent Vivier
2017-01-26 16:00   ` Thomas Huth
2017-01-26 15:09 ` [Qemu-devel] [PATCH v2 4/8] hw: Default -drive to if=none instead of scsi when scsi " Markus Armbruster
2017-01-26 17:59   ` Thomas Huth
2017-01-27 18:31     ` Alistair Francis
2017-01-26 15:09 ` [Qemu-devel] [PATCH v2 5/8] hw/arm/highbank: Default -drive to if=ide instead of if=scsi Markus Armbruster
2017-01-26 18:10   ` Thomas Huth
2017-01-26 15:09 ` [Qemu-devel] [PATCH v2 6/8] blockdev: Improve message for orphaned -drive Markus Armbruster
2017-01-26 15:09 ` [Qemu-devel] [PATCH v2 7/8] blockdev: Make orphaned -drive fatal Markus Armbruster
2017-01-31 12:37   ` [Qemu-devel] [Qemu-block] " John Snow
2017-01-31 14:37     ` Markus Armbruster
2017-01-31 15:37       ` John Snow
2017-02-01  9:00         ` Markus Armbruster
2017-01-26 15:09 ` [Qemu-devel] [PATCH v2 8/8] hw: Drop superfluous special checks for orphaned -drive Markus Armbruster
2017-01-27 11:00   ` John Snow
2017-01-27 11:51     ` Markus Armbruster
2017-01-27 14:15       ` John Snow
2017-01-27 16:04         ` Markus Armbruster
2017-01-28  8:53           ` John Snow
2017-01-30  8:10             ` Markus Armbruster
2017-01-30  8:28               ` John Snow
2017-02-03 11:04               ` Fam Zheng
2017-02-03 13:35                 ` Markus Armbruster
2017-02-03 14:07                   ` Fam Zheng [this message]
2017-02-03 15:38                     ` Markus Armbruster

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=20170203140706.GD28271@lemon \
    --to=famz@redhat.com \
    --cc=armbru@redhat.com \
    --cc=hpoussin@reactos.org \
    --cc=jsnow@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mark.cave-ayland@ilande.co.uk \
    --cc=mreitz@redhat.com \
    --cc=qemu-block@nongnu.org \
    --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).