linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: 邱名碩 <ccchiu77@gmail.com>
To: Pkshih <pkshih@realtek.com>
Cc: Andy Huang <tehuang@realtek.com>,
	"Larry.Finger@lwfinger.net" <Larry.Finger@lwfinger.net>,
	"kuba@kernel.org" <kuba@kernel.org>,
	"kvalo@codeaurora.org" <kvalo@codeaurora.org>,
	Reto Schneider <reto.schneider@husqvarnagroup.com>,
	"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: How does the rate adaptive mask work on Realtek WiFi driver
Date: Thu, 20 May 2021 09:28:46 +0800	[thread overview]
Message-ID: <CANgQ54cKA5N1h1kMgS52N1acrp+pJzV3e+8vd61miSS0_VVD7Q@mail.gmail.com> (raw)
In-Reply-To: <89da58fc162b46558d60495110fcf75f@realtek.com>

Pkshih <pkshih@realtek.com> 於 2021年5月14日 週五 下午2:08寫道:
>
>
> > -----Original Message-----
> > From: 邱名碩 [mailto:ccchiu77@gmail.com]
> > Sent: Monday, May 10, 2021 4:36 PM
> > To: Pkshih; Andy Huang; Larry.Finger@lwfinger.net; kuba@kernel.org; kvalo@codeaurora.org; Reto
> > Schneider; linux-wireless@vger.kernel.org; linux-kernel@vger.kernel.org
> > Subject: How does the rate adaptive mask work on Realtek WiFi driver
> >
> > Hi guys,
> >     I had a problem while verifying the ampdu tx throughput with the
> > rtl8xxxu driver on RTL8188CUS module. The throughput number is
> > relatively good, 39~42Mbps  TCP on 2.4GHz channel. However, the
> > retransmission rate is high, it's 15% ~ 21% with rtl8xxxu driver and
> > It's almost the same result with the rtl8192cu driver. I can get
> > averagely 7~10% retransmission rate in the same test bed with Realtek
> > vendor driver.
> >
> >     From the air capture, I can see the rtl8xxxu driver keep sending
> > the aggregated frames in MCS7 and doesn't even fall back to lower MCS
> > index in the subsequent retries. I can only see very few retried
> > packets been sent with MCS0 or 6Mbps grate. On the vendor driver, I'll
> > see the retried ampdu packets with MCS4 after 3 retries w/o ack from
> > the receiver.
> >
> >     From the rate mask command issued by the h2c command, I force both
> > the rtl8xxxu driver and vendor driver to use the same ratemask 0xfffff
> > (MCS 0-7 and b/g rate included) and leave the arg0 as-is (mostly 0xa0)
> > and I expect both drivers can do the rate adaptive thing in the same
> > way, but it seems to make no difference. The rtl8xxxu driver still
> > sends the packets with highest MCS.
> >
> >     Can anyone tell me what should I expect the rate adaptive to work
> > with the rate mask 0xfffff and 0xf0000? Does the 0xf0000 means that it
> > will pick up a tx rate only between nrate MCS4 to MCS7? I need a base
> > line so that I can judge it's simply a rate mask problem or maybe the
> > h2c command is not written correctly. Please kindly suggest what I
> > should do next. Thanks
> >
>
> The rate mask indicates which rates will be used by rate adaptive mechanism.
> I'm not sure the exact bit allocation for CCK/OFDM/MCS, maybe
> 0x0000f/0x00ff0/0xff0000 for CCK/OFDM/MCS respectively, but you can trace
> vendor driver to know the detail.
>
> I suggest you can try to send only OFDM rate mask, and expect to see OFDM
> rate only by your sniffer. If it's still keep on MCS7, rate adaptive may
> not work properly.
>
Thanks. That's my expectation and I'll try to verify it on vendor
driver and upstream rtl8192cu driver.

> Also, you can compare the content of rate adaptive H2C with vendor driver to
> see if the format is correct.
>
> Another thing is to try 'fix_rate' in tx_desc. Check the vendor driver to
> know the use_rate/rate/bw fields of tx_desc. Then, try to fix the rate you
> want.
>
If I set the fix_rate in tx_desc, will the rate mask in H2C command be
ignored? Or the underlying firmware will do the tx rate fallback for
the retry packets?

Chris

> --
> Ping-Ke
>

  reply	other threads:[~2021-05-20  1:29 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-10  8:35 How does the rate adaptive mask work on Realtek WiFi driver 邱名碩
2021-05-14  4:26 ` 邱名碩
2021-05-14  6:08 ` Pkshih
2021-05-20  1:28   ` 邱名碩 [this message]
2021-05-20  2:07     ` Pkshih
     [not found] <CANgQ54cG8FYTTBtrCc=e6aTsFQzfshM=Mco6J5BdtQ7XyH_Byg@mail.gmail.com>
2021-05-10  5:58 ` 邱名碩

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=CANgQ54cKA5N1h1kMgS52N1acrp+pJzV3e+8vd61miSS0_VVD7Q@mail.gmail.com \
    --to=ccchiu77@gmail.com \
    --cc=Larry.Finger@lwfinger.net \
    --cc=kuba@kernel.org \
    --cc=kvalo@codeaurora.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=pkshih@realtek.com \
    --cc=reto.schneider@husqvarnagroup.com \
    --cc=tehuang@realtek.com \
    /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;
as well as URLs for NNTP newsgroup(s).