aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil-cisco@xs4all.nl>2019-10-14 15:15:13 +0200
committerHans Verkuil <hverkuil-cisco@xs4all.nl>2019-10-14 15:15:13 +0200
commitba5fe02c1b597bfcf99dcce4ced31dba8b30f318 (patch)
tree037bff49142225798f72a1bf61bf09dee230cd78
parent670ffe8cd308f1d0daf1182742a944a14f566021 (diff)
cec-follower: add INACTIVE_SOURCE support.
This was missing in the follower code. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
-rw-r--r--utils/cec-follower/cec-processing.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/utils/cec-follower/cec-processing.cpp b/utils/cec-follower/cec-processing.cpp
index 2496a849..c6e2c770 100644
--- a/utils/cec-follower/cec-processing.cpp
+++ b/utils/cec-follower/cec-processing.cpp
@@ -311,6 +311,22 @@ static void processMsg(struct node *node, struct cec_msg &msg, unsigned me)
dev_info("New active source: %x.%x.%x.%x\n", cec_phys_addr_exp(phys_addr));
return;
}
+ case CEC_MSG_INACTIVE_SOURCE: {
+ __u16 phys_addr;
+
+ if (node->phys_addr)
+ break;
+
+ cec_ops_active_source(&msg, &phys_addr);
+ if (node->state.active_source_pa != phys_addr)
+ break;
+ node->state.active_source_pa = 0;
+ cec_msg_init(&msg, me, CEC_LOG_ADDR_BROADCAST);
+ cec_msg_active_source(&msg, node->phys_addr);
+ transmit(node, &msg);
+ dev_info("New active source: 0.0.0.0\n");
+ return;
+ }
case CEC_MSG_IMAGE_VIEW_ON:
case CEC_MSG_TEXT_VIEW_ON:
if (!cec_has_tv(1 << me))

Privacy Policy