Merge pull request #4314 from jmargeta/fix-legacy-mobile-nvidia-cards

Fix driver for older NVIDIA MXxxx mobile GPUs
This commit is contained in:
Ryan Hughes
2026-01-27 09:41:05 -05:00
committed by GitHub
2 changed files with 21 additions and 2 deletions

19
migrations/1768906440.sh Normal file
View File

@@ -0,0 +1,19 @@
echo "Migrate legacy mobile NVIDIA GPUs to nvidia-580xx driver (if needed)"
# Only migrate MX1xx, 2xx or 3xx (Pascal/Maxwell)
NVIDIA="$(lspci | grep -i 'nvidia')"
if echo "$NVIDIA" | grep -qE "MX1|MX2|MX3"; then
if ! pacman -Qq | grep -qE '^linux(-[a-z0-9]+)?-headers$'; then
echo "Error: no linux headers package installed (required for DKMS drivers). Please install the appropriate headers and re-run this migration."
exit 1
fi
# Piping yes to override existing packages
yes | sudo pacman -S nvidia-580xx-dkms nvidia-580xx-utils lib32-nvidia-580xx-utils
# Verify packages were installed
if ! pacman -Qq nvidia-580xx-dkms nvidia-580xx-utils lib32-nvidia-580xx-utils &>/dev/null; then
echo "Error: NVIDIA 580xx driver packages failed to install"
exit 1
fi
fi