[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v12 03/15] pcie: modify the capability size assert
From: |
Chen Hanxiao |
Subject: |
[Qemu-devel] [PATCH v12 03/15] pcie: modify the capability size assert |
Date: |
Thu, 16 Jul 2015 12:00:41 +0800 |
From: Chen Fan <address@hidden>
Device's Offset and size can reach PCIE_CONFIG_SPACE_SIZE,
fix the corresponding assert.
Signed-off-by: Chen Fan <address@hidden>
Reviewed-by: Marcel Apfelbaum <address@hidden>
Signed-off-by: Chen Hanxiao <address@hidden>
---
hw/pci/pcie.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/pci/pcie.c b/hw/pci/pcie.c
index 6e28985..d66fb10 100644
--- a/hw/pci/pcie.c
+++ b/hw/pci/pcie.c
@@ -594,7 +594,7 @@ void pcie_add_capability(PCIDevice *dev,
assert(offset >= PCI_CONFIG_SPACE_SIZE);
assert(offset < offset + size);
- assert(offset + size < PCIE_CONFIG_SPACE_SIZE);
+ assert(offset + size <= PCIE_CONFIG_SPACE_SIZE);
assert(size >= 8);
assert(pci_is_express(dev));
--
2.1.0
- [Qemu-devel] [PATCH v12 00/15] vfio-pci: pass the aer error to guest, Chen Hanxiao, 2015/07/16
- [Qemu-devel] [PATCH v12 02/15] vfio: squeeze out vfio_pci_do_hot_reset for support bus reset, Chen Hanxiao, 2015/07/16
- [Qemu-devel] [PATCH v12 04/15] vfio: make the 4 bytes aligned for capability size, Chen Hanxiao, 2015/07/16
- [Qemu-devel] [PATCH v12 03/15] pcie: modify the capability size assert,
Chen Hanxiao <=
- [Qemu-devel] [PATCH v12 05/15] vfio: add pcie extanded capability support, Chen Hanxiao, 2015/07/16
- [Qemu-devel] [PATCH v12 06/15] aer: impove pcie_aer_init to support vfio device, Chen Hanxiao, 2015/07/16
- [Qemu-devel] [PATCH v12 08/15] vfio: add check host bus reset is support or not, Chen Hanxiao, 2015/07/16
- [Qemu-devel] [PATCH v12 07/15] vfio: add aer support for vfio device, Chen Hanxiao, 2015/07/16
- [Qemu-devel] [PATCH v12 09/15] pci: add bus reset_notifiers callbacks for host bus reset, Chen Hanxiao, 2015/07/16
- [Qemu-devel] [PATCH v12 11/15] vfio: modify vfio_pci_hot_reset to support bus reset, Chen Hanxiao, 2015/07/16
- [Qemu-devel] [PATCH v12 13/15] pcie_aer: expose pcie_aer_msg() interface, Chen Hanxiao, 2015/07/16
- [Qemu-devel] [PATCH v12 10/15] vfio: add sec_bus_reset notifier to notify physical bus reset is needed, Chen Hanxiao, 2015/07/16
- [Qemu-devel] [PATCH v12 14/15] vfio-pci: pass the aer error to guest, Chen Hanxiao, 2015/07/16
- [Qemu-devel] [PATCH v12 12/15] vfio: do hot bus reset when do virtual secondary bus reset, Chen Hanxiao, 2015/07/16