qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] Re: [SeaBIOS] [PATCH 0/2] pciinit: fix overflow when bar al


From: Isaku Yamahata
Subject: [Qemu-devel] Re: [SeaBIOS] [PATCH 0/2] pciinit: fix overflow when bar allocation
Date: Tue, 19 Oct 2010 10:56:55 +0900
User-agent: Mutt/1.5.19 (2009-01-05)

On Mon, Oct 18, 2010 at 11:47:42AM +0200, Michael S. Tsirkin wrote:
> On Mon, Oct 18, 2010 at 06:34:21PM +0900, Isaku Yamahata wrote:
> > This patch set fixes PCI bar allocation when bar overflow occured.
> > I checked if pmm_alloc facility can be used, but it doesn't suit for
> > pci bar allocation. So I resulted in new API, pci_region which
> > encapsulates region allocation and overflow checks.
> > The first patch introduces pci_region, and the second patch fixes
> > the overflow case with pci_region.
> > 
> > Isaku Yamahata (2):
> >   pci: introduce pci_region to manage pci io/memory/prefmemory regions.
> >   pciinit: use pci_region functions.
> > 
> >  Makefile         |    3 +-
> >  src/pci_region.c |   70 +++++++++++++++++++++++++++++++
> >  src/pciinit.c    |  122 
> > ++++++++++++++++++++++++++---------------------------
> >  src/util.h       |   15 +++++++
> >  4 files changed, 147 insertions(+), 63 deletions(-)
> >  create mode 100644 src/pci_region.c
> 
> Could you clarify what do you mean by bar overflow please?

This is originally raised by Cam.
http://www.seabios.org/pipermail/seabios/2010-August/000888.html
For example, pci_bios_bios() has *paddr += size.
It may overflow and really does with huge bar(1G, 2G...)
reported by Cam and Adnan.

This patch series is revised version of the following as
Kevin has requested me to try to use pmm_malloc() in order
to avoid ugly overflow check.
http://www.seabios.org/pipermail/seabios/2010-July/000794.html
-- 
yamahata



reply via email to

[Prev in Thread] Current Thread [Next in Thread]