mirror of
https://github.com/torvalds/linux.git
synced 2024-11-27 06:31:52 +00:00
media: cec-adap.c: stop trying LAs on CEC_TX_STATUS_TIMEOUT
If, while trying to claim a free logical address, a POLL message times out, then abort this process. A CEC_TX_STATUS_TIMEOUT should be handled the same as a CEC_TX_STATUS_ABORTED. This avoids a situation where transmits time out due to a driver or hardware bug and it takes ages before the attempt to find available free logical addresses finishes. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
This commit is contained in:
parent
498946cf6b
commit
184c387db0
@ -1282,10 +1282,11 @@ static int cec_config_log_addr(struct cec_adapter *adap,
|
||||
return err;
|
||||
|
||||
/*
|
||||
* The message was aborted due to a disconnect or
|
||||
* The message was aborted or timed out due to a disconnect or
|
||||
* unconfigure, just bail out.
|
||||
*/
|
||||
if (msg.tx_status & CEC_TX_STATUS_ABORTED)
|
||||
if (msg.tx_status &
|
||||
(CEC_TX_STATUS_ABORTED | CEC_TX_STATUS_TIMEOUT))
|
||||
return -EINTR;
|
||||
if (msg.tx_status & CEC_TX_STATUS_OK)
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user