Message ID | 20231012140120.891411-1-amadeus@jmu.edu.cn |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:612c:2908:b0:403:3b70:6f57 with SMTP id ib8csp1252010vqb; Thu, 12 Oct 2023 07:02:13 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGQ5wBhHRAnUoCicQpM+UkkJhEBtZF8Bnt5RnMaO6+f9gUfgkhGGd2cmR6A6xnHLOu9m6qj X-Received: by 2002:a17:902:d512:b0:1bf:349f:b85c with SMTP id b18-20020a170902d51200b001bf349fb85cmr26767581plg.1.1697119333440; Thu, 12 Oct 2023 07:02:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697119333; cv=none; d=google.com; s=arc-20160816; b=tx6zgV2muuXpIXketYcQpRk8/j96NM9/qluUV2HmOHTXePFxG//wwFchjUlXYOiVwb s/CJ1XlwPruotRVxDRaELiKPt5zZGu10YBBT9i0r3y/tUwbxOLeVb3U0TygPW8QRkMs0 F7PixN8UqD5vomHWRbxuHkd+1gkkRmF4UwJ9GZh2yqFQuVXd6aLVO/sB+GIDj6xEJwju kLjJFrl4klueQMYuYrlk0T5sQDHiFgNL8gapZkz6pkvYtP9BonLufVSJuFs+fs6/+/gV jzI+UCwqPFWTOMsLfNfw/VYv6An5YaAKLAxN/AhO5NKusDS7/CZlu0G3aeoaPLYq9sGJ Am9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=3fKkrJztXFw7RZQMHdKV2YVwHGtA+rnveiLlvSbiwWk=; fh=zu+P0qdaV7RU5/MaOo+vkC8XGSspPHklujQD5TK7R3c=; b=eajvxAHSGLS5BFeU4bsgt8jwL+vqZKAvhARKFGFSI4c655bnrvju7AKRg6GrglNYAK zIB4r1WhwnEUrfxOkClJycFN9MOS1pqIYKrHGMIJflex6YNi0F/p8YdaY2n4YA9d7bLR bx5vyWbPazNFUWtK7+P2z0/RpKaneH+gxMud3aqrSJKnm8kMmqMIiWm2YPa6/qG/kEPX 0BUYmjiVPK7d8PYSi0n7lI8q5xz2PE/a7hj0QNWXTydeAvfNoTYk/TFSHzZgmir9IGsK IW1JpwgZeUVcL5vHOw7V+AK3ZJQojhA/3LrvbcAt15erdvlg8Lnsqw3cSC8f8FrjmOKH kq8w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=jmu.edu.cn Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id d9-20020a170902cec900b001c7316f26a0si2442683plg.516.2023.10.12.07.02.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 12 Oct 2023 07:02:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=jmu.edu.cn Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 72B0C825CEDD; Thu, 12 Oct 2023 07:02:05 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344014AbjJLOBu (ORCPT <rfc822;rua109.linux@gmail.com> + 19 others); Thu, 12 Oct 2023 10:01:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44876 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235121AbjJLOBt (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 12 Oct 2023 10:01:49 -0400 Received: from mail-m49198.qiye.163.com (mail-m49198.qiye.163.com [45.254.49.198]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5B8C6B7 for <linux-kernel@vger.kernel.org>; Thu, 12 Oct 2023 07:01:44 -0700 (PDT) Received: from localhost.localdomain (unknown [58.61.141.228]) by mail-m121145.qiye.163.com (Hmail) with ESMTPA id 1A011800080; Thu, 12 Oct 2023 22:01:24 +0800 (CST) From: Chukun Pan <amadeus@jmu.edu.cn> To: Ping-Ke Shih <pkshih@realtek.com> Cc: Kalle Valo <kvalo@kernel.org>, linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org, Chukun Pan <amadeus@jmu.edu.cn> Subject: [PATCH 1/1] wifi: rtw88: 8822b: disable call trace when write RF mode table fail Date: Thu, 12 Oct 2023 22:01:20 +0800 Message-Id: <20231012140120.891411-1-amadeus@jmu.edu.cn> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-HM-Spam-Status: e1kfGhgUHx5ZQUpXWQgPGg8OCBgUHx5ZQUlOS1dZFg8aDwILHllBWSg2Ly tZV1koWUFITzdXWS1ZQUlXWQ8JGhUIEh9ZQVlCTB8fVksdThodSUwfSE0dTVUTARMWGhIXJBQOD1 lXWRgSC1lBWU5DVU1KVUpPSlVJSUNZV1kWGg8SFR0UWUFZT0tIVUpKS0hKQ1VKS0tVS1kG X-HM-Tid: 0a8b24312c1fb03akuuu1a011800080 X-HM-MType: 10 X-HM-Sender-Digest: e1kMHhlZQR0aFwgeV1kSHx4VD1lBWUc6OD46EDo6AjwrTQtONFEjNTkR MhowCwxVSlVKTUJMSkpCSUNPTExLVTMWGhIXVRoWGh8eDgg7ERYOVR4fDlUYFUVZV1kSC1lBWU5D VU1KVUpPSlVJSUNZV1kIAVlBSkJIQjcG X-Spam-Status: No, score=-0.8 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Thu, 12 Oct 2023 07:02:05 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1779558602440317222 X-GMAIL-MSGID: 1779558602440317222 |
Series |
[1/1] wifi: rtw88: 8822b: disable call trace when write RF mode table fail
|
|
Commit Message
Chukun Pan
Oct. 12, 2023, 2:01 p.m. UTC
The rtw88 driver throws a useless Call Trace when the rtl8812bu
or rtl8822be wifi modules fail to write the RF mode table.
Since this does not affect normal use of the wifi modules,
replace WARN() with driver warning to avoid useless panic.
Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
---
drivers/net/wireless/realtek/rtw88/rtw8822b.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
Comments
> -----Original Message----- > From: Chukun Pan <amadeus@jmu.edu.cn> > Sent: Thursday, October 12, 2023 10:01 PM > To: Ping-Ke Shih <pkshih@realtek.com> > Cc: Kalle Valo <kvalo@kernel.org>; linux-wireless@vger.kernel.org; linux-kernel@vger.kernel.org; Chukun > Pan <amadeus@jmu.edu.cn> > Subject: [PATCH 1/1] wifi: rtw88: 8822b: disable call trace when write RF mode table fail > > The rtw88 driver throws a useless Call Trace when the rtl8812bu > or rtl8822be wifi modules fail to write the RF mode table. Why do you think this trace is useless? As I see, there is more than one callers. Did you meet a real case it throws this trace? If yes, how about the frequency? Ping-Ke
Hi, Ping-Ke > Why do you think this trace is useless? As I see, there is more than one callers. > Did you meet a real case it throws this trace? If yes, how about the frequency? [ 217.651858] ------------[ cut here ]------------ [ 217.654813] write RF mode table fail [ 217.657434] WARNING: CPU: 2 PID: 3705 at 0xffffffffa03df3cb [rtw88_8822b@00000000bf0fde9e+0x35000] [ 217.662078] Modules linked in: rtw88_8822ce rtw88_8822c rtw88_8822be rtw88_8822b rtw88_8723de ... [ 217.704412] RIP: 0010:0xffffffffa03df3cb [rtw88_8822b@00000000bf0fde9e+0x35000] ... [ 217.737232] Call Trace: [ 217.738683] 0xffffffffa03df943 [rtw88_8822b@00000000bf0fde9e+0x35000] [ 217.740865] 0xffffffffa0385ab9 [rtw88_core@00000000a8d26f0d+0x1a000] [ 217.742993] 0xffffffffa0279111 [mac80211@000000003cb4b3bd+0x7b000] [ 217.745028] 0xffffffffa0239092 [cfg80211@00000000a951c4b5+0x46000] [ 217.751368] ? 0xffffffffa0238de0 [cfg80211@00000000a951c4b5+0x46000] [ 217.773278] RIP: 0033:0x7ff0cdf8836c ... [ 217.789457] ---[ end trace 177712424e9eab4a ]--- As you can see this trace above, I don't think it's useful. This trace throws up a lot of register values but doesn't point out why. As long as I plug in the rtl8812bu or rtl8822be wifi modules, this trace will be thrown every time when the rtw88 driver is loaded. Thanks, Chukun
Chukun Pan <amadeus@jmu.edu.cn> writes: > Hi, Ping-Ke > >> Why do you think this trace is useless? As I see, there is more than one callers. >> Did you meet a real case it throws this trace? If yes, how about the frequency? > > [ 217.651858] ------------[ cut here ]------------ > [ 217.654813] write RF mode table fail > [ 217.657434] WARNING: CPU: 2 PID: 3705 at 0xffffffffa03df3cb [rtw88_8822b@00000000bf0fde9e+0x35000] > [ 217.662078] Modules linked in: rtw88_8822ce rtw88_8822c rtw88_8822be rtw88_8822b rtw88_8723de ... > [ 217.704412] RIP: 0010:0xffffffffa03df3cb [rtw88_8822b@00000000bf0fde9e+0x35000] > ... > [ 217.737232] Call Trace: > [ 217.738683] 0xffffffffa03df943 [rtw88_8822b@00000000bf0fde9e+0x35000] > [ 217.740865] 0xffffffffa0385ab9 [rtw88_core@00000000a8d26f0d+0x1a000] > [ 217.742993] 0xffffffffa0279111 [mac80211@000000003cb4b3bd+0x7b000] > [ 217.745028] 0xffffffffa0239092 [cfg80211@00000000a951c4b5+0x46000] > [ 217.751368] ? 0xffffffffa0238de0 [cfg80211@00000000a951c4b5+0x46000] > [ 217.773278] RIP: 0033:0x7ff0cdf8836c > ... > [ 217.789457] ---[ end trace 177712424e9eab4a ]--- > > As you can see this trace above, I don't think it's useful. This > trace throws up a lot of register values but doesn't point out why. > As long as I plug in the rtl8812bu or rtl8822be wifi modules, this > trace will be thrown every time when the rtw88 driver is loaded. _Why_ is that warning printed? Are your devices uncalibrated or are they somehow else special?
> _Why_ is that warning printed? Are your devices uncalibrated or are they > somehow else special? I don't know, but not only my rtl8822be wifi module will have this call trace every time when the driver probes. This can be considered a common problem. So I prefer to disable this call trace and use the driver warning instead. Thanks, Chukun
> -----Original Message----- > From: Chukun Pan <amadeus@jmu.edu.cn> > Sent: Sunday, October 22, 2023 5:09 PM > To: kvalo@kernel.org > Cc: Ping-Ke Shih <pkshih@realtek.com>; linux-kernel@vger.kernel.org; linux-wireless@vger.kernel.org; > Chukun Pan <amadeus@jmu.edu.cn> > Subject: RE: [PATCH 1/1] wifi: rtw88: 8822b: disable call trace when write RF mode table fail > > > _Why_ is that warning printed? Are your devices uncalibrated or are they > > somehow else special? > > I don't know, but not only my rtl8822be wifi module will have this call trace > every time when the driver probes. This can be considered a common problem. > So I prefer to disable this call trace and use the driver warning instead. > Except to call trace, rtl8822be works well in your side? If so, you just worry the verbose trace, right? By the way, I tested two hardware version of rtl8822be, and they both are fine. Ping-Ke
Chukun Pan <amadeus@jmu.edu.cn> writes: >> _Why_ is that warning printed? Are your devices uncalibrated or are they >> somehow else special? > > I don't know, but not only my rtl8822be wifi module will have this call trace > every time when the driver probes. This can be considered a common problem. > So I prefer to disable this call trace and use the driver warning instead. Why do you say this is a common problem? AFAIK you are the only one reporting this issue, right? It would help to understand _why_ you are seeing this, ie. what's the root cause? Just randomly removing warnings without understanding the root cause is frowned upon.
> Except to call trace, rtl8822be works well in your side? If so, you just > worry the verbose trace, right? Yes, it's a bit noisy. > By the way, I tested two hardware version of rtl8822be, and they both are fine. Sorry wasted your time, but can you test the rtl8812bu wifi module? Based on the issues search, I'm not the only one who has this problem. https://github.com/lwfinger/rtw88/issues/111#issuecomment-1385923235 https://github.com/lwfinger/rtw88/issues/151#issuecomment-1753011363 Thanks, Chukun
diff --git a/drivers/net/wireless/realtek/rtw88/rtw8822b.c b/drivers/net/wireless/realtek/rtw88/rtw8822b.c index 3017a9760da8..06b6efcd16d2 100644 --- a/drivers/net/wireless/realtek/rtw88/rtw8822b.c +++ b/drivers/net/wireless/realtek/rtw88/rtw8822b.c @@ -820,8 +820,10 @@ static void rtw8822b_config_trx_mode(struct rtw_dev *rtwdev, u8 tx_path, break; } - if (WARN(counter <= 0, "write RF mode table fail\n")) + if (counter <= 0) { + rtw_warn(rtwdev, "write RF mode table fail\n"); return; + } rtw_write_rf(rtwdev, RF_PATH_A, RF_LUTWE, RFREG_MASK, 0x80000); rtw_write_rf(rtwdev, RF_PATH_A, RF_LUTWA, RFREG_MASK, 0x00001);