summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2016-07-15 11:13:49 -0300
committerRay Zhang <rayz@codeaurora.org>2017-05-25 11:21:59 +0800
commit5ab280ffae7dbd379b59d6519cffc975153765ce (patch)
tree664a81535a96befdb7d84ba12ad7c3a9cc5fa630
parenta293351e1ce30b84abee0adfee1be23f387ff353 (diff)
[media] cec: set timestamp for selfie transmits
Attempts to send CEC messages to yourself are detected in the framework and returned with a NACK error. However, the tx_ts was never filled in that case. So just set it. Change-Id: Ifd8be78030778d3d99b88b353905879c2079c2c5 Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com> Git-commit: 9a3f14ea802fd0d8848d8e16566b769e4ce09d68 Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git Signed-off-by: Ray Zhang <rayz@codeaurora.org>
-rw-r--r--drivers/staging/media/cec/cec-adap.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/staging/media/cec/cec-adap.c b/drivers/staging/media/cec/cec-adap.c
index 07147a1d2b6b..4d86a6c9258f 100644
--- a/drivers/staging/media/cec/cec-adap.c
+++ b/drivers/staging/media/cec/cec-adap.c
@@ -603,6 +603,7 @@ int cec_transmit_msg_fh(struct cec_adapter *adap, struct cec_msg *msg,
* easy to handle it here so the behavior will be
* consistent.
*/
+ msg->tx_ts = ktime_get_ns();
msg->tx_status = CEC_TX_STATUS_NACK |
CEC_TX_STATUS_MAX_RETRIES;
msg->tx_nack_cnt = 1;