On Fri, Jan 10, 2014 at 04:17:14PM +0100, Igor Mammedov wrote: > On Thu, 9 Jan 2014 17:12:41 -0200 > Eduardo Habkost <ehabk...@redhat.com> wrote: > > > The original SeaBIOS code used the RamSize variable, that was used by > > SeaBIOS for the size of RAM below 4GB, not for all RAM. When copied to > > QEMU, the code was changed to use the full RAM size, and this broke the > > build_srat() code that handles the PCI hole. > > > > This series fixes the problem by restoring the original behavior from > > SeaBIOS. > > [...] > > > > Eduardo Habkost (2): > > pc: Save size of RAM below 4GB > > acpi-build: Fix PCI hole handling on build_srat() > > > > hw/i386/acpi-build.c | 10 +++++----- > > hw/i386/pc.c | 1 + > > include/hw/i386/pc.h | 2 +- > > 3 files changed, 7 insertions(+), 6 deletions(-) > > > > since purpose of the the block you are touching is to exclude PCI hole > from SRAT could you use acpi_get_pci_info() instead?
That would make sense, but as that was not the original behavior from SeaBIOS, I prefer to first fix this obvious and simple translation mistake, and then make the code able to use acpi_get_pci_info() (which won't be as trivial to write/review as this fix). (I didn't even review the existing PCI hole exclusion logic myself. I simply made sure that the code matches what's inside SeaBIOS today and is known to work.) -- Eduardo