Revision b5937f29 hw/pci.c

b/hw/pci.c
1273 1273

  
1274 1274
static QObject *pci_get_dev_dict(PCIDevice *dev, PCIBus *bus, int bus_num)
1275 1275
{
1276
    int class;
1276
    uint8_t type;
1277 1277
    QObject *obj;
1278 1278

  
1279 1279
    obj = qobject_from_jsonf("{ 'bus': %d, 'slot': %d, 'function': %d,"                                       "'class_info': %p, 'id': %p, 'regions': %p,"
......
1289 1289
        qdict_put(qdict, "irq", qint_from_int(dev->config[PCI_INTERRUPT_LINE]));
1290 1290
    }
1291 1291

  
1292
    class = pci_get_word(dev->config + PCI_CLASS_DEVICE);
1293
    if (class == PCI_CLASS_BRIDGE_HOST || class == PCI_CLASS_BRIDGE_PCI) {
1292
    type = dev->config[PCI_HEADER_TYPE] & ~PCI_HEADER_TYPE_MULTI_FUNCTION;
1293
    if (type == PCI_HEADER_TYPE_BRIDGE) {
1294 1294
        QDict *qdict;
1295 1295
        QObject *pci_bridge;
1296 1296

  

Also available in: Unified diff