tiny-pilot / tinypilot

Use your Raspberry Pi as a browser-based KVM.
https://tinypilotkvm.com
MIT License
2.89k stars 244 forks source link

Conditionally load EDID on device with TC358743 capture chip #1730

Closed jdeanwallace closed 5 months ago

jdeanwallace commented 5 months ago

Resolves https://github.com/tiny-pilot/tinypilot/issues/1726

This PR only starts the load-tc358743-edid.service when a TC358743 capture chip is installed. This change avoids reporting the service as "failed" when a TC358743 capture chip is not installed on the device.

Caveat: The load-tc358743-edid.service process is still marked as (code=exited, status=1/FAILURE), but it's active state is no longer failed (Result: exit-code). Instead, its active state is inactive (dead) (Result: exec-condition).

Example output of service being skipped:

Jan 28 18:41:02 raspberrypi systemd[1]: Starting Load EDID for TC358743 HDMI capture chip....
Jan 28 18:41:02 raspberrypi systemd[1]: load-tc358743-edid.service: Control process exited, code=exited, status=1/FAILURE
Jan 28 18:41:02 raspberrypi systemd[1]: load-tc358743-edid.service: Skipped due to 'exec-condition'.
Jan 28 18:41:02 raspberrypi systemd[1]: Condition check resulted in Load EDID for TC358743 HDMI capture chip. being skipped.

Review on CodeApprove

jdeanwallace commented 5 months ago
Automated comment from CodeApprove ➜

⏳ @db39 please review this Pull Request