summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorSimon Rettberg2024-10-28 10:56:20 +0100
committerSimon Rettberg2024-10-28 10:56:20 +0100
commit6e9c352ce5aea90156106a6717b4efab0c794d61 (patch)
tree4a03220fcf1a1e1c0e034532347343f3f3e6c87e /core
parent[run-virt] Fix blockall with no DNS rules (diff)
downloadmltk-6e9c352ce5aea90156106a6717b4efab0c794d61.tar.gz
mltk-6e9c352ce5aea90156106a6717b4efab0c794d61.tar.xz
mltk-6e9c352ce5aea90156106a6717b4efab0c794d61.zip
[hardware-stats] Check that kernel has vfio.ko built-in
This is a requirement for GPU passthrough with QEMU.
Diffstat (limited to 'core')
-rwxr-xr-xcore/modules/hardware-stats/data/opt/openslx/system-check/hooks.d/50-hardware-warnings3
-rw-r--r--core/modules/hardware-stats/data/opt/openslx/system-check/lang/de/slx-vfio-not-builtin1
-rw-r--r--core/modules/hardware-stats/data/opt/openslx/system-check/lang/en/slx-vfio-not-builtin1
-rw-r--r--core/modules/hardware-stats/data/opt/openslx/system-check/tags/slx-vfio-not-builtin2
4 files changed, 7 insertions, 0 deletions
diff --git a/core/modules/hardware-stats/data/opt/openslx/system-check/hooks.d/50-hardware-warnings b/core/modules/hardware-stats/data/opt/openslx/system-check/hooks.d/50-hardware-warnings
index 627b94fd..cd84199c 100755
--- a/core/modules/hardware-stats/data/opt/openslx/system-check/hooks.d/50-hardware-warnings
+++ b/core/modules/hardware-stats/data/opt/openslx/system-check/hooks.d/50-hardware-warnings
@@ -12,3 +12,6 @@ fi
if lspci -nk | grep -q 'Kernel driver in use: nouveau'; then
echo 'slx-gfx-nouveau'
fi
+if ! grep -Fq 'vfio.ko' "/lib/modules/$(uname -r)/modules.builtin"; then
+ echo 'slx-vfio-not-builtin'
+fi
diff --git a/core/modules/hardware-stats/data/opt/openslx/system-check/lang/de/slx-vfio-not-builtin b/core/modules/hardware-stats/data/opt/openslx/system-check/lang/de/slx-vfio-not-builtin
new file mode 100644
index 00000000..4ab8a03d
--- /dev/null
+++ b/core/modules/hardware-stats/data/opt/openslx/system-check/lang/de/slx-vfio-not-builtin
@@ -0,0 +1 @@
+* Der Kernel wurde ohne builtin VFIO-Modul gebaut. Wegschmeißen und neukaufen!
diff --git a/core/modules/hardware-stats/data/opt/openslx/system-check/lang/en/slx-vfio-not-builtin b/core/modules/hardware-stats/data/opt/openslx/system-check/lang/en/slx-vfio-not-builtin
new file mode 100644
index 00000000..65358ce4
--- /dev/null
+++ b/core/modules/hardware-stats/data/opt/openslx/system-check/lang/en/slx-vfio-not-builtin
@@ -0,0 +1 @@
+* This is a kernel without VFIO support built-in. Please throw away this version of bwLehrpool and buy a new one.
diff --git a/core/modules/hardware-stats/data/opt/openslx/system-check/tags/slx-vfio-not-builtin b/core/modules/hardware-stats/data/opt/openslx/system-check/tags/slx-vfio-not-builtin
new file mode 100644
index 00000000..c75eebfa
--- /dev/null
+++ b/core/modules/hardware-stats/data/opt/openslx/system-check/tags/slx-vfio-not-builtin
@@ -0,0 +1,2 @@
+color=#ff0000
+contact=