Config has changed for pci passthrough.

updating the config for pci devices since the old config is deprecated.
https://docs.openstack.org/nova/latest/configuration/config.html#pci.device_spec

Change-Id: Id2da29464359b4845c7d05e3bec53759341f4bad
(cherry picked from commit 9d2924fa80)
This commit is contained in:
Marc Gariepy 2023-09-05 13:52:38 -04:00 committed by Marc Gariépy
parent e98e736e05
commit 9bb3f6bb7d
3 changed files with 11 additions and 6 deletions

View File

@ -553,10 +553,11 @@ nova_enabled_mdev_types: "{{ nova_enabled_vgpu_types | default({}) }}"
# PCI devices passthrough to nova
# For SR-IOV please use:
# nova_pci_passthrough_whitelist: '{ "physical_network": "<ml2 network name>", "devname": "<physical nic>" }'
# nova_device_spec: '{ "physical_network": "<ml2 network name>", "devname": "<physical nic>" }'
# Example:
# nova_pci_passthrough_whitelist: '{ "physical_network": "physnet1", "devname": "p1p1" }'
nova_pci_passthrough_whitelist: {}
# nova_device_spec: '{ "physical_network": "physnet1", "devname": "p1p1" }'
nova_device_spec: "{{ nova_pci_passthrough_whitelist | default({}) }}"
# PCI alias,
# Example:
# nova_pci_alias:

View File

@ -0,0 +1,4 @@
---
deprecations:
- |
`nova_pci_passthrough_whitelist` is now deprecated in favor of `nova_device_spec`.

View File

@ -348,11 +348,11 @@ device_addresses = {{ (record.address is string) | ternary(record.address, recor
{% endfor %}
{% endif %}
{% if nova_pci_passthrough_whitelist or nova_pci_alias %}
{% if nova_device_spec or nova_pci_alias %}
[pci]
{% if nova_pci_passthrough_whitelist %}
{% if nova_device_spec %}
# White list of PCI devices available to VMs.
passthrough_whitelist = {{ nova_pci_passthrough_whitelist }}
device_spec = {{ nova_device_spec }}
{% endif %}
{% if nova_pci_alias %}
# PCI Alias