diff --git a/modules/firmware.sh b/modules/firmware.sh index df707bd..7d20a26 100644 --- a/modules/firmware.sh +++ b/modules/firmware.sh @@ -277,17 +277,17 @@ After the firmware is downloaded, reboot the system." 14 75 else local bcm_ver header_ver bcm_ver=$(apt-cache policy broadcom-sta-dkms 2>/dev/null | awk 'NR==3 {print $2; exit}') - header_ver=$(apt-cache policy linux-headers-$(uname -r) 2>/dev/null | awk 'NR==3 {print $2; exit}') + header_ver=$(apt-cache policy linux-headers-amd64 2>/dev/null | awk 'NR==3 {print $2; exit}') - if ! apt-cache policy "linux-headers-$(uname -r)" 2>/dev/null | grep -q "Candidate: [^ (none)]"; then + if ! apt-cache policy linux-headers-amd64 2>/dev/null | grep -q "Candidate: [^ (none)]"; then _msg "Broadcom Error" \ - "linux-headers-$(uname -r) not available.\n\nCannot compile broadcom-sta-dkms without kernel headers." 10 60 + "linux-headers-amd64 not available.\n\nCannot compile broadcom-sta-dkms without kernel headers." 10 60 _pause continue fi - if _confirm "Broadcom WiFi" "Install Broadcom driver?\n\nRequired for this chipset. Compiles a kernel module.\n\n broadcom-sta-dkms ${bcm_ver:-unknown}\n linux-headers-$(uname -r) ${header_ver:-unknown}\n\nProceed?"; then - _run_cmd "Broadcom" "sudo DEBIAN_FRONTEND=noninteractive apt install -y linux-headers-$(uname -r) broadcom-sta-dkms" \ + if _confirm "Broadcom WiFi" "Install Broadcom driver?\n\nRequired for this chipset. Compiles a kernel module.\n\n broadcom-sta-dkms ${bcm_ver:-unknown}\n linux-headers-amd64 ${header_ver:-unknown}\n\nProceed?"; then + _run_cmd "Broadcom" "sudo DEBIAN_FRONTEND=noninteractive apt install -y linux-headers-amd64 broadcom-sta-dkms" \ "Installing Broadcom driver..." local has_broadcom_bt=false diff --git a/modules/gpu.sh b/modules/gpu.sh index 7569d20..2fd7fc1 100644 --- a/modules/gpu.sh +++ b/modules/gpu.sh @@ -181,11 +181,7 @@ _install_nvidia_stack() { elif [ "$DEBIAN_VERSION" = "12" ]; then if [ "$(is_nvidia_kepler)" = "true" ]; then - if type _install_nvidia_bookworm_kepler &>/dev/null; then - _install_nvidia_bookworm_kepler - else - _install_nvidia_standard - fi + _install_nvidia_bookworm_kepler elif [ "$(is_nvidia_fermi)" = "true" ]; then _msg "NVIDIA Fermi — Bookworm" \ "Fermi GPUs (GF1xx) are not supported\nin Debian 12 (Bookworm).\nThe nvidia-legacy-390xx driver is\nnot available in this version.\n\nNo NVIDIA driver will be installed." diff --git a/modules/gpu/_helpers.sh b/modules/gpu/_helpers.sh index 9104dd7..ddb5e25 100644 --- a/modules/gpu/_helpers.sh +++ b/modules/gpu/_helpers.sh @@ -23,7 +23,7 @@ declare -A NVIDIA_FAMILY_MAP=( ) detect_nvidia_arch() { - local pci_id="$1" + local pci_id="${1^^}" local prefix="${pci_id:0:2}" echo "${NVIDIA_FAMILY_MAP[$prefix]:-unknown}" } diff --git a/modules/gpu/nvidia.sh b/modules/gpu/nvidia.sh index ceb6757..75ecce5 100644 --- a/modules/gpu/nvidia.sh +++ b/modules/gpu/nvidia.sh @@ -199,7 +199,7 @@ _install_nvidia_bookworm_bpo() { # sin pasar por nvidia-detect (evita falsa recomendación rama 535) # ------------------------------------------------------------------- _install_nvidia_bookworm_kepler() { - local nv_pkg="nvidia-legacy-470xx-driver" + local nv_pkg="nvidia-tesla-470-driver" local nv_ver nv_ver=$(apt-cache policy "$nv_pkg" 2>/dev/null | awk 'NR==3 {print $2; exit}') || true