* [PATCH v2] wifi: ath12k: fix desc address calculation in wbm tx completion
@ 2024-03-11 18:07 quic_tmariyap
2024-03-11 18:24 ` Jeff Johnson
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: quic_tmariyap @ 2024-03-11 18:07 UTC (permalink / raw)
To: ath12k; +Cc: linux-wireless
From: Thiraviyam Mariyappan <quic_tmariyap@quicinc.com>
In tx completion, status desc is obtained from offsetting the address
from wbm ring. Having HTT_TX_WBM_COMP_STATUS_OFFSET(8) and reserved 8
bytes in status desc offsets the address twice and read the values
from the incorrect address. Hence, remove the
HTT_TX_WBM_COMP_STATUS_OFFSET from wbm completion address calculation.
Also this patch is applicable for WCN7850.
Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.0.1-00029-QCAHKSWPL_SILICONZ-1
Signed-off-by: Thiraviyam Mariyappan <quic_tmariyap@quicinc.com>
---
v2:
- removed the addition of HTT_TX_WBM_COMP_STATUS_OFFSET instead of
structure changes.
- modified commit log and renamed subject from "wifi: ath12k: remove
reserve member of wbm completion structure".
---
drivers/net/wireless/ath/ath12k/dp.h | 2 --
drivers/net/wireless/ath/ath12k/dp_tx.c | 2 +-
2 files changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/net/wireless/ath/ath12k/dp.h b/drivers/net/wireless/ath/ath12k/dp.h
index eb2dd408e081..9b83b9230bbc 100644
--- a/drivers/net/wireless/ath/ath12k/dp.h
+++ b/drivers/net/wireless/ath/ath12k/dp.h
@@ -377,8 +377,6 @@ struct ath12k_dp {
/* peer meta data */
#define HTT_TCL_META_DATA_PEER_ID GENMASK(15, 2)
-#define HTT_TX_WBM_COMP_STATUS_OFFSET 8
-
/* HTT tx completion is overlaid in wbm_release_ring */
#define HTT_TX_WBM_COMP_INFO0_STATUS GENMASK(16, 13)
#define HTT_TX_WBM_COMP_INFO1_REINJECT_REASON GENMASK(3, 0)
diff --git a/drivers/net/wireless/ath/ath12k/dp_tx.c b/drivers/net/wireless/ath/ath12k/dp_tx.c
index 572b87153647..9b6d7d72f57c 100644
--- a/drivers/net/wireless/ath/ath12k/dp_tx.c
+++ b/drivers/net/wireless/ath/ath12k/dp_tx.c
@@ -414,7 +414,7 @@ ath12k_dp_tx_process_htt_tx_complete(struct ath12k_base *ab,
struct ath12k_dp_htt_wbm_tx_status ts = {0};
enum hal_wbm_htt_tx_comp_status wbm_status;
- status_desc = desc + HTT_TX_WBM_COMP_STATUS_OFFSET;
+ status_desc = desc;
wbm_status = le32_get_bits(status_desc->info0,
HTT_TX_WBM_COMP_INFO0_STATUS);
--
2.17.1
^ permalink raw reply related [flat|nested] 4+ messages in thread* Re: [PATCH v2] wifi: ath12k: fix desc address calculation in wbm tx completion
2024-03-11 18:07 [PATCH v2] wifi: ath12k: fix desc address calculation in wbm tx completion quic_tmariyap
@ 2024-03-11 18:24 ` Jeff Johnson
2024-03-20 10:07 ` Kalle Valo
2024-03-20 12:02 ` Kalle Valo
2 siblings, 0 replies; 4+ messages in thread
From: Jeff Johnson @ 2024-03-11 18:24 UTC (permalink / raw)
To: quic_tmariyap, ath12k; +Cc: linux-wireless
On 3/11/2024 11:07 AM, quic_tmariyap@quicinc.com wrote:
> From: Thiraviyam Mariyappan <quic_tmariyap@quicinc.com>
>
> In tx completion, status desc is obtained from offsetting the address
> from wbm ring. Having HTT_TX_WBM_COMP_STATUS_OFFSET(8) and reserved 8
> bytes in status desc offsets the address twice and read the values
> from the incorrect address. Hence, remove the
> HTT_TX_WBM_COMP_STATUS_OFFSET from wbm completion address calculation.
>
> Also this patch is applicable for WCN7850.
>
> Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.0.1-00029-QCAHKSWPL_SILICONZ-1
>
> Signed-off-by: Thiraviyam Mariyappan <quic_tmariyap@quicinc.com>
Acked-by: Jeff Johnson <quic_jjohnson@quicinc.com>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v2] wifi: ath12k: fix desc address calculation in wbm tx completion
2024-03-11 18:07 [PATCH v2] wifi: ath12k: fix desc address calculation in wbm tx completion quic_tmariyap
2024-03-11 18:24 ` Jeff Johnson
@ 2024-03-20 10:07 ` Kalle Valo
2024-03-20 12:02 ` Kalle Valo
2 siblings, 0 replies; 4+ messages in thread
From: Kalle Valo @ 2024-03-20 10:07 UTC (permalink / raw)
To: quic_tmariyap; +Cc: ath12k, linux-wireless
quic_tmariyap@quicinc.com wrote:
> In tx completion, status desc is obtained from offsetting the address
> from wbm ring. Having HTT_TX_WBM_COMP_STATUS_OFFSET(8) and reserved 8
> bytes in status desc offsets the address twice and read the values
> from the incorrect address. Hence, remove the
> HTT_TX_WBM_COMP_STATUS_OFFSET from wbm completion address calculation.
>
> Also this patch is applicable for WCN7850.
>
> Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.0.1-00029-QCAHKSWPL_SILICONZ-1
>
> Signed-off-by: Thiraviyam Mariyappan <quic_tmariyap@quicinc.com>
> Acked-by: Jeff Johnson <quic_jjohnson@quicinc.com>
> Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>
Patch applied to ath-next branch of ath.git, thanks.
a49732b1f1f8 wifi: ath12k: fix desc address calculation in wbm tx completion
--
https://patchwork.kernel.org/project/linux-wireless/patch/20240311180708.9334-1-quic_tmariyap@quicinc.com/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v2] wifi: ath12k: fix desc address calculation in wbm tx completion
2024-03-11 18:07 [PATCH v2] wifi: ath12k: fix desc address calculation in wbm tx completion quic_tmariyap
2024-03-11 18:24 ` Jeff Johnson
2024-03-20 10:07 ` Kalle Valo
@ 2024-03-20 12:02 ` Kalle Valo
2 siblings, 0 replies; 4+ messages in thread
From: Kalle Valo @ 2024-03-20 12:02 UTC (permalink / raw)
To: quic_tmariyap; +Cc: ath12k, linux-wireless
quic_tmariyap@quicinc.com writes:
> From: Thiraviyam Mariyappan <quic_tmariyap@quicinc.com>
>
> In tx completion, status desc is obtained from offsetting the address
> from wbm ring. Having HTT_TX_WBM_COMP_STATUS_OFFSET(8) and reserved 8
> bytes in status desc offsets the address twice and read the values
> from the incorrect address. Hence, remove the
> HTT_TX_WBM_COMP_STATUS_OFFSET from wbm completion address calculation.
>
> Also this patch is applicable for WCN7850.
>
> Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.0.1-00029-QCAHKSWPL_SILICONZ-1
>
> Signed-off-by: Thiraviyam Mariyappan <quic_tmariyap@quicinc.com>
BTW please fix your email setup. Your From header has now:
From: quic_tmariyap@quicinc.com
But it should contain your full name as well:
From: Thiraviyam Mariyappan <quic_tmariyap@quicinc.com>
That way there's no need to have an extra From header in the email body.
--
https://patchwork.kernel.org/project/linux-wireless/list/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2024-03-20 12:02 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-11 18:07 [PATCH v2] wifi: ath12k: fix desc address calculation in wbm tx completion quic_tmariyap
2024-03-11 18:24 ` Jeff Johnson
2024-03-20 10:07 ` Kalle Valo
2024-03-20 12:02 ` Kalle Valo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox