nova/nova/objects
Stephen Finucane 3f63c68195 libvirt: Add support for virtio-based input devices
The USB-based tablet is often the only USB device in an x86 instance,
while the USB-based keyboard is often the only such device in an AArch64
instance (x86 have PS2 keyboards and mice). Replacing these with
virtio-based devices can eliminate the need to have a USB host adapter
in the instance. Enable just that possibility by adding a new value
image metadata property, 'hw_input_bus'. This allows us to specify not
only virtio-based pointer and keyboard input devices but also USB
equivalents.

Note that this also fixes one instance of a particular class of bugs,
whereby we have checks for *guest* architecture-specific behavior that
are being toggled based on the *host* architecture. In this instance,
we were attempting to add a keyboard device on AArch64 guests since they
don't have one by default, but we were determining the architecture by
looking at the CPU architecture reported in the host capabilities. By
replacing this check of the host capabilities with a call to the
'nova.virt.libvirt.utils.get_arch' helper, we correctly handle requests
to create non-host architecture guests via the 'hw_architecture' image
metadata property. There are many other instances of this bug and those
can be resolved separately.

Change-Id: If9f3ede3e8449f9a6c8d1da927974c0a73923d51
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
2021-03-05 11:00:02 +00:00
..
__init__.py objects: Remove Agent, AgentList 2020-09-11 14:10:32 +01:00
aggregate.py DB API changes to get non-matching aggregates from metadata 2019-09-12 16:56:32 -05:00
bandwidth_usage.py virt: Remove 'get_all_bw_counters' API 2020-11-24 15:29:21 +00:00
base.py Remove six.binary_type/integer_types/string_types 2020-12-13 11:25:14 +00:00
block_device.py fup: Merge duplicate volume attachment checks 2021-02-04 14:05:31 +00:00
build_request.py Remove six.binary_type/integer_types/string_types 2020-12-13 11:25:14 +00:00
cell_mapping.py Remove six.moves 2020-11-07 03:25:02 +00:00
compute_node.py objects: Add migrate-on-load behavior for legacy NUMA objects 2020-05-06 15:40:06 +01:00
console_auth_token.py Remove six.moves 2020-11-07 03:25:02 +00:00
diagnostics.py Add NovaEphemeralObject class for non-persistent objects 2020-01-14 08:13:18 -08:00
ec2.py ec2: Move ec2utils functions to their callers 2019-09-27 15:27:08 +01:00
external_event.py Define Cyborg ARQ binding notification event. 2020-03-01 13:52:51 -08:00
fields.py libvirt: Add support for virtio-based input devices 2021-03-05 11:00:02 +00:00
flavor.py Merge "Remove old flavor_create db api method" 2018-03-20 18:11:06 +00:00
host_mapping.py Warn for duplicate host mappings during discover_hosts 2019-06-13 17:18:16 +00:00
hv_spec.py objects: Move 'hv_type' to 'fields.HVType' 2016-11-25 16:19:43 +00:00
image_meta.py libvirt: Add support for virtio-based input devices 2021-03-05 11:00:02 +00:00
instance.py Remove unused Instance method 2021-02-11 15:50:55 +00:00
instance_action.py Remove six.binary_type/integer_types/string_types 2020-12-13 11:25:14 +00:00
instance_fault.py Remove 'instance_fault_create_at_top' 2019-04-29 17:54:17 +01:00
instance_group.py Avoid unnecessary joins in InstanceGroup.get_hosts 2019-05-23 11:14:55 -04:00
instance_info_cache.py Remove 'instance_info_cache_update_at_top' 2019-04-29 17:55:41 +01:00
instance_mapping.py Remove six.text_type (1/2) 2020-12-13 11:25:31 +00:00
instance_numa.py objects: Fix issue in exception type 2020-10-12 10:09:10 +01:00
instance_pci_requests.py objects: Add 'socket' PCI NUMA affinity 2021-02-24 10:23:33 +00:00
keypair.py Drop migrate_keypairs_to_api_db data migration 2019-04-03 11:42:48 -04:00
migrate_data.py libvirt: Remove MIN_LIBVIRT_FILE_BACKED_DISCARD_VERSION 2020-09-22 10:29:37 +01:00
migration.py Track error migrations in resource tracker 2020-09-10 05:30:39 +00:00
migration_context.py Fix accumulated non-docs nits for cross-cell-resize series 2019-12-23 10:10:57 -05:00
monitor_metric.py Fix MonitorMetric obj_make_compatible 2016-09-12 14:10:41 +00:00
network_metadata.py Assorted cleanups from numa-aware-vswitches series 2018-07-27 09:49:12 -07:00
network_request.py nova-net: Kill it 2020-01-14 21:25:56 +00:00
numa.py libvirt: start tracking NUMACell.socket for hosts 2021-02-21 11:30:07 -05:00
pci_device.py Merge "Add an online migration for PciDevice.uuid" 2021-01-17 14:30:57 +00:00
pci_device_pool.py Remove six.binary_type/integer_types/string_types 2020-12-13 11:25:14 +00:00
quotas.py Merge "Add NovaEphemeralObject class for non-persistent objects" 2020-01-19 23:18:59 +00:00
request_spec.py Rename ensure_network_metadata to amend requested_networks 2021-02-03 18:21:34 +01:00
resource.py libvirt: Enable driver discovering PMEM namespaces 2019-09-13 08:50:35 +00:00
security_group.py nova-net: Add TODOs to remove security group-related objects 2020-01-08 13:54:12 +00:00
selection.py Add Selection.availability_zone field 2019-10-02 13:39:24 -04:00
service.py Support interface attach with QoS ports 2021-02-11 16:43:17 +01:00
tag.py Use nova.db.api directly 2018-07-10 14:56:27 +00:00
task_log.py Use nova.db.api directly 2018-07-10 14:56:27 +00:00
trusted_certs.py Use nova.db.api directly 2018-07-10 14:56:27 +00:00
vcpu_model.py Use nova.db.api directly 2018-07-10 14:56:27 +00:00
virt_cpu_topology.py cleanup NovaObjectDictCompat from virt_cpu_topology 2015-08-05 08:56:30 +05:30
virt_device_metadata.py Use nova.db.api directly 2018-07-10 14:56:27 +00:00
virtual_interface.py Populate InstanceMapping.user_id during migrations and schedules 2019-03-08 19:01:25 -05:00
volume_usage.py Transform volume.usage notification 2018-10-09 06:28:11 +00:00