From f3906c6c2cc8dafb3da39d9e5890c531e25b29bd Mon Sep 17 00:00:00 2001 From: technowhizz <7688823+technowhizz@users.noreply.github.com> Date: Fri, 1 Mar 2024 11:23:07 +0000 Subject: [PATCH] Update iommu role for rl9 --- roles/iommu/tasks/main.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/roles/iommu/tasks/main.yml b/roles/iommu/tasks/main.yml index 4ca9872..a700972 100644 --- a/roles/iommu/tasks/main.yml +++ b/roles/iommu/tasks/main.yml @@ -3,11 +3,11 @@ ansible.builtin.include_role: name: stackhpc.linux.grubcmdline vars: - kernel_cmdline: # noqa: var-naming[no-role-prefix] - - intel_iommu=on + kernel_cmdline: "{{ ['intel_iommu=on'] + (['vfio-pci.ids=' + vfio_pci_ids] if vfio_pci_ids is defined else []) }}" # noqa: var-naming[no-role-prefix] kernel_cmdline_remove: # noqa: var-naming[no-role-prefix] - ^intel_iommu= - when: "'Intel' in ansible_facts.processor.0" + - ^vfio-pci\.ids= + when: ansible_facts.processor | select('search', 'Intel') | list | length > 0 - name: Set iommu=pt ansible.builtin.include_role: