Skip to content

Commit 0b35eda

Browse files
committed
fix(deck): Update jupiter-hw-support package
1 parent 460f111 commit 0b35eda

File tree

3 files changed

+38
-27
lines changed

3 files changed

+38
-27
lines changed

spec_files/jupiter-hw-support/bazzite-btrfs.patch

+10-11
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
11
diff --git a/etc/systemd/system/steamos-automount@.service b/etc/systemd/system/steamos-automount@.service
2-
index dd700da..152e231 100644
2+
index 96e8818..33038bc 100644
33
--- a/etc/systemd/system/steamos-automount@.service
44
+++ b/etc/systemd/system/steamos-automount@.service
5-
@@ -14,6 +14,7 @@
5+
@@ -14,5 +14,6 @@ Description=Mount removable drive %i
66
[Service]
77
Type=oneshot
88
RemainAfterExit=true
99
+EnvironmentFile=/etc/default/steamos-btrfs
10-
ExecStart=-/usr/libexec/steamos-automount add %i
11-
ExecStop=-/usr/libexec/steamos-automount remove %i
12-
ExecReload=-/usr/libexec/steamos-automount retrigger %i
13-
10+
ExecStart=/usr/lib/hwsupport/steamos-automount.sh add %i
11+
ExecStop=/usr/lib/hwsupport/steamos-automount.sh remove %i
1412
diff --git a/usr/lib/hwsupport/format-device.sh b/usr/lib/hwsupport/format-device.sh
15-
index b136413..d3cbb16 100755
13+
index 566eea2..d6803ff 100755
1614
--- a/usr/lib/hwsupport/format-device.sh
1715
+++ b/usr/lib/hwsupport/format-device.sh
1816
@@ -2,6 +2,8 @@
@@ -24,26 +22,27 @@ index b136413..d3cbb16 100755
2422
# If the script is not run from a tty then send a copy of stdout and
2523
# stderr to the journal. In this case stderr is also redirected to stdout.
2624
if ! tty -s; then
27-
25+
diff --git a/usr/lib/hwsupport/steamos-automount.sh b/usr/lib/hwsupport/steamos-automount.sh
26+
index 6dd3a2f..ca1c5ca 100755
2827
--- a/usr/lib/hwsupport/steamos-automount.sh
2928
+++ b/usr/lib/hwsupport/steamos-automount.sh
30-
@@ -77,6 +77,7 @@
29+
@@ -66,6 +66,7 @@ do_mount()
3130
dev_json=$(lsblk -o PATH,LABEL,FSTYPE --json -- "$DEVICE" | jq '.blockdevices[0]')
3231
ID_FS_LABEL=$(jq -r '.label | select(type == "string")' <<< "$dev_json")
3332
ID_FS_TYPE=$(jq -r '.fstype | select(type == "string")' <<< "$dev_json")
3433
+ FSTYPE_PREFIX=""
3534

3635
#### SteamOS Btrfs Begin ####
3736
if [[ -f /etc/default/steamos-btrfs ]]; then
38-
@@ -120,6 +121,7 @@
37+
@@ -109,6 +110,7 @@ do_mount()
3938
UDISKS2_ALLOW='uid=$UID,gid=$GID,umask,dmask,fmask,locale,norecover,ignore_case,windows_names,compression,nocompression,big_writes,nls,nohidden,sys_immutable,sparse,showmeta,prealloc'
4039
OPTS="${STEAMOS_BTRFS_SDCARD_NTFS_MOUNT_OPTS:-rw,noatime,lazytime,uid=1000,gid=1000,big_writes,umask=0022,ignore_case,windows_names}"
4140
FSTYPE="lowntfs-3g"
4241
+ FSTYPE_PREFIX="ntfs:"
4342
if [[ ! -f /etc/filesystems ]] || ! grep -q '\b'"${FSTYPE}"'\b' /etc/filesystems; then
4443
echo "${FSTYPE}" >> /etc/filesystems
4544
fi
46-
@@ -132,7 +134,7 @@
45+
@@ -121,7 +123,7 @@ do_mount()
4746
if [[ -f "${udisks2_mount_options_conf}" && ! -f "${udisks2_mount_options_conf}.orig" ]]; then
4847
mv -f "${udisks2_mount_options_conf}"{,.orig}
4948
fi

spec_files/jupiter-hw-support/jupiter-hw-support-btrfs.spec

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
%define packagename jupiter-hw-support
2-
%define packagever jupiter-20231115.1
2+
%define packagever jupiter-3.5-20231115.1
33
Name: %{packagename}-btrfs
44
Version: {{{ git_dir_version }}}
55
Release: 1%{?dist}
66
Summary: Steam Deck Hardware Support Package
77
License: GPLv3
88
URL: https://github.com/ublue-os/bazzite
99

10-
Source: https://gitlab.com/evlaV/%{packagename}/-/archive/jupiter-20230927.2/%{packagename}-%{packagever}.tar.gz
10+
Source: https://gitlab.com/evlaV/%{packagename}/-/archive/%{packagever}/%{packagename}-%{packagever}.tar.gz
1111
Patch0: fedora.patch
1212
Patch1: selinux.patch
13-
Patch2: https://gitlab.com/popsulfr/steamos-btrfs/-/raw/main/files/usr/lib/hwsupport/steamos-automount.sh.patch.old.20231104103824.20231031.1000
14-
Patch3: https://gitlab.com/popsulfr/steamos-btrfs/-/raw/main/files/usr/lib/hwsupport/format-device.sh.patch.old.20230922091429.20230915.100
13+
Patch2: https://gitlab.com/popsulfr/steamos-btrfs/-/raw/v1.2.6.20231104/files/usr/lib/hwsupport/steamos-automount.sh.patch.old.20231104103824.20231031.1000
14+
Patch3: https://gitlab.com/popsulfr/steamos-btrfs/-/raw/v1.2.6.20231104/files/usr/lib/hwsupport/format-device.sh.patch.old.20230922091429.20230915.100
1515
Patch4: user.patch
1616
Patch5: bazzite-btrfs.patch
1717
Patch6: systemd-run.patch
@@ -41,7 +41,7 @@ SteamOS 3.0 Steam Deck Hardware Support Package
4141
%define debug_package %{nil}
4242

4343
%prep
44-
%autosetup -p1 -n jupiter-hw-support-jupiter-20230927.2-faaccd721214cbb705bdcba8d3eddfdec1ef4e3b
44+
%autosetup -p1 -n %{packagename}-%{packagever}
4545

4646
%build
4747

spec_files/jupiter-hw-support/priv-write.patch

+23-11
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
diff --git a/usr/bin/steamos-polkit-helpers/steamos-priv-write b/usr/bin/steamos-polkit-helpers/steamos-priv-write
2-
index 907133b..6ba1dd8 100755
2+
index 296996e..ae0ae3e 100755
33
--- a/usr/bin/steamos-polkit-helpers/steamos-priv-write
44
+++ b/usr/bin/steamos-polkit-helpers/steamos-priv-write
55
@@ -2,6 +2,9 @@
@@ -12,19 +12,31 @@ index 907133b..6ba1dd8 100755
1212
if [[ $EUID -ne 0 ]];
1313
then
1414
exec pkexec --disable-internal-agent "$0" "$@"
15-
@@ -12,16 +15,19 @@
15+
@@ -12,21 +15,25 @@ WRITE_VALUE="$2"
1616

1717
function CommitWrite()
1818
{
19+
- if [ ! -z "$WRITE_VALUE" ]
20+
- then
21+
- echo "commit: $WRITE_VALUE -> $WRITE_PATH" | systemd-cat -t p-steamos-priv-write -p warning
22+
- echo "$WRITE_VALUE" > "$WRITE_PATH"
1923
+ if [[ ":Jupiter:" =~ ":$SYS_ID:" || ":Galileo:" =~ ":$SYS_ID:" || "$ENABLE_HARDWARE_CONTROL_ON_NON_DECK_HARDWARE" = 1 ]]; then
20-
echo "commit: $WRITE_VALUE -> $WRITE_PATH" | systemd-cat -t p-steamos-priv-write -p warning
21-
- echo "$WRITE_VALUE" > "$WRITE_PATH"
22-
chmod a+w "$WRITE_PATH"
23-
+ echo "$WRITE_VALUE" > "$WRITE_PATH"
24+
+ if [ ! -z "$WRITE_VALUE" ]
25+
+ then
26+
+ echo "commit: $WRITE_VALUE -> $WRITE_PATH" | systemd-cat -t p-steamos-priv-write -p warning
27+
+ chmod a+w "$WRITE_PATH"
28+
+ echo "$WRITE_VALUE" > "$WRITE_PATH"
29+
+ fi
30+
+
31+
+ echo "chmod a+w: $WRITE_PATH" | systemd-cat -t p-steamos-priv-write -p warning
2432
+ else
25-
+ echo "commit: Skipped - see /etc/default/steam-hardware-control" | systemd-cat -t p-steamos-priv-write -p warning
26-
+ fi
27-
exit 0
33+
+ echo "commit: Skipped - see /etc/default/steam-hardware-control" | systemd-cat -t p-steamos-priv-write -p warning
34+
fi
35+
-
36+
- chmod a+w "$WRITE_PATH"
37+
- echo "chmod a+w: $WRITE_PATH" | systemd-cat -t p-steamos-priv-write -p warning
38+
+
39+
exit 0
2840
}
2941

3042
function DeclineWrite()
@@ -34,8 +46,8 @@ index 907133b..6ba1dd8 100755
3446
exit 1
3547
}
3648

37-
@@ -32,15 +38,90 @@
38-
49+
@@ -40,15 +47,90 @@ if [[ "$WRITE_PATH" == /dev/drm_dp_aux0 ]]; then
50+
fi
3951

4052
if [[ "$WRITE_PATH" == /sys/class/drm/card*/device/power_dpm_force_performance_level ]]; then
4153
- CommitWrite

0 commit comments

Comments
 (0)