]> git.proxmox.com Git - qemu.git/commitdiff
pci: fix pci_find_bus()
authorIsaku Yamahata <yamahata@valinux.co.jp>
Mon, 8 Feb 2010 06:38:36 +0000 (15:38 +0900)
committerMichael S. Tsirkin <mst@redhat.com>
Mon, 8 Feb 2010 10:14:42 +0000 (12:14 +0200)
typo in c021f8e65f5009a5ab5711d9d5326fcab553ef1c.
comparison fix.

Cc: Blue Swirl <blauwirbel@gmail.com>
Cc: "Michael S. Tsirkin" <mst@redhat.com>
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/pci.c

index 9ad63dd94849e1bdda63ddac16369cdde4280e61..e91d2e693f70971ec77177e30dea2a56f86b8bc3 100644 (file)
--- a/hw/pci.c
+++ b/hw/pci.c
@@ -1558,7 +1558,7 @@ PCIBus *pci_find_bus(PCIBus *bus, int bus_num)
     /* try child bus */
     QLIST_FOREACH(sec, &bus->child, sibling) {
         if (!bus->parent_dev /* pci host bridge */
-            || (pci_bus_num(sec) >= bus_num &&
+            || (pci_bus_num(sec) <= bus_num &&
                 bus_num <= bus->parent_dev->config[PCI_SUBORDINATE_BUS]) ) {
             ret = pci_find_bus(sec, bus_num);
             if (ret) {