Changeset 97030 in vbox for trunk/src/VBox/Devices
- Timestamp:
- Oct 6, 2022 2:16:55 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/VirtIO/VirtioCore.cpp
r96407 r97030 1560 1560 else 1561 1561 if (VIRTIO_DEV_CONFIG_MATCH_MEMBER( uVirtqSelect, VIRTIO_PCI_COMMON_CFG_T, uOffsetOfAccess)) 1562 VIRTIO_DEV_CONFIG_ACCESS( uVirtqSelect, VIRTIO_PCI_COMMON_CFG_T, uOffsetOfAccess, pVirtio); 1562 { 1563 if (fWrite) { 1564 uint16_t uVirtqNew = *(uint16_t *)pv; 1565 1566 if (uVirtqNew < RT_ELEMENTS(pVirtio->aVirtqueues)) 1567 VIRTIO_DEV_CONFIG_ACCESS( uVirtqSelect, VIRTIO_PCI_COMMON_CFG_T, uOffsetOfAccess, pVirtio); 1568 else 1569 LogFunc(("... WARNING: Guest attempted to write invalid virtq selector (ignoring)\n")); 1570 } 1571 else 1572 VIRTIO_DEV_CONFIG_ACCESS( uVirtqSelect, VIRTIO_PCI_COMMON_CFG_T, uOffsetOfAccess, pVirtio); 1573 } 1563 1574 else 1564 1575 if (VIRTIO_DEV_CONFIG_MATCH_MEMBER( GCPhysVirtqDesc, VIRTIO_PCI_COMMON_CFG_T, uOffsetOfAccess)) … … 1718 1729 1719 1730 if (VIRTIO_DEV_CONFIG_MATCH_MEMBER( uVirtqSelect, VIRTIO_LEGACY_PCI_COMMON_CFG_T, offPort)) 1720 VIRTIO_DEV_CONFIG_ACCESS( uVirtqSelect, VIRTIO_LEGACY_PCI_COMMON_CFG_T, offPort, pVirtio); 1731 { 1732 if (u32 < RT_ELEMENTS(pVirtio->aVirtqueues)) 1733 VIRTIO_DEV_CONFIG_ACCESS( uVirtqSelect, VIRTIO_LEGACY_PCI_COMMON_CFG_T, offPort, pVirtio); 1734 else 1735 LogFunc(("... WARNING: Guest attempted to write invalid virtq selector (ignoring)\n")); 1736 } 1721 1737 else 1722 1738 #ifdef LEGACY_MSIX_SUPPORTED
Note:
See TracChangeset
for help on using the changeset viewer.