提交 00f6f92d 编写于 作者: H Hans Verkuil 提交者: Mauro Carvalho Chehab

media: adv7511: fix incorrect clear of CEC receive interrupt

If a CEC message was received and the RX interrupt was set, but
not yet processed, and a new transmit was issues, then the
transmit code would inadvertently clear the RX interrupt and
after that no new messages would ever be received.

Instead it should only clear TX interrupts since register 0x97
is a clear-on-write register.
Signed-off-by: NHans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: NMauro Carvalho Chehab <mchehab+samsung@kernel.org>
上级 73678158
...@@ -831,8 +831,8 @@ static int adv7511_cec_adap_transmit(struct cec_adapter *adap, u8 attempts, ...@@ -831,8 +831,8 @@ static int adv7511_cec_adap_transmit(struct cec_adapter *adap, u8 attempts,
*/ */
adv7511_cec_write_and_or(sd, 0x12, ~0x70, max(1, attempts - 1) << 4); adv7511_cec_write_and_or(sd, 0x12, ~0x70, max(1, attempts - 1) << 4);
/* blocking, clear cec tx irq status */ /* clear cec tx irq status */
adv7511_wr_and_or(sd, 0x97, 0xc7, 0x38); adv7511_wr(sd, 0x97, 0x38);
/* write data */ /* write data */
for (i = 0; i < len; i++) for (i = 0; i < len; i++)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册