libcec: fix HDMI input grab-back on routing change to external device#52
Open
samtheruby wants to merge 1 commit into
Open
libcec: fix HDMI input grab-back on routing change to external device#52samtheruby wants to merge 1 commit into
samtheruby wants to merge 1 commit into
Conversation
Patches SetActiveRoute() and HandleSetStreamPath() to call MarkAsInactiveSource() on all libCEC-controlled devices when CEC routing changes to a known external device (one not handled by libCEC). Without this fix, m_bActiveSource stays true after the user switches input away via the TV remote. When the TV broadcasts REQUEST_ACTIVE_SOURCE ~30 seconds later, libCEC responds and steals the HDMI input back — a long-standing user-visible regression where the box yanks focus from whatever the user just switched to. The patch file landed in two follow-up fixes for the patch format itself (formerly separate commits, now squashed): - Fix a malformed blank context line between SetActiveRoute and SetStreamPath where the leading space had been stripped, causing `patch` to treat it as end-of-hunk and report the file as malformed. - Fix wrong old/new line counts in both hunks and trim the second hunk's leading context from 13 lines (needing fuzz 12) to 3 so the patch applies cleanly with default fuzz. End state is a single packages/mediacenter/libcec/patches/ libcec-001-fix-active-source-on-routing-change.patch that applies cleanly against the current libcec source tree.
8 tasks
Contributor
Author
|
All possible tests passed, As well as 0 bugs when in regular use, I think this is ready for prime time! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
packages/mediacenter/libcec/patches/libcec-001-fix-active-source-on-routing-change.patch. It patchesSetActiveRoute()andHandleSetStreamPath()in libcec to callMarkAsInactiveSource()on all libCEC-controlled devices when CEC routing changes to a known external device (one not handled by libCEC).Bug fixed
Without this fix,
m_bActiveSourcestaystrueafter the user switches HDMI input away via the TV remote. ~30 seconds later the TV broadcastsREQUEST_ACTIVE_SOURCEand libCEC responds, causing the box to steal the HDMI input back — a user-visible long-standing regression where you switch to a game console / streaming stick / etc. and the box yanks focus back unprompted.Test plan
make imagebuilds libcec withoutpatchwarnings or failures.