hv: vpci: restore vbdf when pci dev un-assigned from uos
When a pci device assined to UOS, the virtual bdf is allocated by device model. After the pci device un-assigned from UOS, it is back to SOS. The virtual bdf should be restored. The virtual bdf equals physical bdf for a pci device in SOS. Tracked-On: #2788 Signed-off-by: Binbin Wu <binbin.wu@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
parent
7669a76f95
commit
906c79eb40
|
@ -251,6 +251,8 @@ void vpci_reset_ptdev_intr_info(const struct acrn_vm *target_vm, uint16_t vbdf,
|
|||
|
||||
if (vm != NULL) {
|
||||
vdev->vpci = &vm->vpci;
|
||||
/* vbdf equals to pbdf in sos */
|
||||
vdev->vbdf.value = vdev->pdev->bdf.value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue