2ab1ccee23d3f1f2712b1239b0be245f84fd645d
[openwrt/staging/xback.git] /
1 From fa8914fe29543be586e9bbc00c7209e2808f0a13 Mon Sep 17 00:00:00 2001
2 From: Daniel Golle <daniel@makrotopia.org>
3 Date: Fri, 16 Sep 2022 20:28:40 +0100
4 Subject: [PATCH 12/16] rt2x00: set correct TX_SW_CFG1 MAC register for MT7620
5 To: linux-wireless@vger.kernel.org,
6 Stanislaw Gruszka <stf_xl@wp.pl>,
7 Helmut Schaa <helmut.schaa@googlemail.com>
8 Cc: Kalle Valo <kvalo@kernel.org>,
9 David S. Miller <davem@davemloft.net>,
10 Eric Dumazet <edumazet@google.com>,
11 Jakub Kicinski <kuba@kernel.org>,
12 Paolo Abeni <pabeni@redhat.com>,
13 Johannes Berg <johannes.berg@intel.com>
14
15 Set correct TX_SW_CFG1 MAC register as it is done also in v3 of the
16 vendor driver[1].
17
18 [1]: https://gitlab.com/dm38/padavan-ng/-/blob/master/trunk/proprietary/rt_wifi/rtpci/3.0.X.X/mt76x2/chips/rt6352.c#L531
19 Reported-by: Serge Vasilugin <vasilugin@yandex.ru>
20 Signed-off-by: Daniel Golle <daniel@makrotopia.org>
21 ---
22 drivers/net/wireless/ralink/rt2x00/rt2800lib.c | 2 +-
23 1 file changed, 1 insertion(+), 1 deletion(-)
24
25 --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
26 +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
27 @@ -5934,7 +5934,7 @@ static int rt2800_init_registers(struct
28 rt2800_register_write(rt2x00dev, TX_SW_CFG0, 0x00000404);
29 } else if (rt2x00_rt(rt2x00dev, RT6352)) {
30 rt2800_register_write(rt2x00dev, TX_SW_CFG0, 0x00000401);
31 - rt2800_register_write(rt2x00dev, TX_SW_CFG1, 0x000C0000);
32 + rt2800_register_write(rt2x00dev, TX_SW_CFG1, 0x000C0001);
33 rt2800_register_write(rt2x00dev, TX_SW_CFG2, 0x00000000);
34 rt2800_register_write(rt2x00dev, TX_ALC_VGA3, 0x00000000);
35 rt2800_register_write(rt2x00dev, TX0_BB_GAIN_ATTEN, 0x0);