Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp330755rdg; Thu, 12 Oct 2023 07:02:20 -0700 (PDT) X-Google-Smtp-Source: AGHT+IH5ov/5NlSWP87jkoOySFO0wYd6FP3DbRb0kUf8T3ActjuY1m26phbbn58g2ydOJM9g5V7K X-Received: by 2002:a17:90a:d906:b0:27d:1df4:26f3 with SMTP id c6-20020a17090ad90600b0027d1df426f3mr2297982pjv.15.1697119339648; Thu, 12 Oct 2023 07:02:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697119339; cv=none; d=google.com; s=arc-20160816; b=x7fAiaMbunPhApy3zb1LoURck2E/Taeh8Wvj9aM4b0e0IehKkl+NTz4T7NcizwaHNb qwlqDfFm/InMc0EMWnnPBEHGivGqZ8u+q6S0MZ4bxM5MSEWG1JOVhnVRcmaAlcdBbQu3 l4vnv4u+0UjORZ9TEqAjYYUHeja5xMZoxVoFgrilI1o/cAYBBQE4TqaV8GV2hsc4azhE 9UCfpRBVQWCJx2qqyscGIZ8jelrZnUcMM7OZiv5n/muurEBLfRTckYgcPSmV6iel89ku JSzu7UVCmC8URJx+RxGEzcny03Y8IDvWtJPGZLJCqTMv57l+N61kxDE7WlnoDYc+EnrV rxxQ== 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 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=jmu.edu.cn Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [2620:137:e000::3:3]) by mx.google.com with ESMTPS id g10-20020a63dd4a000000b005a1d88169casi2276613pgj.189.2023.10.12.07.02.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 12 Oct 2023 07:02:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) client-ip=2620:137:e000::3:3; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 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 3657480C875B; Thu, 12 Oct 2023 07:02:15 -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 S1343965AbjJLOBu (ORCPT + 99 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 ); 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 ; 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 To: Ping-Ke Shih Cc: Kalle Valo , linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org, Chukun Pan 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: 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:15 -0700 (PDT) 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 --- drivers/net/wireless/realtek/rtw88/rtw8822b.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) 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); -- 2.25.1