fix: Restart steamos-manager after HDMI-CEC changes

It only offers Steam its HDMI-CEC settings when cecd was there at its start.
This commit is contained in:
theupriser committed 2026-09-25 09:17:05 +02:00
1 parent 3eb41eef5a
commit f7837f82b9
3 files changed
+14 -1

No files matched your search

+2
View File
@@ -13,6 +13,8 @@ one per merged pull request.
the TV turns on and off with the PC. On a Steam Machine, steamos-manager
configures it from Steam's settings.
- Works with any `/dev/cec*` (GPU or USB adapter); the menu lists them.
- Restarts steamos-manager, which only offers Steam its HDMI-CEC settings
when cecd was there at its start.
- The README no longer says Steam Machine support alone gives HDMI-CEC:
`cecd` wasn't installed, so it didn't.
+2 -1
View File
@@ -188,7 +188,8 @@ Steam Machine; the CachyOS kernel has DisplayPort CEC built in) or a USB
adapter. The menu lists the CEC devices found. Also turn on CEC on the TV
(Sony: BRAVIA Sync, Samsung: Anynet+, LG: SimpLink). On a Steam Machine
`steamos-manager` writes cecd's settings from Steam's (wake the TV, put it to
sleep), in `~/.config/cecd/config.d/`.
sleep), in `~/.config/cecd/config.d/`, and Steam shows its HDMI-CEC
settings; the wizard restarts steamos-manager so that happens right away.
It's experimental: on SteamOS itself CEC can wake the Steam Machine right
after it goes to sleep (Samsung TVs,
+10
View File
@@ -9,6 +9,14 @@
CEC_PKGS=(cecd cec-audio-control inputattach-cec-units)
restart_steamos_manager() {
# steamos-manager only offers its HDMI-CEC interface (Steam's CEC
# settings) when cecd was there at its start.
systemctl --user is-active -q steamos-manager.service 2>/dev/null &&
systemctl --user restart steamos-manager.service
return 0
}
cec_status() { pacman -Q "${CEC_PKGS[@]}" >/dev/null 2>&1; }
fetch_holo_pkg() {
@@ -60,6 +68,7 @@ cec_enable() {
systemctl --user enable steamos-manager-configure-cecd.service 2>/dev/null
if compgen -G "/dev/cec*" >/dev/null; then
systemctl --user restart cecd.service 2>/dev/null
restart_steamos_manager
ok "HDMI-CEC on ($(cd /dev && echo cec*)). Turn on CEC on your TV too (e.g. Sony: BRAVIA Sync, Samsung: Anynet+, LG: SimpLink)."
else
warn "No CEC device (/dev/cec*) found: your GPU may not support CEC. A USB CEC adapter"
@@ -77,6 +86,7 @@ cec_disable() {
state_clear cec
fi
sudo udevadm control --reload
restart_steamos_manager
ok "HDMI-CEC removed."
}