Well, this patch works fine for me. Gleb Natapov wrote: > On Thu, Jul 22, 2010 at 07:11:34PM +0800, Hao, Xudong wrote: >> Gleb, >> This patch does not work either, qemu stoped @ Starting Seabios. >> > And this one? > > diff --git a/hw/device-assignment.c b/hw/device-assignment.c > index 2bba22f..b7e7dc0 100644 > --- a/hw/device-assignment.c > +++ b/hw/device-assignment.c > @@ -238,9 +238,10 @@ static void > assigned_dev_iomem_map_slow(PCIDevice *pci_dev, int region_num, > DEBUG("%s", "slow map\n"); if (region_num == PCI_ROM_SLOT) > m = cpu_register_io_memory(slow_bar_read, NULL, region); > - else > + else { > m = cpu_register_io_memory(slow_bar_read, slow_bar_write, > region); - cpu_register_physical_memory(e_phys, e_size, m); > + cpu_register_physical_memory(e_phys, e_size, m); > + } > > /* MSI-X MMIO page */ > if ((e_size > 0) && > @@ -272,7 +273,8 @@ static void assigned_dev_iomem_map(PCIDevice > *pci_dev, int region_num, if (region_num == PCI_ROM_SLOT) > flags |= IO_MEM_ROM; > > - cpu_register_physical_memory(e_phys, e_size, > region->memory_index | flags); + if (region_num != > PCI_ROM_SLOT) + cpu_register_physical_memory(e_phys, e_size, > region->memory_index | flags); > > /* deal with MSI-X MMIO page */ > if (real_region->base_addr <= r_dev->msix_table_addr && Thanks, Xudong-- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html