fix(host): remove has pcie extend bus check

Signed-off-by: wanyaoqi <d3lx.yq@gmail.com>
This commit is contained in:
wanyaoqi
2022-11-09 21:55:42 +08:00
parent aa9492578f
commit 929770264d
2 changed files with 2 additions and 4 deletions
+1 -1
View File
@@ -175,7 +175,7 @@ func (s *SKVMGuestInstance) initMachineDefaultDevices() error {
func (s *SKVMGuestInstance) initGuestPciControllers() (*desc.PCIController, *desc.PCIController) {
var isPcie = s.isPcie()
var pciRoot, pciBridge *desc.PCIController
if isPcie && s.hasPcieExtendBus() {
if isPcie {
pciRoot = s.addPCIController(desc.CONTROLLER_TYPE_PCIE_ROOT, "")
s.addPCIController(desc.CONTROLLER_TYPE_PCIE_TO_PCI_BRIDGE, desc.CONTROLLER_TYPE_PCIE_ROOT)
pciBridge = s.addPCIController(desc.CONTROLLER_TYPE_PCI_BRIDGE, desc.CONTROLLER_TYPE_PCIE_TO_PCI_BRIDGE)
+1 -3
View File
@@ -2163,9 +2163,7 @@ func (s *SKVMGuestInstance) OnResumeSyncMetadataInfo() {
} else {
meta.Set("__cpu_mode", jsonutils.NewString(api.CPU_MODE_HOST))
}
if s.hasPcieExtendBus() {
meta.Set("__pcie_extend_bus", jsonutils.JSONTrue)
}
meta.Set("__pcie_extend_bus", jsonutils.JSONTrue)
cmdline, err := s.getQemuCmdline()
if err != nil {
log.Errorf("Get qemu process cmdline error: %v", err)