All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2] wifi: ath11k: fix monitor vdev creation with firmware recovery
@ 2022-10-14 15:50 ` Nagarajan Maran
  0 siblings, 0 replies; 4+ messages in thread
From: Nagarajan Maran @ 2022-10-14 15:50 UTC (permalink / raw)
  To: ath11k; +Cc: linux-wireless, Nagarajan Maran

During firmware recovery, the monitor interface is not
getting created in the driver and firmware since
the respective flags are not updated properly.

So after firmware recovery is successful, when monitor
interface is brought down manually, firmware assertion
is observed, since we are trying to bring down the
interface which is not yet created in the firmware.

Fix this by updating the monitor flags properly per
phy#, during firmware recovery.

Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1

Signed-off-by: Nagarajan Maran <quic_nmaran@quicinc.com>
---
v2:
 - added "wifi" to the patch title.
---
 drivers/net/wireless/ath/ath11k/core.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/net/wireless/ath/ath11k/core.c b/drivers/net/wireless/ath/ath11k/core.c
index 35a5de3a0a8a..0ab2f190f1ec 100644
--- a/drivers/net/wireless/ath/ath11k/core.c
+++ b/drivers/net/wireless/ath/ath11k/core.c
@@ -1677,6 +1677,10 @@ void ath11k_core_pre_reconfigure_recovery(struct ath11k_base *ab)
 			     ath11k_mac_tx_mgmt_pending_free, ar);
 		idr_destroy(&ar->txmgmt_idr);
 		wake_up(&ar->txmgmt_empty_waitq);
+
+		ar->monitor_vdev_id = -1;
+		clear_bit(ATH11K_FLAG_MONITOR_STARTED, &ar->monitor_flags);
+		clear_bit(ATH11K_FLAG_MONITOR_VDEV_CREATED, &ar->monitor_flags);
 	}
 
 	wake_up(&ab->wmi_ab.tx_credits_wq);
-- 
2.17.1


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

* [PATCH v2] wifi: ath11k: fix monitor vdev creation with firmware recovery
@ 2022-10-14 15:50 ` Nagarajan Maran
  0 siblings, 0 replies; 4+ messages in thread
From: Nagarajan Maran @ 2022-10-14 15:50 UTC (permalink / raw)
  To: ath11k; +Cc: linux-wireless, Nagarajan Maran

During firmware recovery, the monitor interface is not
getting created in the driver and firmware since
the respective flags are not updated properly.

So after firmware recovery is successful, when monitor
interface is brought down manually, firmware assertion
is observed, since we are trying to bring down the
interface which is not yet created in the firmware.

Fix this by updating the monitor flags properly per
phy#, during firmware recovery.

Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1

Signed-off-by: Nagarajan Maran <quic_nmaran@quicinc.com>
---
v2:
 - added "wifi" to the patch title.
---
 drivers/net/wireless/ath/ath11k/core.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/net/wireless/ath/ath11k/core.c b/drivers/net/wireless/ath/ath11k/core.c
index 35a5de3a0a8a..0ab2f190f1ec 100644
--- a/drivers/net/wireless/ath/ath11k/core.c
+++ b/drivers/net/wireless/ath/ath11k/core.c
@@ -1677,6 +1677,10 @@ void ath11k_core_pre_reconfigure_recovery(struct ath11k_base *ab)
 			     ath11k_mac_tx_mgmt_pending_free, ar);
 		idr_destroy(&ar->txmgmt_idr);
 		wake_up(&ar->txmgmt_empty_waitq);
+
+		ar->monitor_vdev_id = -1;
+		clear_bit(ATH11K_FLAG_MONITOR_STARTED, &ar->monitor_flags);
+		clear_bit(ATH11K_FLAG_MONITOR_VDEV_CREATED, &ar->monitor_flags);
 	}
 
 	wake_up(&ab->wmi_ab.tx_credits_wq);
-- 
2.17.1


-- 
ath11k mailing list
ath11k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath11k

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

* Re: [PATCH v2] wifi: ath11k: fix monitor vdev creation with firmware recovery
  2022-10-14 15:50 ` Nagarajan Maran
@ 2022-10-28 13:40   ` Kalle Valo
  -1 siblings, 0 replies; 4+ messages in thread
From: Kalle Valo @ 2022-10-28 13:40 UTC (permalink / raw)
  To: Nagarajan Maran; +Cc: ath11k, linux-wireless, Nagarajan Maran

Nagarajan Maran <quic_nmaran@quicinc.com> wrote:

> During firmware recovery, the monitor interface is not
> getting created in the driver and firmware since
> the respective flags are not updated properly.
> 
> So after firmware recovery is successful, when monitor
> interface is brought down manually, firmware assertion
> is observed, since we are trying to bring down the
> interface which is not yet created in the firmware.
> 
> Fix this by updating the monitor flags properly per
> phy#, during firmware recovery.
> 
> Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1
> 
> Signed-off-by: Nagarajan Maran <quic_nmaran@quicinc.com>
> Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>

Patch applied to ath-next branch of ath.git, thanks.

f3ca72b03271 wifi: ath11k: fix monitor vdev creation with firmware recovery

-- 
https://patchwork.kernel.org/project/linux-wireless/patch/20221014155054.11471-1-quic_nmaran@quicinc.com/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches


-- 
ath11k mailing list
ath11k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath11k

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

* Re: [PATCH v2] wifi: ath11k: fix monitor vdev creation with firmware recovery
@ 2022-10-28 13:40   ` Kalle Valo
  0 siblings, 0 replies; 4+ messages in thread
From: Kalle Valo @ 2022-10-28 13:40 UTC (permalink / raw)
  To: Nagarajan Maran; +Cc: ath11k, linux-wireless, Nagarajan Maran

Nagarajan Maran <quic_nmaran@quicinc.com> wrote:

> During firmware recovery, the monitor interface is not
> getting created in the driver and firmware since
> the respective flags are not updated properly.
> 
> So after firmware recovery is successful, when monitor
> interface is brought down manually, firmware assertion
> is observed, since we are trying to bring down the
> interface which is not yet created in the firmware.
> 
> Fix this by updating the monitor flags properly per
> phy#, during firmware recovery.
> 
> Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1
> 
> Signed-off-by: Nagarajan Maran <quic_nmaran@quicinc.com>
> Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>

Patch applied to ath-next branch of ath.git, thanks.

f3ca72b03271 wifi: ath11k: fix monitor vdev creation with firmware recovery

-- 
https://patchwork.kernel.org/project/linux-wireless/patch/20221014155054.11471-1-quic_nmaran@quicinc.com/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches


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

end of thread, other threads:[~2022-10-28 13:42 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-14 15:50 [PATCH v2] wifi: ath11k: fix monitor vdev creation with firmware recovery Nagarajan Maran
2022-10-14 15:50 ` Nagarajan Maran
2022-10-28 13:40 ` Kalle Valo
2022-10-28 13:40   ` Kalle Valo

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.