mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-20 16:28:10 +00:00
hv: vpci: remove vm structure pointer from vpci
We could use container_of to get vm structure pointer from vpci. So vm structure pointer is no need in vpci structure. Tracked-On: #4550 Signed-off-by: Li Fei1 <fei1.li@intel.com>
This commit is contained in:
@@ -88,7 +88,7 @@ static void remap_one_vmsix_entry(const struct pci_vdev *vdev, uint32_t index)
|
||||
info.vmsi_addr.full = vdev->msix.table_entries[index].addr;
|
||||
info.vmsi_data.full = vdev->msix.table_entries[index].data;
|
||||
|
||||
ret = ptirq_prepare_msix_remap(vdev->vpci->vm, vdev->bdf.value, vdev->pdev->bdf.value, (uint16_t)index, &info);
|
||||
ret = ptirq_prepare_msix_remap(vpci2vm(vdev->vpci), vdev->bdf.value, vdev->pdev->bdf.value, (uint16_t)index, &info);
|
||||
if (ret == 0) {
|
||||
/* Write the table entry to the physical structure */
|
||||
pentry = get_msix_table_entry(vdev, index);
|
||||
@@ -266,7 +266,7 @@ void deinit_vmsix(const struct pci_vdev *vdev)
|
||||
{
|
||||
if (has_msix_cap(vdev)) {
|
||||
if (vdev->msix.table_count != 0U) {
|
||||
ptirq_remove_msix_remapping(vdev->vpci->vm, vdev->bdf.value, vdev->msix.table_count);
|
||||
ptirq_remove_msix_remapping(vpci2vm(vdev->vpci), vdev->bdf.value, vdev->msix.table_count);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user