Files
debianito-post-install/modules/gpu/amd_intel.sh
T
stornic56 fa81a9f1aa amd gcn legacy support & kernel overhaul
- Fixed Mesa 32-bit dependency conflicts by removing mesa-va-drivers from gaming setup; mesa-libgallium now includes VA-API for Mesa >= 25.3.3, resolving solver errors with backports (Mesa 26.x).
- Removed corectrl detection and installation from AMD tools in gpu/amd_intel.sh (retained in System Tools checklist only).
- Added zutty terminal emulator option alongside alacritty for Debian 12+ in terminals.sh.
- Overhauled Kernel menu: replaced "Backports Kernel" with "Kernel" submenu offering Stable, RT, Cloud, and Backports options; removed hardcoded Debian 11 restriction (backports hidden only on Bullseye); headers now installed automatically with all kernel variants; NVIDIA warnings added for Backports (DKMS required) and RT (driver compatibility note).
- Implemented AMD GCN legacy driver migration: is_amd_legacy_gcn() function detects GCN 1.0/1.1 GPUs via whitelist of 85 PCI IDs; offers user prompt to force amdgpu module with GRUB parameters (radeon.si_support=0, radeon.cik_support=0, amdgpu.si_support=1, amdgpu.cik_support=1); safe sed-based injection into GRUB_CMDLINE_LINUX_DEFAULT with backup and idempotency check.
- Standardized UI across 27 checklist locations: unified text to "Check [*] the packages you want installed/updated on your system."; removed SCROLL_HINT variable entirely from all code; changed OK button to "Apply" in _checklist() and _inputbox() only (not in _msg/_menu).
- Reordered gaming menu checklists: i386 moved to top position, steam/mangohud positioned immediately after for better dependency flow.
- Enhanced kernel installation prompts: all variants (Stable, RT, Cloud, Backports) now display candidate version numbers in parentheses using apt-cache policy and madison queries.
- update readme
2026-07-23 00:18:24 -05:00

97 lines
3.1 KiB
Bash

#!/usr/bin/env bash
# AMD and Intel GPU firmware + tools
install_amd_firmware() {
local fw_info
fw_info=$(pkg_versions firmware-amd-graphics)
if _confirm "AMD Firmware" "Install AMD GPU firmware?\n\n${fw_info}"; then
_run_cmd "AMD" "sudo apt install -y firmware-amd-graphics" "Installing AMD GPU firmware..."
fi
}
offer_amd_tools() {
local amd_tools=("radeontop")
local pkgs
if [ "$DEBIAN_VERSION" = "11" ]; then
pkgs=$(pkg_versions "${amd_tools[@]}" vainfo)
else
pkgs=$(pkg_versions "${amd_tools[@]}" nvtop vainfo)
fi
if ! _confirm "AMD Tools" "Install AMD monitoring tools?\n\n${pkgs}"; then
echo "Skipping AMD tools."
return
fi
if [ "$DEBIAN_VERSION" = "11" ]; then
_run_cmd "AMD Tools" "sudo apt install -y ${amd_tools[*]} vainfo" "Installing AMD tools..."
else
_run_cmd "AMD Tools" "sudo apt install -y ${amd_tools[*]} nvtop vainfo" "Installing AMD tools..."
fi
vainfo
_pause "vainfo output shown above."
echo -e "${GREEN}AMD tools installed.${NC}"
}
install_intel_firmware() {
local gen
gen=$(get_intel_generation)
local va_driver
if [ "$gen" = "gen7-" ]; then
va_driver="i965-va-driver-shaders"
else
va_driver="intel-media-va-driver-non-free"
fi
local fw_info
fw_info=$(pkg_versions firmware-intel-graphics "$va_driver")
if _confirm "Intel Firmware" "Install Intel GPU firmware?\n\n${fw_info}"; then
_run_cmd "Intel" "sudo apt install -y firmware-intel-graphics $va_driver" "Installing Intel GPU firmware..."
fi
}
offer_intel_tools() {
local driver_info=""
local has_xe=false
local has_i915=false
local pkg_list=()
local pkg_info=""
[ -d "/sys/bus/pci/drivers/xe" ] && has_xe=true
[ -d "/sys/bus/pci/drivers/i915" ] && has_i915=true
if [ "$DEBIAN_VERSION" = "11" ]; then
if $has_xe; then
echo "Intel Xe GPU detected. No monitoring tools available on Bullseye."
return
elif $has_i915; then
driver_info="Classic Intel GPU detected (i915 driver)."
pkg_list=("intel-gpu-tools")
else
echo "Intel GPU driver not identified. No monitoring tools available on Bullseye."
return
fi
elif $has_xe; then
driver_info="Modern Intel GPU detected (Xe driver).\nintel-gpu-tools is NOT compatible with Xe.\nOnly nvtop will be offered."
pkg_list=("nvtop")
elif $has_i915; then
driver_info="Classic Intel GPU detected (i915 driver).\nintel-gpu-tools is compatible and will be offered."
pkg_list=("intel-gpu-tools" "nvtop")
else
driver_info="Intel GPU driver not identified.\nOffering nvtop as a safe default."
pkg_list=("nvtop")
fi
pkg_info=$(pkg_versions "${pkg_list[@]}" vainfo)
if _confirm "Intel Tools" "Intel GPU monitoring tools\n\n${driver_info}\n\nPackages:\n${pkg_info}"; then
_run_cmd "Intel Tools" "sudo apt install -y ${pkg_list[*]} vainfo" "Installing Intel monitoring tools..."
vainfo
_pause "vainfo output shown above."
else
echo "Skipping Intel monitoring tools."
fi
}