[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL v3 31/32] intel_iommu: a fix to vtd_find_as_from_bus_num()
From: |
Michael S. Tsirkin |
Subject: |
[PULL v3 31/32] intel_iommu: a fix to vtd_find_as_from_bus_num() |
Date: |
Sun, 5 Jan 2020 07:59:59 -0500 |
From: Liu Yi L <address@hidden>
Ensure the return value of vtd_find_as_from_bus_num() is NULL by
enforcing vtd_bus=NULL. This would help caller of vtd_find_as_from_bus_num()
to decide if any further operation on the returned vtd_bus.
Cc: address@hidden
Cc: Kevin Tian <address@hidden>
Cc: Jacob Pan <address@hidden>
Cc: Peter Xu <address@hidden>
Cc: Yi Sun <address@hidden>
Signed-off-by: Liu Yi L <address@hidden>
Signed-off-by: Yi Sun <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Peter Xu <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>
---
hw/i386/intel_iommu.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/hw/i386/intel_iommu.c b/hw/i386/intel_iommu.c
index ee06993675..609b80750a 100644
--- a/hw/i386/intel_iommu.c
+++ b/hw/i386/intel_iommu.c
@@ -948,6 +948,7 @@ static VTDBus *vtd_find_as_from_bus_num(IntelIOMMUState *s,
uint8_t bus_num)
return vtd_bus;
}
}
+ vtd_bus = NULL;
}
return vtd_bus;
}
--
MST
- [PULL v3 20/32] virtio-mmio: Clear v2 transport state on soft reset, (continued)
- [PULL v3 20/32] virtio-mmio: Clear v2 transport state on soft reset, Michael S. Tsirkin, 2020/01/05
- [PULL v3 21/32] hw/pci/pci_host: Remove redundant PCI_DPRINTF(), Michael S. Tsirkin, 2020/01/05
- [PULL v3 22/32] hw/pci/pci_host: Let pci_data_[read/write] use unsigned 'size' argument, Michael S. Tsirkin, 2020/01/05
- [PULL v3 23/32] vhost-user: add VHOST_USER_RESET_DEVICE to reset devices, Michael S. Tsirkin, 2020/01/05
- [PULL v3 24/32] vhost-user-scsi: reset the device if supported, Michael S. Tsirkin, 2020/01/05
- [PULL v3 25/32] hw: fix using 4.2 compat in 5.0 machine types for i440fx/q35, Michael S. Tsirkin, 2020/01/05
- [PULL v3 26/32] virtio: make seg_max virtqueue size dependent, Michael S. Tsirkin, 2020/01/05
- [PULL v3 28/32] virtio-mmio: update queue size on guest write, Michael S. Tsirkin, 2020/01/05
- [PULL v3 29/32] virtio: reset region cache when on queue deletion, Michael S. Tsirkin, 2020/01/05
- [PULL v3 30/32] virtio-net: delete also control queue when TX/RX deleted, Michael S. Tsirkin, 2020/01/05
- [PULL v3 31/32] intel_iommu: a fix to vtd_find_as_from_bus_num(),
Michael S. Tsirkin <=
- [PULL v3 32/32] intel_iommu: add present bit check for pasid table entries, Michael S. Tsirkin, 2020/01/05
- [PULL v3 27/32] tests: add virtio-scsi and virtio-blk seg_max_adjust test, Michael S. Tsirkin, 2020/01/05
- Re: [PULL v3 00/32] virtio, pci, pc: fixes, features, Peter Maydell, 2020/01/06
- [PULL v3 00/32] virtio, pci, pc: fixes, features, Michael S. Tsirkin, 2020/01/07
- [PULL v3 01/32] virtio: add ability to delete vq through a pointer, Michael S. Tsirkin, 2020/01/07
- [PULL v3 02/32] virtio: make virtio_delete_queue idempotent, Michael S. Tsirkin, 2020/01/07
- [PULL v3 03/32] virtio-balloon: fix memory leak while attach virtio-balloon device, Michael S. Tsirkin, 2020/01/07
- [PULL v3 04/32] virtio-serial-bus: fix memory leak while attach virtio-serial-bus, Michael S. Tsirkin, 2020/01/07
- [PULL v3 05/32] virtio-input: convert to new virtio_delete_queue, Michael S. Tsirkin, 2020/01/07