HV: unify the sharing_mode_vpci_init and partition_mode_vpci_init code

Put the init code in init_vdev_for_pdev for both sos and pre-launched VMs, and
remove sharing_mode_vpci_init() and partition_mode_vpci_init().

Rename functions used by init_vdev_for_pdev:
 vhostbridge_init --> init_vhostbridge
 vmsi_init --> init_vmsi
 vmsix_init --> init_vmsix

Tracked-On: #3056
Signed-off-by: dongshen <dongsheng.x.zhang@intel.com>
Reviewed-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
dongshen
2019-05-14 14:27:30 -07:00
committed by ACRN System Integration
parent f873b843de
commit 3a6c63f2d8
5 changed files with 64 additions and 92 deletions

View File

@@ -45,7 +45,7 @@
* @pre vdev->vpci != NULL
* @pre vdev->vpci->vm != NULL
*/
void vhostbridge_init(struct pci_vdev *vdev)
void init_vhostbridge(struct pci_vdev *vdev)
{
if (is_hostbridge(vdev) && is_prelaunched_vm(vdev->vpci->vm)) {
/* PCI config space */