]> git.baikalelectronics.ru Git - kernel.git/commit
ath10k: fix copy engine 5 destination ring stuck
authorRajkumar Manoharan <rmanohar@qti.qualcomm.com>
Wed, 21 Sep 2016 10:58:06 +0000 (16:28 +0530)
committerKalle Valo <kvalo@qca.qualcomm.com>
Wed, 28 Sep 2016 09:48:35 +0000 (12:48 +0300)
commit3215052993186abeb0154ae56207edcb0cf6860a
tree9aac2f80522d69534f790634f7c51b5cd5168493
parentaaef9f64a28ccb7fa477c777138a0ff2a9a47828
ath10k: fix copy engine 5 destination ring stuck

Firmware is running watchdog timer for tracking copy engine ring index
and write index. Whenever both indices are stuck at same location for
given duration, watchdog will be trigger to assert target. While
updating copy engine destination ring write index, driver ensures that
write index will not be same as read index by finding delta between these
two indices (CE_RING_DELTA).

HTT target to host copy engine (CE5) is special case where ring buffers
will be reused and delta check is not applied while updating write index.
In rare scenario, whenever CE5 ring is full, both indices will be referring
same location and this is causing CE ring stuck issue as explained
above. This issue is originally reported on IPQ4019 during long hour stress
testing and during veriwave max clients testsuites. The same issue is
also observed in other chips as well. Fix this by ensuring that write
index is one less than read index which means that full ring is
available for receiving data.

Cc: stable@vger.kernel.org
Tested-by: Tamizh chelvam <c_traja@qti.qualcomm.com>
Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
drivers/net/wireless/ath/ath10k/ce.c