Add PCI device to VM
Open
Nobody has claimed this yet.
question
sample request
- Dominant language
- Python
- Stars
- 2.3k
- Forks
- 763
- PR merge metrics
- No merged PRs in 30d
Description
Appreciate any help on this, given below is what I am trying. But backing.deviceId I'm not able fetch properly.
pcispec = vim.vm.device.VirtualDeviceSpec()
pcispec.operation = vim.vm.device.VirtualDeviceSpec.Operation.add
pcispec.device = vim.vm.device.VirtualPCIPassthrough()
pcispec.device.key = -1
pcispec.device.backing = vim.vm.device.VirtualPCIPassthrough.DeviceBackingInfo()
pcispec.device.backing.id = '00:00.0'
pcispec.device.backing.deviceId = ??? (HostPciDevice.deviceId)
#pcispec.device.backing.systemId = ???
pcispec.device.connectable = vim.vm.device.VirtualDevice.ConnectInfo()
pcispec.device.connectable.startConnected = True
pcispec.device.connectable.allowGuestControl = True
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the shown VirtualPCIPassthrough and DeviceBackingInfo configuration, then consult the HostPciDevice fields referenced in the issue to determine the required deviceId and systemId values. Done means the PCI device can be added to a VM with a valid backing configuration; no repository file or test is named.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- api, infrastructure
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100