public inbox for linux-mediatek@lists.infradead.org
 help / color / mirror / Atom feed
From: Ryder Lee <Ryder.Lee@mediatek.com>
To: "linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
	"nbd@nbd.name" <nbd@nbd.name>,
	"Deren Wu (武德仁)" <Deren.Wu@mediatek.com>
Cc: "lorenzo.bianconi@redhat.com" <lorenzo.bianconi@redhat.com>,
	"Shayne Chen (陳軒丞)" <Shayne.Chen@mediatek.com>,
	"linux-mediatek@lists.infradead.org"
	<linux-mediatek@lists.infradead.org>,
	"Evelyn Tsai (蔡珊鈺)" <Evelyn.Tsai@mediatek.com>,
	"Chui-hao Chiu (邱垂浩)" <Chui-hao.Chiu@mediatek.com>
Subject: Re: [PATCH v5] wifi: mt76: mt7915: report tx retries/failed counts for non-WED path
Date: Tue, 9 May 2023 18:10:40 +0000	[thread overview]
Message-ID: <46117c51d736be7ab8e5cf280d779f45751b73ae.camel@mediatek.com> (raw)
In-Reply-To: <13d9169b5709efad969d7d167a1ff19828395fed.1683602740.git.ryder.lee@mediatek.com>

On Tue, 2023-05-09 at 11:26 +0800, Ryder Lee wrote:
> Get missing tx retries/failed counts from txfree done events and
> report
> them via mt7915_sta_statistics().
> 
> Co-developed-by: Peter Chiu <chui-hao.chiu@mediatek.com>
> Signed-off-by: Peter Chiu <chui-hao.chiu@mediatek.com>
> Signed-off-by: Ryder Lee <ryder.lee@mediatek.com>
> ---
> v5 - fix noacked
> v4 - switch from Tx latency report to enable Tx count in txfree path
> for non-v3 format
> v3 - add a missing check for mt7921
> v2 - add a missing check for non-v3 format
> ---
>  .../wireless/mediatek/mt76/mt76_connac_mac.c  |  7 ++++--
>  .../net/wireless/mediatek/mt76/mt7915/init.c  |  2 ++
>  .../net/wireless/mediatek/mt76/mt7915/mac.c   | 22
> +++++++++++++++++--
>  .../net/wireless/mediatek/mt76/mt7915/mac.h   |  7 +++++-
>  .../net/wireless/mediatek/mt76/mt7915/main.c  | 12 +++++-----
>  .../net/wireless/mediatek/mt76/mt7915/regs.h  |  3 +++
>  6 files changed, 42 insertions(+), 11 deletions(-)
> 
> diff --git a/drivers/net/wireless/mediatek/mt76/mt76_connac_mac.c
> b/drivers/net/wireless/mediatek/mt76/mt76_connac_mac.c
> index ee0fbfcd07d6..6b515f330976 100644
> --- a/drivers/net/wireless/mediatek/mt76/mt76_connac_mac.c
> +++ b/drivers/net/wireless/mediatek/mt76/mt76_connac_mac.c
> @@ -728,16 +728,19 @@ bool mt76_connac2_mac_add_txs_skb(struct
> mt76_dev *dev, struct mt76_wcid *wcid,
>  	skb = mt76_tx_status_skb_get(dev, wcid, pid, &list);
>  	if (skb) {
>  		struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
> -		bool noacked = !(info->flags & IEEE80211_TX_STAT_ACK);
> +		bool noacked;
>  
>  		if (!(le32_to_cpu(txs_data[0]) &
> MT_TXS0_ACK_ERROR_MASK))
>  			info->flags |= IEEE80211_TX_STAT_ACK;
>  
> +		noacked = !(info->flags & IEEE80211_TX_STAT_ACK);
>  		info->status.ampdu_len = 1;
>  		info->status.ampdu_ack_len = !noacked;
>  		info->status.rates[0].idx = -1;
>  
> -		wcid->stats.tx_failed += noacked;
> +		/* avoid double counting if dev supports txfree event
> */
> +		if (is_mt7921(dev))
> +			wcid->stats.tx_failed += noacked;
@Deren, can you help to check if mt7921 can drop this  and calculate
tx_failed from txfree directly?

Ryder

  reply	other threads:[~2023-05-09 18:11 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-09  3:26 [PATCH v5] wifi: mt76: mt7915: report tx retries/failed counts for non-WED path Ryder Lee
2023-05-09 18:10 ` Ryder Lee [this message]
2023-05-10  3:11   ` Deren Wu (武德仁)

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=46117c51d736be7ab8e5cf280d779f45751b73ae.camel@mediatek.com \
    --to=ryder.lee@mediatek.com \
    --cc=Chui-hao.Chiu@mediatek.com \
    --cc=Deren.Wu@mediatek.com \
    --cc=Evelyn.Tsai@mediatek.com \
    --cc=Shayne.Chen@mediatek.com \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=lorenzo.bianconi@redhat.com \
    --cc=nbd@nbd.name \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox