v4plus: config.txt for passthrough

This commit is contained in:
Maxim Devaev
2024-04-06 23:51:41 +03:00
parent 8b7196671b
commit a276aa76d6
2 changed files with 13 additions and 0 deletions

View File

@@ -83,6 +83,15 @@ post_upgrade() {
keyboxd@etc-pacman.d-gnupg.socket
fi
if [[ "$(varcmp "$2" 3.331)" -lt 0 ]]; then
grep -q "^dtoverlay=vc4-kms-v3d" /boot/config.txt || cat << EOF >> /boot/config.txt
# Passthrough
dtoverlay=vc4-kms-v3d
disable_overscan=1
EOF
fi
# Some update deletes /etc/motd, WTF
# shellcheck disable=SC2015,SC2166
[ ! -f /etc/motd -a -f /etc/motd.pacsave ] && mv /etc/motd.pacsave /etc/motd || true