Replace has_dynamic_sysbus with list of allowed device types
Status from this message: Queued on machine-next.
Get series with b4
b4 am [email protected]Versions newest first
Changes v1 (RFC) -> v2 from the cover letter
* Patch 1 now just adds TYPE_SYS_BUS_DEVICE to the existing has_dynamic_sysbus=true machines, and other patches make the lists on each machine-type more specific.
* Change the name of the new field to allowed_dynamic_sysbus_devices.
* The q35 allowed list is much shorter because the list of user-creatable sysbus devices in QEMU is shorter.
* Keep the xen_set_dynamic_sysbus() hack, just change it to add 'xen-sysdev" to the allowed list.
* Simplified the arm/virt code.
Patches in v2 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/6 | machine: Replace has_dynamic_sysbus with list of allowed deviceshw/ hw/ hw/ +4 more | +48 | 5 replies | |
| 2/6 | hw/arm/virt: Allow only supported dynamic sysbus deviceshw/ | +4 | 0 replies | |
| 3/6 | ppc: e500: Allow only supported dynamic sysbus deviceshw/ | +2 | 5 replies | |
| 4/6 | spapr: Allow only supported dynamic sysbus deviceshw/ | +1 | 2 replies | |
| 5/6 | xen: Add only xen-sysdev to dynamic sysbus device listhw/ | +1 | 2 replies | |
| 6/6 | q35: Allow only supported dynamic sysbus deviceshw/ | +4 | 2 replies |
Reviews trailers per patch
5 of 6 patches have a Reviewed-by or Acked-by.
| Patch | Greg Kurz | David Gibson | Marcel Apfelbaum | Marc-André Lureau | Anthony PERARD |
|---|---|---|---|---|---|
| 1/6 | R-b | R-b | R-b | R-b | |
| 2/6 | |||||
| 3/6 | R-b | A-b | |||
| 4/6 | R-b | A-b | |||
| 5/6 | R-b | A-b | |||
| 6/6 | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 5 reviewers.
Cover letter [Qemu-devel] [PATCH v2 0/6] Replace has_dynamic_sysbus with list of allowed device types
Changes v1 (RFC) -> v2:
* Patch 1 now just adds TYPE_SYS_BUS_DEVICE to the existing has_dynamic_sysbus=true machines, and other patches make the lists on each machine-type more specific.
* Change the name of the new field to allowed_dynamic_sysbus_devices.
* The q35 allowed list is much shorter because the list of user-creatable sysbus devices in QEMU is shorter.
* Keep the xen_set_dynamic_sysbus() hack, just change it to add 'xen-sysdev" to the allowed list.
* Simplified the arm/virt code.
Summary
-------
This series replaces the existing has_dynamic_sysbus flag (that makes the machine accept every user-creatable sysbus device type on the command-line) with a list of allowed devices.
This will be helpful when implementing the new query-device-slots command, because each machine type will include only the sysbus devices it really supports, instead of including a catch-all TYPE_SYS_BUS_DEVICE "slot".
This will be useful to add support to new sysbus devices on machines like pc_piix, that don't have has_dynamic_sysbus set today.
This also makes the code safer: just compiling a new sysbus device in the same QEMU binary won't make a machine-type automatically start accepting the device.
Eduardo Habkost (6):
machine: Replace has_dynamic_sysbus with list of allowed devices hw/arm/virt: Allow only supported dynamic sysbus devices
ppc: e500: Allow only supported dynamic sysbus devices
spapr: Allow only supported dynamic sysbus devices
xen: Add only xen-sysdev to dynamic sysbus device list
q35: Allow only supported dynamic sysbus devices
include/hw/boards.h | 5 ++++- hw/arm/virt.c | 5 ++++- hw/core/machine.c | 43 +++++++++++++++++++++++++++++-------------- hw/i386/pc_q35.c | 5 ++++- hw/ppc/e500plat.c | 4 +++- hw/ppc/spapr.c | 2 +- hw/xen/xen_backend.c | 2 +- 7 files changed, 46 insertions(+), 20 deletions(-)
Signature · 1 line
2.13.6