diff mbox series

[1/7] UBUNTU: SAUCE: ubuntu_kernel_selftests: Install the linux-modules-extra package matching the running kernel

Message ID 20211104130146.1537314-2-francis.ginther@canonical.com
State New
Headers show
Series Install the linux-modules-extra package matching the running kernel | expand

Commit Message

Francis Ginther Nov. 4, 2021, 1:01 p.m. UTC
Install the linux-modules-extra package matching the running kernel
instead of doing a wildcard match on the kernel flavour. The wildcard
may match packages that are uninstallable.

Signed-off-by: Francis Ginther <francis.ginther@canonical.com>
---
 ubuntu_kernel_selftests/ubuntu_kernel_selftests.py | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/ubuntu_kernel_selftests/ubuntu_kernel_selftests.py b/ubuntu_kernel_selftests/ubuntu_kernel_selftests.py
index e6f98082..f01f09ef 100644
--- a/ubuntu_kernel_selftests/ubuntu_kernel_selftests.py
+++ b/ubuntu_kernel_selftests/ubuntu_kernel_selftests.py
@@ -30,9 +30,8 @@  class ubuntu_kernel_selftests(test.test):
         gcc = 'gcc' if self.arch in ['ppc64le', 'aarch64', 's390x', 'riscv64'] else 'gcc-multilib'
         pkgs.append(gcc)
 
-        if any(x in self.flavour for x in ['aws', 'azure', 'gcp', 'gke']):
-            if not (self.flavour == 'aws' and self.series == 'trusty'):
-                pkgs.append('linux-modules-extra-' + self.flavour + '*')
+        if not (self.flavour == 'aws' and self.series == 'trusty'):
+            pkgs.append('linux-modules-extra-' + platform.uname()[2])
 
         if self.kv >= 415:
             # extra packages for building bpf tests