aboutsummaryrefslogtreecommitdiffstats
path: root/utils/cec-compliance/cec-test-adapter.cpp
diff options
context:
space:
mode:
authorHans Verkuil <hans.verkuil@cisco.com>2016-11-04 10:43:34 +0100
committerHans Verkuil <hans.verkuil@cisco.com>2016-11-16 19:44:16 +0100
commitcad302175706a503fb0b73ff2032cbfc22d58c7a (patch)
treea880d29fd2978d4d1da364b8c3ec0be5d25366db /utils/cec-compliance/cec-test-adapter.cpp
parent35a5299801ce9868a027ab429a5302f1c70d6350 (diff)
cec-compliance: fix tests that affect msg.flags
Several tests assumed that the cec_msg flags field was always 0, but that is no longer the case. Update the tests. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Diffstat (limited to 'utils/cec-compliance/cec-test-adapter.cpp')
-rw-r--r--utils/cec-compliance/cec-test-adapter.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/utils/cec-compliance/cec-test-adapter.cpp b/utils/cec-compliance/cec-test-adapter.cpp
index 12b1578d..d3d3f772 100644
--- a/utils/cec-compliance/cec-test-adapter.cpp
+++ b/utils/cec-compliance/cec-test-adapter.cpp
@@ -273,6 +273,7 @@ int testTransmit(struct node *node)
msg.len = 1;
msg.timeout = 0;
msg.reply = 0;
+ msg.flags &= ~CEC_MSG_FL_REPLY_TO_FOLLOWERS;
fail_on_test(doioctl(node, CEC_TRANSMIT, &msg));
@@ -307,6 +308,7 @@ int testTransmit(struct node *node)
memset(&msg, 0xff, sizeof(msg));
msg.msg[0] = (la << 4) | i;
msg.timeout = 1001;
+ msg.flags &= ~CEC_MSG_FL_REPLY_TO_FOLLOWERS;
cec_msg_give_physical_addr(&msg, true);
fail_on_test(doioctl(node, CEC_TRANSMIT, &msg));
fail_on_test(msg.len != 5);
@@ -329,6 +331,7 @@ int testTransmit(struct node *node)
memset(&msg, 0xff, sizeof(msg));
msg.msg[0] = (la << 4) | i;
msg.timeout = 0;
+ msg.flags &= ~CEC_MSG_FL_REPLY_TO_FOLLOWERS;
cec_msg_give_physical_addr(&msg, false);
fail_on_test(doioctl(node, CEC_TRANSMIT, &msg));
fail_on_test(msg.timeout);
@@ -351,6 +354,7 @@ int testTransmit(struct node *node)
memset(&msg, 0xff, sizeof(msg));
msg.msg[0] = (la << 4) | i;
msg.timeout = 1002;
+ msg.flags &= ~CEC_MSG_FL_REPLY_TO_FOLLOWERS;
cec_msg_give_physical_addr(&msg, true);
fail_on_test(doioctl(node, CEC_TRANSMIT, &msg));
fail_on_test(msg.timeout != 1002);
@@ -371,6 +375,7 @@ int testTransmit(struct node *node)
memset(&msg, 0xff, sizeof(msg));
msg.msg[0] = (la << 4) | i;
msg.timeout = 0;
+ msg.flags &= ~CEC_MSG_FL_REPLY_TO_FOLLOWERS;
cec_msg_give_physical_addr(&msg, false);
fail_on_test(doioctl(node, CEC_TRANSMIT, &msg));
fail_on_test(msg.timeout);
@@ -523,6 +528,7 @@ int testNonBlocking(struct node *node)
memset(&msg, 0xff, sizeof(msg));
msg.msg[0] = (la << 4) | invalid_remote;
msg.timeout = 0;
+ msg.flags &= ~CEC_MSG_FL_REPLY_TO_FOLLOWERS;
cec_msg_give_physical_addr(&msg, true);
fail_on_test(doioctl(node, CEC_TRANSMIT, &msg));
fail_on_test(msg.len != 2);
@@ -616,6 +622,7 @@ int testNonBlocking(struct node *node)
memset(&msg, 0xff, sizeof(msg));
msg.msg[0] = (la << 4) | remote_la;
msg.timeout = 0;
+ msg.flags &= ~CEC_MSG_FL_REPLY_TO_FOLLOWERS;
cec_msg_give_physical_addr(&msg, true);
fail_on_test(doioctl(node, CEC_TRANSMIT, &msg));
fail_on_test(msg.len != 2);

Privacy Policy