From: Hans Verkuil <hverkuil@xs4all.nl> To: linux-media@vger.kernel.org Cc: dri-devel <dri-devel@lists.freedesktop.org>, Daniel Vetter <daniel.vetter@ffwll.ch>, Hans Verkuil <hans.verkuil@cisco.com> Subject: [PATCH for 4.13] cec: cec_transmit_attempt_done: ignore CEC_TX_STATUS_MAX_RETRIES Date: Wed, 12 Jul 2017 22:07:08 +0200 [thread overview] Message-ID: <106e748e-afe5-027b-0284-80e2928d1661@xs4all.nl> (raw) In-Reply-To: <20170711133011.41139-4-hverkuil@xs4all.nl> The switch in cec_transmit_attempt_done() should ignore the CEC_TX_STATUS_MAX_RETRIES status bit. Calling this function with e.g. CEC_TX_STATUS_NACK | CEC_TX_STATUS_MAX_RETRIES is perfectly legal and should not trigger the WARN(1). Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> --- After testing the DisplayPort CEC-Tunneling-over-AUX support with an adapter that didn't hook up the CEC pin correctly I found a bug in this CEC core function that is corrected with this patch. --- drivers/media/cec/cec-adap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/cec/cec-adap.c b/drivers/media/cec/cec-adap.c index bf45977b2823..d596b601ff42 100644 --- a/drivers/media/cec/cec-adap.c +++ b/drivers/media/cec/cec-adap.c @@ -559,7 +559,7 @@ EXPORT_SYMBOL_GPL(cec_transmit_done); void cec_transmit_attempt_done(struct cec_adapter *adap, u8 status) { - switch (status) { + switch (status & ~CEC_TX_STATUS_MAX_RETRIES) { case CEC_TX_STATUS_OK: cec_transmit_done(adap, status, 0, 0, 0, 0); return; -- 2.11.0
WARNING: multiple messages have this Message-ID (diff)
From: Hans Verkuil <hverkuil@xs4all.nl> To: linux-media@vger.kernel.org Cc: Daniel Vetter <daniel.vetter@ffwll.ch>, Hans Verkuil <hans.verkuil@cisco.com>, dri-devel <dri-devel@lists.freedesktop.org> Subject: [PATCH for 4.13] cec: cec_transmit_attempt_done: ignore CEC_TX_STATUS_MAX_RETRIES Date: Wed, 12 Jul 2017 22:07:08 +0200 [thread overview] Message-ID: <106e748e-afe5-027b-0284-80e2928d1661@xs4all.nl> (raw) In-Reply-To: <20170711133011.41139-4-hverkuil@xs4all.nl> The switch in cec_transmit_attempt_done() should ignore the CEC_TX_STATUS_MAX_RETRIES status bit. Calling this function with e.g. CEC_TX_STATUS_NACK | CEC_TX_STATUS_MAX_RETRIES is perfectly legal and should not trigger the WARN(1). Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> --- After testing the DisplayPort CEC-Tunneling-over-AUX support with an adapter that didn't hook up the CEC pin correctly I found a bug in this CEC core function that is corrected with this patch. --- drivers/media/cec/cec-adap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/cec/cec-adap.c b/drivers/media/cec/cec-adap.c index bf45977b2823..d596b601ff42 100644 --- a/drivers/media/cec/cec-adap.c +++ b/drivers/media/cec/cec-adap.c @@ -559,7 +559,7 @@ EXPORT_SYMBOL_GPL(cec_transmit_done); void cec_transmit_attempt_done(struct cec_adapter *adap, u8 status) { - switch (status) { + switch (status & ~CEC_TX_STATUS_MAX_RETRIES) { case CEC_TX_STATUS_OK: cec_transmit_done(adap, status, 0, 0, 0, 0); return; -- 2.11.0 _______________________________________________ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel
next prev parent reply other threads:[~2017-07-12 20:07 UTC|newest] Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top 2017-07-11 13:30 [PATCH 0/3] drm/i915: add DisplayPort CEC-Tunneling-over-AUX support Hans Verkuil 2017-07-11 13:30 ` Hans Verkuil 2017-07-11 13:30 ` [PATCH 1/3] drm: add support for DisplayPort CEC-Tunneling-over-AUX Hans Verkuil 2017-08-10 0:34 ` Carlos Santa 2017-08-10 19:19 ` Sean Paul 2017-07-11 13:30 ` [PATCH 2/3] drm-kms-helpers.rst: document the DP CEC helpers Hans Verkuil 2017-07-11 13:30 ` [PATCH 3/3] drm/i915: add DisplayPort CEC-Tunneling-over-AUX support Hans Verkuil 2017-07-12 20:07 ` Hans Verkuil [this message] 2017-07-12 20:07 ` [PATCH for 4.13] cec: cec_transmit_attempt_done: ignore CEC_TX_STATUS_MAX_RETRIES Hans Verkuil 2017-08-10 0:39 ` [PATCH 3/3] drm/i915: add DisplayPort CEC-Tunneling-over-AUX support Carlos Santa 2017-08-09 10:01 ` [PATCH 0/3] " Hans Verkuil
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=106e748e-afe5-027b-0284-80e2928d1661@xs4all.nl \ --to=hverkuil@xs4all.nl \ --cc=daniel.vetter@ffwll.ch \ --cc=dri-devel@lists.freedesktop.org \ --cc=hans.verkuil@cisco.com \ --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: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.