提交 18618a9f 编写于 作者: M Maya Erez 提交者: Kalle Valo

wil6210: missing reinit_completion in HALP voting

After setting HALP ICR bit, we keep it set until HALP unvote.
Masking HALP ICR should protect the driver from hitting the HALP ICR
over and over again. However, in case there is another MISC ICR
we will read the HALP ICR and issue a completion. This can lead to
a case where HALP voting is completed immediately, as the completion
is already set.
Reinit the HALP completion before the actual vote will clear previous
completions and protect from such cases.
Signed-off-by: NMaya Erez <qca_merez@qca.qualcomm.com>
Signed-off-by: NKalle Valo <kvalo@qca.qualcomm.com>
上级 5eb443e9
...@@ -1158,6 +1158,7 @@ void wil_halp_vote(struct wil6210_priv *wil) ...@@ -1158,6 +1158,7 @@ void wil_halp_vote(struct wil6210_priv *wil)
wil->halp.ref_cnt); wil->halp.ref_cnt);
if (++wil->halp.ref_cnt == 1) { if (++wil->halp.ref_cnt == 1) {
reinit_completion(&wil->halp.comp);
wil6210_set_halp(wil); wil6210_set_halp(wil);
rc = wait_for_completion_timeout(&wil->halp.comp, to_jiffies); rc = wait_for_completion_timeout(&wil->halp.comp, to_jiffies);
if (!rc) { if (!rc) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册