Re: [PATCH] qemu: add PCI-multibus support for ppc

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

 



On 02/28/2014 10:10 AM, Hong-Hua.Yin@xxxxxxxxxxxxx wrote:
> Hi Daniel,
> 
> Refer to libvirt/src/qemu/qemu_capabilities.c, only x86_64/i686 support PCI_MULTIBUS.
>     /* Currently only x86_64 and i686 support PCI-multibus. */
>     if (qemuCaps->arch == VIR_ARCH_X86_64 ||
>         qemuCaps->arch == VIR_ARCH_I686) {
>         virQEMUCapsSet(qemuCaps, QEMU_CAPS_PCI_MULTIBUS);
> 
> libvirt/src/qemu/qemu_capabilities.h:
>     QEMU_CAPS_PCI_MULTIBUS       = 52, /* bus=pci.0 vs bus=pci */
> 
> 
> Exactly there're several PowerPC platforms also use pci.0 as PCI bus name.
> $ grep -r "pci\.0"  qemu/hw/
> qemu/hw/ppc/prep.c:    pci_bus = (PCIBus *)qdev_get_child_bus(dev, "pci.0");
> qemu/hw/ppc/e500.c:    pci_bus = (PCIBus *)qdev_get_child_bus(dev, "pci.0");
> qemu/hw/ppc/ppc440_bamboo.c:    pcibus = (PCIBus *)qdev_get_child_bus(dev, "pci.0");
> 

Looking at 'info qtree' output it seems "pseries" is the only PPC machine type
using "pci" (out of those I managed to run):
ppce500
    bus: pci.0
mac99
    bus: pci.0
g3beige
    bus: pci.0
mpc8544ds
    bus: pci.0
ref405ep
qemu-system-ppc64: Could not load PowerPC BIOS 'ppc405_rom.bin'
taihu
qemu-system-ppc64: Could not load PowerPC BIOS 'ppc405_rom.bin'
bamboo
    bus: pci.0
prep
    bus: pci.0
pseries
Warning: Disabling some instructions which are not emulated by TCG (0x0, 0x4)
    bus: pci
virtex-ml507

> There's no much platform specific code in libvirt.
> How can we get the exact PCI bus name and make "pci.0" work on the above PowerPC platforms?

I think we need to check the def->os.machine string on PPC, since we only
probe a particular QEMU binary, not every machine type it supports.

Jan

Attachment: signature.asc
Description: OpenPGP digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]