mirror of
https://github.com/aljazceru/kata-containers.git
synced 2025-12-24 01:24:26 +01:00
qemu: Add qemu parameter for PCI address for a bridge.
We need to be able to specify the PCI slot for a bridge while adding it. Add test to verify bridge is correctly added. Signed-off-by: Archana Shinde <archana.m.shinde@intel.com>
This commit is contained in:
@@ -365,6 +365,22 @@ func TestAppendDeviceSCSIController(t *testing.T) {
|
||||
testAppend(scsiCon, deviceSCSIControllerBusAddrStr, t)
|
||||
}
|
||||
|
||||
var deviceBridgeString = "-device pci-bridge,bus=/pci-bus/pcie.0,id=mybridge,chassis_nr=5,shpc=on,addr=ff"
|
||||
|
||||
func TestAppendBridgeDevice(t *testing.T) {
|
||||
|
||||
bridge := BridgeDevice{
|
||||
Type: PCIBridge,
|
||||
ID: "mybridge",
|
||||
Bus: "/pci-bus/pcie.0",
|
||||
Addr: "255",
|
||||
Chassis: 5,
|
||||
SHPC: true,
|
||||
}
|
||||
|
||||
testAppend(bridge, deviceBridgeString, t)
|
||||
}
|
||||
|
||||
func TestAppendEmptyDevice(t *testing.T) {
|
||||
device := SerialDevice{}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user