ath10k: correct target assert problem due to CE5 stuck
authorManikanta Pubbisetty <mpubbise@codeaurora.org>
Thu, 12 Apr 2018 12:16:50 +0000 (17:46 +0530)
committerKalle Valo <kvalo@codeaurora.org>
Thu, 19 Apr 2018 15:58:27 +0000 (18:58 +0300)
commit1e8f77502341035f079039c9aa9a647ebc9d881a
tree7623c25be360c4b365e95287194f9ff3896142b5
parent5072d87426bb6ed685d3ad9b694f5571859eca06
ath10k: correct target assert problem due to CE5 stuck

Correct a minor bug in the commit 0628467f97b5 ("ath10k: fix
copy engine 5 destination ring stuck") which introduced a change to fix
firmware assert that happens when ring indices of copy engine 5 are stuck
for a specific duration, problem with this fix is that it did not use
ring arithmatic. As a result,firmware asserts did not go away entirely
athough the frequency of occurrence has reduced. Using ring arithmatic
to fix the issue.

Tested on QCA9984(fw version-10.4-3.4-00082).

Fixes: 0628467f97b5 ("ath10k: fix copy engine 5 destination ring stuck)
Signed-off-by: Manikanta Pubbisetty <mpubbise@codeaurora.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/ath/ath10k/ce.c