linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] wifi: ath11k: adjust a comment to reflect reality
@ 2024-02-27  2:45 Kevin Lo
  2024-03-01 16:16 ` Jeff Johnson
  0 siblings, 1 reply; 3+ messages in thread
From: Kevin Lo @ 2024-02-27  2:45 UTC (permalink / raw)
  To: ath11k; +Cc: Kalle Valo, Jeff Johnson, linux-wireless

In ath11k_mhi_set_mhictrl_reset(), I observed on QCA6390/QCN9074/WCN6855,
MHISTATUS has SYSERR bit always been set after SOC_GLOBAL_RESET.

Signed-off-by: Kevin Lo <kevlo@kevlo.org>
---
diff --git a/drivers/net/wireless/ath/ath11k/mhi.c b/drivers/net/wireless/ath/ath11k/mhi.c
index 3de7fa6f88d0..1198e80d9dff 100644
--- a/drivers/net/wireless/ath/ath11k/mhi.c
+++ b/drivers/net/wireless/ath/ath11k/mhi.c
@@ -158,8 +158,8 @@ void ath11k_mhi_set_mhictrl_reset(struct ath11k_base *ab)
 
 	ath11k_dbg(ab, ATH11K_DBG_PCI, "mhistatus 0x%x\n", val);
 
-	/* Observed on QCA6390 that after SOC_GLOBAL_RESET, MHISTATUS
-	 * has SYSERR bit set and thus need to set MHICTRL_RESET
+	/* After SOC_GLOBAL_RESET, MHISTATUS has SYSERR bit
+	 * always been set and thus need to set MHICTRL_RESET
 	 * to clear SYSERR.
 	 */
 	ath11k_pcic_write32(ab, MHICTRL, MHICTRL_RESET_MASK);

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] wifi: ath11k: adjust a comment to reflect reality
  2024-02-27  2:45 [PATCH] wifi: ath11k: adjust a comment to reflect reality Kevin Lo
@ 2024-03-01 16:16 ` Jeff Johnson
  2024-03-04  7:57   ` Kevin Lo
  0 siblings, 1 reply; 3+ messages in thread
From: Jeff Johnson @ 2024-03-01 16:16 UTC (permalink / raw)
  To: Kevin Lo, ath11k; +Cc: Kalle Valo, linux-wireless

On 2/26/2024 6:45 PM, Kevin Lo wrote:
> In ath11k_mhi_set_mhictrl_reset(), I observed on QCA6390/QCN9074/WCN6855,
> MHISTATUS has SYSERR bit always been set after SOC_GLOBAL_RESET.
> 
> Signed-off-by: Kevin Lo <kevlo@kevlo.org>
> ---
> diff --git a/drivers/net/wireless/ath/ath11k/mhi.c b/drivers/net/wireless/ath/ath11k/mhi.c
> index 3de7fa6f88d0..1198e80d9dff 100644
> --- a/drivers/net/wireless/ath/ath11k/mhi.c
> +++ b/drivers/net/wireless/ath/ath11k/mhi.c
> @@ -158,8 +158,8 @@ void ath11k_mhi_set_mhictrl_reset(struct ath11k_base *ab)
>  
>  	ath11k_dbg(ab, ATH11K_DBG_PCI, "mhistatus 0x%x\n", val);
>  
> -	/* Observed on QCA6390 that after SOC_GLOBAL_RESET, MHISTATUS
> -	 * has SYSERR bit set and thus need to set MHICTRL_RESET
> +	/* After SOC_GLOBAL_RESET, MHISTATUS has SYSERR bit
> +	 * always been set and thus need to set MHICTRL_RESET
>  	 * to clear SYSERR.
>  	 */
>  	ath11k_pcic_write32(ab, MHICTRL, MHICTRL_RESET_MASK);

Unless you've verified this is always true for every supported chipset
I'd rather more accurately say something like:
After SOC_GLOBAL_RESET, MHISTATUS may still have SYSERR bit set and thus...

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] wifi: ath11k: adjust a comment to reflect reality
  2024-03-01 16:16 ` Jeff Johnson
@ 2024-03-04  7:57   ` Kevin Lo
  0 siblings, 0 replies; 3+ messages in thread
From: Kevin Lo @ 2024-03-04  7:57 UTC (permalink / raw)
  To: Jeff Johnson; +Cc: ath11k, Kalle Valo, linux-wireless

On Fri, Mar 01, 2024 at 08:16:16AM -0800, Jeff Johnson wrote:
> 
> On 2/26/2024 6:45 PM, Kevin Lo wrote:
> > In ath11k_mhi_set_mhictrl_reset(), I observed on QCA6390/QCN9074/WCN6855,
> > MHISTATUS has SYSERR bit always been set after SOC_GLOBAL_RESET.
> > 
> > Signed-off-by: Kevin Lo <kevlo@kevlo.org>
> > ---
> > diff --git a/drivers/net/wireless/ath/ath11k/mhi.c b/drivers/net/wireless/ath/ath11k/mhi.c
> > index 3de7fa6f88d0..1198e80d9dff 100644
> > --- a/drivers/net/wireless/ath/ath11k/mhi.c
> > +++ b/drivers/net/wireless/ath/ath11k/mhi.c
> > @@ -158,8 +158,8 @@ void ath11k_mhi_set_mhictrl_reset(struct ath11k_base *ab)
> >  
> >  	ath11k_dbg(ab, ATH11K_DBG_PCI, "mhistatus 0x%x\n", val);
> >  
> > -	/* Observed on QCA6390 that after SOC_GLOBAL_RESET, MHISTATUS
> > -	 * has SYSERR bit set and thus need to set MHICTRL_RESET
> > +	/* After SOC_GLOBAL_RESET, MHISTATUS has SYSERR bit
> > +	 * always been set and thus need to set MHICTRL_RESET
> >  	 * to clear SYSERR.
> >  	 */
> >  	ath11k_pcic_write32(ab, MHICTRL, MHICTRL_RESET_MASK);
> 
> Unless you've verified this is always true for every supported chipset

Only PCIe devices trigger the call to ath11k_mhi_set_mhictrl_reset(),
and I've verified this on the QCA6390, QCN9074, and WCN6855 chips.

> I'd rather more accurately say something like:
> After SOC_GLOBAL_RESET, MHISTATUS may still have SYSERR bit set and thus...

Okay, I'll update the comments as per your suggestion, thanks.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-03-04  7:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-27  2:45 [PATCH] wifi: ath11k: adjust a comment to reflect reality Kevin Lo
2024-03-01 16:16 ` Jeff Johnson
2024-03-04  7:57   ` Kevin Lo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).