From 273f4b62db0cb502bedbcd9c438d2ff2bc14ce39 Mon Sep 17 00:00:00 2001 From: Kyle Gospodnetich Date: Mon, 8 Jul 2024 13:24:38 -0700 Subject: [PATCH] chore: Preliminary support for the ROG Ally X chore: Drop simpledeckytdp workaround --- .../shared/usr/etc/default/steamos-nested-desktop | 4 ++-- .../desktop/shared/usr/etc/default/waydroid-launcher | 4 ++-- .../desktop/shared/usr/libexec/bazzite-hardware-setup | 10 +--------- .../usr/libexec/hwsupport/hhd-supported-hardware | 2 +- .../hwsupport/simpledeckytdp-supported-hardware | 8 -------- .../desktop/shared/usr/libexec/hwsupport/sysid | 3 +++ 6 files changed, 9 insertions(+), 22 deletions(-) delete mode 100755 system_files/desktop/shared/usr/libexec/hwsupport/simpledeckytdp-supported-hardware diff --git a/system_files/desktop/shared/usr/etc/default/steamos-nested-desktop b/system_files/desktop/shared/usr/etc/default/steamos-nested-desktop index d3536840..229c5b74 100644 --- a/system_files/desktop/shared/usr/etc/default/steamos-nested-desktop +++ b/system_files/desktop/shared/usr/etc/default/steamos-nested-desktop @@ -4,11 +4,11 @@ STEAMOS_UNKNOWN_NESTED_DESKTOP_WIDTH=1920 STEAMOS_UNKNOWN_NESTED_DESKTOP_HEIGHT=1080 # Handle nested desktop resolution for known devices. -case "$(cat /sys/devices/virtual/dmi/id/product_name)" in +case "$(/usr/libexec/hwsupport/sysid)" in "Jupiter" | "Galileo" | "AYANEO GEEK" | "G1619-05") STEAMOS_NESTED_DESKTOP_WIDTH=1280 STEAMOS_NESTED_DESKTOP_HEIGHT=800 ;; - "ROG Ally RC71L_RC71L" | "ROG Ally RC71L_Action" | "ROG Ally RC71L" | "G1618-04" | "G1617-01" | "Loki Max") + "ROG Ally RC71L" | "ROG Ally X RC72LA" | "G1618-04" | "G1617-01" | "Loki Max") STEAMOS_NESTED_DESKTOP_WIDTH=1920 STEAMOS_NESTED_DESKTOP_HEIGHT=1080 ;; "AYANEO 2" | "AYANEO 2S" | "AOKZOE A1 AR07" | "G1619-04" | "AIR Plus") diff --git a/system_files/desktop/shared/usr/etc/default/waydroid-launcher b/system_files/desktop/shared/usr/etc/default/waydroid-launcher index 3e7f393a..bb4a7b02 100644 --- a/system_files/desktop/shared/usr/etc/default/waydroid-launcher +++ b/system_files/desktop/shared/usr/etc/default/waydroid-launcher @@ -5,12 +5,12 @@ WAYDROID_UNKNOWN_HEIGHT=1080 WAYDROID_GRALLOC=minigbm_gbm_mesa # Handle nested desktop resolution for known devices. -case "$(cat /sys/devices/virtual/dmi/id/product_name)" in +case "$(/usr/libexec/hwsupport/sysid)" in "Jupiter" | "Galileo" | "AYANEO GEEK" | "G1619-05") WAYDROID_WIDTH=1280 WAYDROID_HEIGHT=800 WAYDROID_DENSITY=215 ;; - "ROG Ally RC71L_RC71L" | "ROG Ally RC71L_Action" | "ROG Ally RC71L" | "G1618-04" | "G1617-01" | "Loki Max" | "ONEXPLAYER F1" | "ONEXPLAYER F1 EVA-01" | "AIR Plus" | "AIR 1S" | "AIR 1S Limited") + "ROG Ally RC71L" | "ROG Ally X RC72LA" | "G1618-04" | "G1617-01" | "Loki Max" | "ONEXPLAYER F1" | "ONEXPLAYER F1 EVA-01" | "AIR Plus" | "AIR 1S" | "AIR 1S Limited") WAYDROID_WIDTH=1920 WAYDROID_HEIGHT=1080 ;; "AYANEO 2" | "AYANEO 2S" | "AOKZOE A1 AR07" | "AOKZOE A1 Pro" | "G1619-04") diff --git a/system_files/desktop/shared/usr/libexec/bazzite-hardware-setup b/system_files/desktop/shared/usr/libexec/bazzite-hardware-setup index c76e6b48..c0a3a1fd 100755 --- a/system_files/desktop/shared/usr/libexec/bazzite-hardware-setup +++ b/system_files/desktop/shared/usr/libexec/bazzite-hardware-setup @@ -117,13 +117,6 @@ if [[ ":ONEXPLAYER F1:" =~ ":$SYS_ID:" ]]; then fi fi -if /usr/libexec/hwsupport/simpledeckytdp-supported-hardware; then - if [[ ! $KARGS =~ "iomem" ]]; then - echo "Adding needed kargs for ryzenadj" - NEEDED_KARGS+=("--append-if-missing=iomem=relaxed") - fi -fi - if [[ ! $KARGS =~ "disable_ertm" ]]; then echo "Adding needed kargs for bluetooth" NEEDED_KARGS+=("--append-if-missing=bluetooth.disable_ertm=1") @@ -217,8 +210,7 @@ if [[ ":Framework:" =~ ":$VEN_ID:" ]]; then fi # ALLY POWER SAVE FIX -ALLY_LIST="ROG Ally RC71L_RC71L:ROG Ally RC71L:ROG Ally RC71L_Action" -if [[ ":$ALLY_LIST:" =~ ":$SYS_ID:" ]]; then +if [[ ":ROG Ally RC71L:" =~ ":$SYS_ID:" ]]; then echo 0 | sudo tee /sys/devices/platform/asus-nb-wmi/mcu_powersave fi diff --git a/system_files/desktop/shared/usr/libexec/hwsupport/hhd-supported-hardware b/system_files/desktop/shared/usr/libexec/hwsupport/hhd-supported-hardware index 9a0c3baf..7c38bfd4 100755 --- a/system_files/desktop/shared/usr/libexec/hwsupport/hhd-supported-hardware +++ b/system_files/desktop/shared/usr/libexec/hwsupport/hhd-supported-hardware @@ -1,7 +1,7 @@ #!/usr/bin/bash # Returns true for hardware that is supported by HHD SYS_ID="$(/usr/libexec/hwsupport/sysid)" -if [[ ":ROG Ally RC71L:83E1:G1618-04:G1617-01:G1619-05:AIR Plus:AIR 1S:AIR 1S Limited:AIR:AYANEO GEEK:AYANEO 2:AYANEO 2S:AOKZOE A1 AR07:AOKZOE A1 Pro:G1619-04:Win600:Loki Max:Loki Zero:Loki MiniPro:" =~ ":$SYS_ID:" ]]; then +if [[ ":ROG Ally RC71L:ROG Ally X RC72LA:83E1:G1618-04:G1617-01:G1619-05:AIR Plus:AIR 1S:AIR 1S Limited:AIR:AYANEO GEEK:AYANEO 2:AYANEO 2S:AOKZOE A1 AR07:AOKZOE A1 Pro:G1619-04:Win600:Loki Max:Loki Zero:Loki MiniPro:" =~ ":$SYS_ID:" ]]; then exit 0 fi diff --git a/system_files/desktop/shared/usr/libexec/hwsupport/simpledeckytdp-supported-hardware b/system_files/desktop/shared/usr/libexec/hwsupport/simpledeckytdp-supported-hardware deleted file mode 100755 index 2ad84b2b..00000000 --- a/system_files/desktop/shared/usr/libexec/hwsupport/simpledeckytdp-supported-hardware +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/bash -# Returns true for hardware that is supported by SimpleDeckyTDP -SYS_ID="$(/usr/libexec/hwsupport/sysid)" -if [[ ":ROG Ally RC71L:83E1:G1618-04:G1619-04:G1617-01:G1619-05:AIR Plus:AIR 1S:AIR 1S Limited:AIR:SLIDE:V3:AOKZOE A1 AR07:AOKZOE A1 Pro:ONEXPLAYER 2 ARP23:ONEXPLAYER 2 PRO ARP23H:ONEXPLAYER 2 PRO ARP23P:ONEXPLAYER 2 PRO ARP23P EVA-01:" =~ ":$SYS_ID:" ]]; then - exit 0 -fi - -exit 1 diff --git a/system_files/desktop/shared/usr/libexec/hwsupport/sysid b/system_files/desktop/shared/usr/libexec/hwsupport/sysid index 72bb3257..ca7065b6 100755 --- a/system_files/desktop/shared/usr/libexec/hwsupport/sysid +++ b/system_files/desktop/shared/usr/libexec/hwsupport/sysid @@ -6,6 +6,9 @@ SYS_ID="$(cat /sys/devices/virtual/dmi/id/product_name)" if [[ "$SYS_ID" =~ ROG[[:space:]]Ally[[:space:]]RC71L.+ ]]; then # Trunctate ROG Ally SYS_ID echo "ROG Ally RC71L" +elif [[ "$SYS_ID" =~ ROG[[:space:]]Ally[[:space:]]X[[:space:]]RC72LA.+ ]]; then + # Trunctate ROG Ally X SYS_ID + echo "ROG Ally X RC72LA" else # Probably a sensible SYS_ID so we echo it echo "$SYS_ID"