Received: by 2002:a05:6500:1b45:b0:1f5:f2ab:c469 with SMTP id cz5csp979295lqb; Wed, 17 Apr 2024 17:29:41 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXSxBQn+zIZl9vhUvfkTfRUW4Q5bhvQibvn5gxdboj/6d5IPuSqFwM//WTKrogTOZe56tdhj5uJzOX8y137DkOtNbSqV6j8f93Va5TUOg== X-Google-Smtp-Source: AGHT+IEq3kzxMXIVMlN9drflm6LFreLaiNm4g55e9ZePS/8+QwkGxYwpPNmEujoiI4vGHSTlKGN8 X-Received: by 2002:a17:90a:4894:b0:2a5:4d59:950e with SMTP id b20-20020a17090a489400b002a54d59950emr992922pjh.27.1713400180788; Wed, 17 Apr 2024 17:29:40 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713400180; cv=pass; d=google.com; s=arc-20160816; b=G7F/LngpayLq5kNY77VC081LnNnJto5kmVVGYBNih0AH/vK1GPHmp3em/khsalSGVS 1uFRaQfEM6EAojQg2s7v5F//Myz6Gq/61QpbZR7B7qnlbcDsnE4fF51xCEbwW4Lp9d9e IKsqD4hhnPeH0xDQ0jO75jhmylzSij7yWpZHv0PJ6ZMm/hhTBqRSA82x8/8MUNYzTbHs saNWLdibN6H9m4f7VR7BIMi/Y/kT/Qgz9Unt8FINJ4iKTEV86o+RX70f0KiJQYmtVPpV w+9DWqEYqHoqFbK48S2kQZRYUKFz4zXOW7pjpEht4wnlQLT4zCq6RY+0kvHvLrNQCQEZ 63JQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from; bh=Binb6EN5Irfk4CU/+iiq8Lo4kc/u/ZLdhX8u94Ln4ac=; fh=LtQnubVPZKRsfSoE/cEmqA5ZquQaeNYe+Q0VHCzkEvc=; b=mWD8CR2J6z4ZJXnxmcLSyQl9mAyhkY7BSD2ovLrq2KqgwG/gppGU9KVJ2Oezg6maNi TM11Sx58O1hxkH3Fpha11m1F97O54ExFDTsROXShBVYy68OIQAqF99CGKhCcn8pFEdry LfeBx1B9IQo3Dq8oeWWbqPlhaN2SuRboQ6iY1V6gaS9o3Wp+TkX1yyAx6AXenhkH6QBY scxh3Y7xai3w4pLwtimR2Fch5VfW/qfUIG0l/ryToU6G5xc5uIh1gLJLwnm7c0+SYmyE b6ycGFR5+vKKE7wdRQixwCw1pMvNBmxa/GViohB3PJrhom1N6DrBcGXtw00tNp29Poof 8y8g==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=realtek.com); spf=pass (google.com: domain of linux-wireless+bounces-6471-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-6471-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id pg18-20020a17090b1e1200b002a29b882714si2150985pjb.187.2024.04.17.17.29.40 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Apr 2024 17:29:40 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless+bounces-6471-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=realtek.com); spf=pass (google.com: domain of linux-wireless+bounces-6471-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-6471-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 342F5B21DC4 for ; Thu, 18 Apr 2024 00:29:37 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 7CEBD628; Thu, 18 Apr 2024 00:29:33 +0000 (UTC) X-Original-To: linux-wireless@vger.kernel.org Received: from rtits2.realtek.com.tw (rtits2.realtek.com [211.75.126.72]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5BE32382 for ; Thu, 18 Apr 2024 00:29:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=211.75.126.72 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713400173; cv=none; b=oVZY1r9k7Dn2ywA2YdkEAKgbX9LIaduz5zm8J737XOerQj2NO12tIsMdVufbFUJ4n4P9oDPI2HvUnXH1Zj8Z9fcOrD8RfkrcouJWWNT5Y7yxtFnwICO/gv8x1MNSWD2SO5o2fG8bDglj0Lv/QhM1iOLU/+MYur93f+eB7vc/sIU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713400173; c=relaxed/simple; bh=zghP/jhQX2RjmR5Z+BVeRuSQhQKlB+FrGMUouwN0KGA=; h=From:To:CC:Subject:Date:Message-ID:MIME-Version:Content-Type; b=fLUE85N+vifyMcpITMZsuhNvUnj1dWBb3fJFK3ggjjgUzxdbVYDBhdHD9mizqlBxB6iDo79I5r8CZbFZYTI37fZysCabIHevHGCXFObpwMZTgvpIwW0UailXcjHCgBM+vq0aReEnRIDCL7lcRLKmuNM0PX7vKE1HL6fxWcsBZnQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=realtek.com; spf=pass smtp.mailfrom=realtek.com; arc=none smtp.client-ip=211.75.126.72 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=realtek.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=realtek.com X-SpamFilter-By: ArmorX SpamTrap 5.78 with qID 43I0TQpoC3883303, This message is accepted by code: ctloc85258 Received: from mail.realtek.com (rtexh36505.realtek.com.tw[172.21.6.25]) by rtits2.realtek.com.tw (8.15.2/2.95/5.92) with ESMTPS id 43I0TQpoC3883303 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 18 Apr 2024 08:29:26 +0800 Received: from RTEXMBS04.realtek.com.tw (172.21.6.97) by RTEXH36505.realtek.com.tw (172.21.6.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.35; Thu, 18 Apr 2024 08:29:26 +0800 Received: from [127.0.1.1] (172.21.69.94) by RTEXMBS04.realtek.com.tw (172.21.6.97) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.35; Thu, 18 Apr 2024 08:29:26 +0800 From: Ping-Ke Shih To: CC: Subject: [PATCH v2] wifi: rtw88: suppress messages of failed to flush queue Date: Thu, 18 Apr 2024 08:29:16 +0800 Message-ID: <20240418002916.5965-1-pkshih@realtek.com> X-Mailer: git-send-email 2.25.1 Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: RTEXMBS02.realtek.com.tw (172.21.6.95) To RTEXMBS04.realtek.com.tw (172.21.6.97) X-KSE-ServerInfo: RTEXH36505.realtek.com.tw, 9 X-KSE-AntiSpam-Interceptor-Info: fallback X-KSE-Antivirus-Interceptor-Info: fallback X-KSE-AntiSpam-Interceptor-Info: fallback Driver throws messages when scanning with a lot of traffic, because packets in TX buffer can not be transmitted in time. Since this is a common occurrence, change them to debug message with special debug mask that developers can turn on this mask by default for further analysis. Cc: Lewis Robbins Tested-by: Lewis Robbins Signed-off-by: Ping-Ke Shih --- v2: modify comment along with changes --- drivers/net/wireless/realtek/rtw88/debug.h | 1 + drivers/net/wireless/realtek/rtw88/mac.c | 5 +++-- drivers/net/wireless/realtek/rtw88/pci.c | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/drivers/net/wireless/realtek/rtw88/debug.h b/drivers/net/wireless/realtek/rtw88/debug.h index f20c0471c82a..eb69006c463e 100644 --- a/drivers/net/wireless/realtek/rtw88/debug.h +++ b/drivers/net/wireless/realtek/rtw88/debug.h @@ -26,6 +26,7 @@ enum rtw_debug_mask { RTW_DBG_STATE = 0x00020000, RTW_DBG_SDIO = 0x00040000, + RTW_DBG_UNEXP = 0x80000000, RTW_DBG_ALL = 0xffffffff }; diff --git a/drivers/net/wireless/realtek/rtw88/mac.c b/drivers/net/wireless/realtek/rtw88/mac.c index 699ae3048c6b..0dba8aae7716 100644 --- a/drivers/net/wireless/realtek/rtw88/mac.c +++ b/drivers/net/wireless/realtek/rtw88/mac.c @@ -1039,14 +1039,15 @@ static void __rtw_mac_flush_prio_queue(struct rtw_dev *rtwdev, msleep(20); } - /* priority queue is still not empty, throw a warning, + /* priority queue is still not empty, throw a debug message * * Note that if we want to flush the tx queue when having a lot of * traffic (ex, 100Mbps up), some of the packets could be dropped. * And it requires like ~2secs to flush the full priority queue. */ if (!drop) - rtw_warn(rtwdev, "timed out to flush queue %d\n", prio_queue); + rtw_dbg(rtwdev, RTW_DBG_UNEXP, + "timed out to flush queue %d\n", prio_queue); } static void rtw_mac_flush_prio_queues(struct rtw_dev *rtwdev, diff --git a/drivers/net/wireless/realtek/rtw88/pci.c b/drivers/net/wireless/realtek/rtw88/pci.c index 9986a4cb37eb..7a093f3d5f74 100644 --- a/drivers/net/wireless/realtek/rtw88/pci.c +++ b/drivers/net/wireless/realtek/rtw88/pci.c @@ -729,7 +729,8 @@ static void __pci_flush_queue(struct rtw_dev *rtwdev, u8 pci_q, bool drop) } if (!drop) - rtw_warn(rtwdev, "timed out to flush pci tx ring[%d]\n", pci_q); + rtw_dbg(rtwdev, RTW_DBG_UNEXP, + "timed out to flush pci tx ring[%d]\n", pci_q); } static void __rtw_pci_flush_queues(struct rtw_dev *rtwdev, u32 pci_queues, -- 2.25.1