2022-01-04 19:13:19

by Alper Nebi Yasak

[permalink] [raw]
Subject: rtw88: EDCCA makes Wi-Fi unusable with a USB 3.0 SSD connected

Hi,

I have a laptop with a rtw_8822be wireless card and boot Debian on it
from an external USB 3.0 SSD. I also configured the wireless regulatory
domain as TR (DFS-ETSI). Things worked fine this way until the v5.16-rc
releases where I have been practically unable to use Wi-Fi. The network
shows as connected but I can't load any website, pings to my router
mostly fail with "Destination Host Unreachable".

I tracked it down to commit 7285eb9693a2 ("rtw88: support adaptivity for
ETSI/JP DFS region"), tried the debugfs toggle mentioned in that commit,
and found a few more things that also work:

- echo 0 | sudo tee /sys/kernel/debug/ieee80211/phy0/rtw88/edcca_enable
- Connecting the SSD through a USB 2.0 hub
- Connecting the SSD to the port on other side of the laptop
- Putting my phone next to the display, "shielding" it from the ports

All combined lead me to think it's interference from USB 3.0 that's the
real cause of my problems.

I also see this mail on a previous version of the patch [1]:

> As mentioned in commit message, the debugfs is expected to be used when debugging
> in noisy environment. In that case, we think all rtw88 devices will probably
> be affected. Besides, we believe that turning EDCCA off is a temporary state under
> debugging.

[1]
https://lore.kernel.org/linux-wireless/[email protected]/

So I'm not sure what to think and wanted to ask here. Is EDCCA
working-as-intended in my case, meaning I should fix my "noisy
environment"? Or is something wrong with the implementation that should
be debugged? I think it'll be very easy for other people to run into
this issue, maybe it should be disabled by default, or turned into a
module option?

Thanks in advance.


2022-01-06 05:53:58

by Ping-Ke Shih

[permalink] [raw]
Subject: RE: rtw88: EDCCA makes Wi-Fi unusable with a USB 3.0 SSD connected

Hi

> -----Original Message-----
> From: Alper Nebi Yasak <[email protected]>
> Sent: Wednesday, January 5, 2022 3:13 AM
> To: [email protected]; Pkshih <[email protected]>; Kevin Yang <[email protected]>
> Cc: Yan-Hsuan Chuang <[email protected]>; Kalle Valo <[email protected]>
> Subject: rtw88: EDCCA makes Wi-Fi unusable with a USB 3.0 SSD connected
>
> Hi,
>
> I have a laptop with a rtw_8822be wireless card and boot Debian on it
> from an external USB 3.0 SSD. I also configured the wireless regulatory
> domain as TR (DFS-ETSI). Things worked fine this way until the v5.16-rc
> releases where I have been practically unable to use Wi-Fi. The network
> shows as connected but I can't load any website, pings to my router
> mostly fail with "Destination Host Unreachable".
>
> I tracked it down to commit 7285eb9693a2 ("rtw88: support adaptivity for
> ETSI/JP DFS region"), tried the debugfs toggle mentioned in that commit,
> and found a few more things that also work:
>
> - echo 0 | sudo tee /sys/kernel/debug/ieee80211/phy0/rtw88/edcca_enable
> - Connecting the SSD through a USB 2.0 hub
> - Connecting the SSD to the port on other side of the laptop
> - Putting my phone next to the display, "shielding" it from the ports
>
> All combined lead me to think it's interference from USB 3.0 that's the
> real cause of my problems.

I think you have sorted the problem that USB 3.0 is the interference source.
Since the clock of USB 3.0 is 2.5G, so please try to connect a 5G AP to see if the
problem is still existing.

>
> I also see this mail on a previous version of the patch [1]:
>
> > As mentioned in commit message, the debugfs is expected to be used when debugging
> > in noisy environment. In that case, we think all rtw88 devices will probably
> > be affected. Besides, we believe that turning EDCCA off is a temporary state under
> > debugging.
>
> [1]
> https://lore.kernel.org/linux-wireless/[email protected]/
>
> So I'm not sure what to think and wanted to ask here. Is EDCCA
> working-as-intended in my case, meaning I should fix my "noisy
> environment"? Or is something wrong with the implementation that should
> be debugged? I think it'll be very easy for other people to run into
> this issue, maybe it should be disabled by default, or turned into a
> module option?

The adaptivity patch is to detect signal energy and stop to transmit if the
energy is over a threshold, and I think the USB 3.0 interference does.
I will discuss internally how we can debug this symptom.

--
Ping-Ke

2022-01-06 18:00:13

by Alper Nebi Yasak

[permalink] [raw]
Subject: Re: rtw88: EDCCA makes Wi-Fi unusable with a USB 3.0 SSD connected

On 06/01/2022 08:53, Pkshih wrote:
> I think you have sorted the problem that USB 3.0 is the interference source.
> Since the clock of USB 3.0 is 2.5G, so please try to connect a 5G AP to see if the
> problem is still existing.

I don't have a standalone modem/router that can use 5GHz, but I managed
to create an AP from another laptop and connect to it. Pinging the
second laptop works fine at 5GHz (but pings are still late/dropped at
2.4GHz as expected).

> The adaptivity patch is to detect signal energy and stop to transmit if the
> energy is over a threshold, and I think the USB 3.0 interference does.
> I will discuss internally how we can debug this symptom.

Thanks, feel free to ask for more information or testing if you need it.