From: Jiunn Chang <c0d1n61at3@gmail.com>
To: linux-media@vger.kernel.org,
linux-kernel-mentees@lists.linuxfoundation.org
Cc: hverkuil@xs4all.nl
Subject: [PATCH] cec-compliance: system information give features
Date: Fri, 6 Sep 2019 11:44:43 -0500 [thread overview]
Message-ID: <20190906164443.1748-1-c0d1n61at3@gmail.com> (raw)
For devices on a HDMI ARC link, sinks can only support transmitter
devices and sources can only support receiver devices.
Add two checks:
- Playback devices can only have has_arc_rx
- TVs can only have has_arc_tx
Signed-off-by: Jiunn Chang <c0d1n61at3@gmail.com>
---
utils/cec-compliance/cec-test.cpp | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/utils/cec-compliance/cec-test.cpp b/utils/cec-compliance/cec-test.cpp
index bbd13989..839c0fb9 100644
--- a/utils/cec-compliance/cec-test.cpp
+++ b/utils/cec-compliance/cec-test.cpp
@@ -172,6 +172,10 @@ int system_info_give_features(struct node *node, unsigned me, unsigned la, bool
return fail("Only Playback and Recording devices shall set the Supports Deck Control bit\n");
if (!cec_has_tv(1 << la) && node->remote[la].has_rec_tv)
return fail("Only TVs shall set the Record TV Screen bit\n");
+ if (!cec_has_playback(1 << la) && node->remote[la].has_arc_rx)
+ return fail("Only Playback devices shall set the Source Supports ARC Rx bit\n");
+ if (!cec_has_tv(1 << la) && node->remote[la].has_arc_tx)
+ return fail("Only TVs shall set the Sink Supports ARC Tx bit\n");
fail_on_test(node->remote[la].rc_profile != *rc_profile);
fail_on_test(node->remote[la].dev_features != *dev_features);
--
2.23.0
next reply other threads:[~2019-09-06 16:44 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-09-06 16:44 Jiunn Chang [this message]
2019-09-09 8:05 ` [PATCH] cec-compliance: system information give features Hans Verkuil
2019-09-09 15:07 Jiunn Chang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190906164443.1748-1-c0d1n61at3@gmail.com \
--to=c0d1n61at3@gmail.com \
--cc=hverkuil@xs4all.nl \
--cc=linux-kernel-mentees@lists.linuxfoundation.org \
--cc=linux-media@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).