Skip to content

Commit

Permalink
lxd/instance/drivers: Replace util.ValueInSlice() with shared.ValueIn…
Browse files Browse the repository at this point in the history
…Slice()

Signed-off-by: Kadin Sayani <[email protected]>
  • Loading branch information
kadinsayani committed Aug 9, 2024
1 parent ecdd2f0 commit 4b217f7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lxd/instance/drivers/driver_qemu.go
Original file line number Diff line number Diff line change
Expand Up @@ -3439,7 +3439,7 @@ func (d *qemu) generateQemuConfigFile(cpuInfo *cpuTopology, mountInfo *storagePo
}

qemuDev := make(map[string]string)
if util.ValueInSlice(busName, []string{"nvme", "virtio-blk"}) {
if shared.ValueInSlice(busName, []string{"nvme", "virtio-blk"}) {
// Allocate a PCI(e) port and write it to the config file so QMP can "hotplug" the
// drive into it later.
devBus, devAddr, multi := bus.allocate(busFunctionGroupNone)
Expand Down Expand Up @@ -4087,7 +4087,7 @@ func (d *qemu) addDriveConfig(qemuDev map[string]string, bootIndexes map[string]
} else if media == "cdrom" {
qemuDev["driver"] = "scsi-cd"
}
} else if util.ValueInSlice(bus, []string{"nvme", "virtio-blk"}) {
} else if shared.ValueInSlice(bus, []string{"nvme", "virtio-blk"}) {
if qemuDev["bus"] == "" {
// Figure out a hotplug slot.
pciDevID := qemuPCIDeviceIDStart
Expand Down

0 comments on commit 4b217f7

Please sign in to comment.