From: Gleb Natapov <gleb@redhat.com>
To: Markus Armbruster <armbru@redhat.com>
Cc: blauwirbel@gmail.com, kevin@koconnor.net, qemu-devel@nongnu.org,
kvm@vger.kernel.org
Subject: Re: [Qemu-devel] [PATCHv8 12/16] Add bootindex parameter to net/block/fd device
Date: Wed, 2 Feb 2011 17:10:04 +0200 [thread overview]
Message-ID: <20110202151004.GM14984@redhat.com> (raw)
In-Reply-To: <m3k4hi8ofc.fsf@blackfin.pond.sub.org>
On Wed, Feb 02, 2011 at 04:08:07PM +0100, Markus Armbruster wrote:
> Gleb Natapov <gleb@redhat.com> writes:
>
> > If bootindex is specified on command line a string that describes device
> > in firmware readable way is added into sorted list. Later this list will
> > be passed into firmware to control boot order.
> >
> > Signed-off-by: Gleb Natapov <gleb@redhat.com>
>
> Just noticed something that slipped through review:
>
> [...]
> > diff --git a/vl.c b/vl.c
> > index 2cd263e..dadc161 100644
> > --- a/vl.c
> > +++ b/vl.c
> [...]
> > @@ -693,6 +704,35 @@ static void restore_boot_devices(void *opaque)
> > qemu_free(standard_boot_devices);
> > }
> >
> > +void add_boot_device_path(int32_t bootindex, DeviceState *dev,
> > + const char *suffix)
> > +{
> > + FWBootEntry *node, *i;
> > +
> > + if (bootindex < 0) {
> > + return;
> > + }
> > +
> > + assert(dev != NULL || suffix != NULL);
> > +
> > + node = qemu_mallocz(sizeof(FWBootEntry));
> > + node->bootindex = bootindex;
> > + node->suffix = strdup(suffix);
>
> qemu_strdup()?
>
Yap. Will fix.
> > + node->dev = dev;
> > +
> > + QTAILQ_FOREACH(i, &fw_boot_order, link) {
> > + if (i->bootindex == bootindex) {
> > + fprintf(stderr, "Two devices with same boot index %d\n", bootindex);
> > + exit(1);
> > + } else if (i->bootindex < bootindex) {
> > + continue;
> > + }
> > + QTAILQ_INSERT_BEFORE(i, node, link);
> > + return;
> > + }
> > + QTAILQ_INSERT_TAIL(&fw_boot_order, node, link);
> > +}
> > +
> > static void numa_add(const char *optarg)
> > {
> > char option[128];
--
Gleb.
next prev parent reply other threads:[~2011-02-02 15:10 UTC|newest]
Thread overview: 38+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-12-08 11:34 [Qemu-devel] [PATCHv8 00/16] boot order specification Gleb Natapov
2010-12-08 11:34 ` [Qemu-devel] [PATCHv8 01/16] Introduce fw_name field to DeviceInfo structure Gleb Natapov
2010-12-08 11:34 ` [Qemu-devel] [PATCHv8 02/16] Introduce new BusInfo callback get_fw_dev_path Gleb Natapov
2010-12-08 11:34 ` [Qemu-devel] [PATCHv8 03/16] Keep track of ISA ports ISA device is using in qdev Gleb Natapov
2010-12-08 11:34 ` [Qemu-devel] [PATCHv8 04/16] Add get_fw_dev_path callback to ISA bus " Gleb Natapov
2010-12-08 11:34 ` [Qemu-devel] [PATCHv8 05/16] Store IDE bus id in IDEBus structure for easy access Gleb Natapov
2010-12-08 11:34 ` [Qemu-devel] [PATCHv8 06/16] Add get_fw_dev_path callback to IDE bus Gleb Natapov
2010-12-08 11:35 ` [Qemu-devel] [PATCHv8 07/16] Add get_fw_dev_path callback for system bus Gleb Natapov
2010-12-08 11:35 ` [Qemu-devel] [PATCHv8 08/16] Add get_fw_dev_path callback for pci bus Gleb Natapov
2010-12-08 11:35 ` [Qemu-devel] [PATCHv8 09/16] Record which USBDevice USBPort belongs too Gleb Natapov
2010-12-08 11:35 ` [Qemu-devel] [PATCHv8 10/16] Add get_fw_dev_path callback for usb bus Gleb Natapov
2010-12-08 11:35 ` [Qemu-devel] [PATCHv8 11/16] Add get_fw_dev_path callback to scsi bus Gleb Natapov
2010-12-08 11:35 ` [Qemu-devel] [PATCHv8 12/16] Add bootindex parameter to net/block/fd device Gleb Natapov
2011-01-28 13:29 ` Markus Armbruster
2011-01-28 15:53 ` Gleb Natapov
2011-01-28 17:19 ` Markus Armbruster
2011-02-02 15:08 ` Markus Armbruster
2011-02-02 15:10 ` Gleb Natapov [this message]
2011-02-02 15:12 ` Gleb Natapov
2010-12-08 11:35 ` [Qemu-devel] [PATCHv8 13/16] Change fw_cfg_add_file() to get full file path as a parameter Gleb Natapov
2010-12-08 11:35 ` [Qemu-devel] [PATCHv8 14/16] Add bootindex for option roms Gleb Natapov
2010-12-08 11:35 ` [Qemu-devel] [PATCHv8 15/16] Add notifier that will be called when machine is fully created Gleb Natapov
2010-12-08 11:35 ` [Qemu-devel] [PATCHv8 16/16] Pass boot device list to firmware Gleb Natapov
2010-12-11 15:13 ` [Qemu-devel] Re: [PATCHv8 00/16] boot order specification Blue Swirl
2010-12-11 16:06 ` Gleb Natapov
2010-12-11 17:19 ` Blue Swirl
2010-12-11 18:02 ` Gleb Natapov
2010-12-11 18:27 ` Gleb Natapov
2010-12-11 19:06 ` Blue Swirl
2010-12-11 19:11 ` Gleb Natapov
2010-12-11 23:27 ` Benjamin Herrenschmidt
2010-12-11 18:59 ` Blue Swirl
2010-12-11 23:22 ` Benjamin Herrenschmidt
2010-12-14 19:59 ` Andreas Färber
2010-12-14 20:31 ` Benjamin Herrenschmidt
2010-12-14 23:02 ` Alexander Graf
2010-12-17 14:05 ` Andreas Färber
2010-12-11 22:10 ` Blue Swirl
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=20110202151004.GM14984@redhat.com \
--to=gleb@redhat.com \
--cc=armbru@redhat.com \
--cc=blauwirbel@gmail.com \
--cc=kevin@koconnor.net \
--cc=kvm@vger.kernel.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).