All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christian Borntraeger <borntraeger@de.ibm.com>
To: Markus Armbruster <armbru@redhat.com>
Cc: "Kevin Wolf" <kwolf@redhat.com>,
	"Peter Maydell" <peter.maydell@linaro.org>,
	"Anthony Liguori" <aliguori@us.ibm.com>,
	"Igor Mitsyanko" <i.mitsyanko@samsung.com>,
	"Alexander Graf" <agraf@suse.de>,
	"qemu-devel qemu-devel" <qemu-devel@nongnu.org>,
	"Jens Freimann" <jfrei@linux.vnet.ibm.com>,
	"Stefan Hajnoczi" <stefanha@redhat.com>,
	"Cornelia Huck" <cornelia.huck@de.ibm.com>,
	"Andreas Färber" <afaerber@suse.de>,
	"Einar Lueck" <elelueck@de.ibm.com>
Subject: Re: [Qemu-devel] [PATCH 1/1] Support default block interfaces per QEMUMachine
Date: Tue, 20 Nov 2012 12:22:59 +0100	[thread overview]
Message-ID: <50AB6813.60608@de.ibm.com> (raw)
In-Reply-To: <87ip91smw1.fsf@blackfin.pond.sub.org>

On 19/11/12 15:11, Markus Armbruster wrote:
> 
> Generalizing QEMUMachine member use_scsi to a default BlockInterfaceType
> makes plenty of sense to me.

Great.

> 
> I'm not sure "no initializer means IDE" is such a hot idea, but since
> it's how use_scsi has always worked, I'm okay with making its
> replacement work like that, too.

This actually makes sure that simple qemu command lines (without libvirt) provide
sane defaults for users, so I will try to keep that.

> 
> Like Alex, I dislike inventing yet another enumeration for this
> purpose.  Let's use BlockInterfaceType.

OK, will try to come up with something else.
> 
> In theory, we can change values of internal enumerations freely.  In
> practice, such changes can run afoul of leaky abstractions, such as C89
> array initializers and sloppy tests against zero.  Careful review
> advised.
> 

Indeed, I did it that way to avoid problems in code that implicitely assumes IF_NONE
if nothing is specified. Fortunately there are only a small number of code places
that actually check for IF_NONE (e.g. drive_hot_add).

I will try to review each place before re-submitting.

Christian

  reply	other threads:[~2012-11-20 11:23 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-12  8:22 [Qemu-devel] [PATCH 0/1] Default block interface per machine Christian Borntraeger
2012-11-12  8:22 ` [Qemu-devel] [PATCH 1/1] Support default block interfaces per QEMUMachine Christian Borntraeger
2012-11-13  8:03   ` Christian Borntraeger
2012-11-19 13:36   ` Alexander Graf
2012-11-19 13:44     ` Christian Borntraeger
2012-11-19 13:47       ` Alexander Graf
2012-11-19 14:11         ` Markus Armbruster
2012-11-20 11:22           ` Christian Borntraeger [this message]
2012-11-20 13:01             ` Stefan Hajnoczi

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=50AB6813.60608@de.ibm.com \
    --to=borntraeger@de.ibm.com \
    --cc=afaerber@suse.de \
    --cc=agraf@suse.de \
    --cc=aliguori@us.ibm.com \
    --cc=armbru@redhat.com \
    --cc=cornelia.huck@de.ibm.com \
    --cc=elelueck@de.ibm.com \
    --cc=i.mitsyanko@samsung.com \
    --cc=jfrei@linux.vnet.ibm.com \
    --cc=kwolf@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@redhat.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.