Page MenuHomeFreeBSD

bhyvectl: Add device hotplugging options
Needs ReviewPublic

Authored by bnovkov on Sun, Jan 11, 1:33 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Jan 19, 6:14 PM
Unknown Object (File)
Sat, Jan 17, 7:14 AM
Unknown Object (File)
Fri, Jan 16, 8:12 PM
Unknown Object (File)
Thu, Jan 15, 5:54 PM
Unknown Object (File)
Mon, Jan 12, 3:53 AM
Unknown Object (File)
Sun, Jan 11, 11:50 PM
Unknown Object (File)
Sun, Jan 11, 4:17 PM

Details

Reviewers
None
Group Reviewers
bhyve
Summary

This change introduces the --pci-{add,remove} options which allow
users to add or remove emulated PCI devices to an active virtual machine.

--pci-add's argument follows the same format as bhyve's -s option,
with the only difference being that --pci-add does not take a
bus:slot:function string. When asked to hotplug a device,
bhyvectl creates a new nvlist and uses libbhyve's
pci_parse_config and pci_init_fds routines to populate it with the
appropriate key/value pairs and file descriptors. It will then
invoke the appropriate bhyve IPC command.

--pci-remove takes a bus:slot:function string as an argument.
The argument can also be specified in all of the same formats
used by bhyve's -s flag.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 69802
Build 66685: arc lint + arc unit