From: "Daniel P. Berrange" <berrange@redhat.com>
To: Kevin O'Connor <kevin@koconnor.net>
Cc: seabios@seabios.org, Gerd Hoffmann <kraxel@redhat.com>,
"Richard W.M. Jones" <rjones@redhat.com>,
qemu-devel <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] Hang when using 9p mounts after last Seabios update
Date: Tue, 11 Oct 2011 09:30:24 +0100 [thread overview]
Message-ID: <20111011083024.GA16057@redhat.com> (raw)
In-Reply-To: <20111001165043.GA16833@morn.localdomain>
On Sat, Oct 01, 2011 at 12:50:43PM -0400, Kevin O'Connor wrote:
> On Thu, Sep 22, 2011 at 12:45:11PM +0100, Daniel P. Berrange wrote:
> > On 0.14, 0.15 releaes, this all works just fine. On current GIT master,
> > the guest OS will hang during boot.
> [...]
> > To reproduce this you will need my custom initrd for mounting 9p filesystems
> > as the root FS. You can get that here:
> >
> > http://berrange.com/~dan/qemu-serial-hang-demo.tar.gz
>
> Thanks for the detailed report.
>
> I've confirmed the issue and tracked it down. The current SeaBIOS
> code gets confused during alignment checking if there are no prefmem
> regions found.
>
> The patch below should fix the issue.
Thanks, I have tested Seabios 1.6.3 which includes that patch, and
can confirm that it does fix the hang I saw.
Anthony/Gerd: we can get QEMU master updated to Seabios 1.6.3 before
the 1.0 release ?
> Author: Kevin O'Connor <kevin@koconnor.net>
> Date: Sat Oct 1 12:35:32 2011 -0400
>
> Fix alignment bug in pci_bios_init_root_regions().
>
> If there are no memory allocations for a given type then the "max" bar
> size is zero. However, ALIGN_DOWN does not handle an alignment of
> zero properly. Catch and handle the zero case.
>
> Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
>
> diff --git a/src/pciinit.c b/src/pciinit.c
> index a857da0..0d8758e 100644
> --- a/src/pciinit.c
> +++ b/src/pciinit.c
> @@ -536,7 +536,7 @@ static void pci_bios_init_bus_bases(struct pci_bus *bus)
> }
> }
>
> -#define ROOT_BASE(top, sum, align) ALIGN_DOWN((top)-(sum),(align))
> +#define ROOT_BASE(top, sum, max) ALIGN_DOWN((top)-(sum),(max) ?: 1)
>
> static int pci_bios_init_root_regions(u32 start, u32 end)
> {
Regards,
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
next prev parent reply other threads:[~2011-10-11 8:30 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-22 11:45 [Qemu-devel] Hang when using 9p mounts after last Seabios update Daniel P. Berrange
2011-09-28 0:53 ` Kevin O'Connor
2011-10-01 16:50 ` Kevin O'Connor
2011-10-01 17:32 ` Richard W.M. Jones
2011-10-11 8:30 ` Daniel P. Berrange [this message]
2011-10-11 16:45 ` Chris Krumme
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=20111011083024.GA16057@redhat.com \
--to=berrange@redhat.com \
--cc=kevin@koconnor.net \
--cc=kraxel@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=rjones@redhat.com \
--cc=seabios@seabios.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).