linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Simon Horman <simon.horman@corigine.com>
To: Sascha Hauer <s.hauer@pengutronix.de>
Cc: linux-wireless <linux-wireless@vger.kernel.org>,
	Hans Ulli Kroll <linux@ulli-kroll.de>,
	Larry Finger <Larry.Finger@lwfinger.net>,
	Pkshih <pkshih@realtek.com>, Tim K <tpkuester@gmail.com>,
	"Alex G ." <mr.nuke.me@gmail.com>,
	Nick Morrow <morrownr@gmail.com>,
	Viktor Petrenko <g0000ga@gmail.com>,
	Andreas Henriksson <andreas@fatal.se>,
	ValdikSS <iam@valdikss.org.ru>,
	kernel@pengutronix.de, petter@technux.se
Subject: Re: [PATCH] wifi: rtw88: usb: silence log flooding error message
Date: Wed, 24 May 2023 13:34:52 +0200	[thread overview]
Message-ID: <ZG32XKBsAub+Y+bO@corigine.com> (raw)
In-Reply-To: <20230524103934.1019096-1-s.hauer@pengutronix.de>

On Wed, May 24, 2023 at 12:39:34PM +0200, Sascha Hauer wrote:
> When receiving more rx packets than the kernel can handle the driver
> drops the packets and issues an error message. This is bad for two
> reasons. The logs are flooded with myriads of messages, but then time
> consumed for printing messages in that critical code path brings down
> the device. After some time of excessive rx load the driver responds
> with:
> 
> rtw_8822cu 1-1:1.2: failed to get tx report from firmware
> rtw_8822cu 1-1:1.2: firmware failed to report density after scan
> rtw_8822cu 1-1:1.2: firmware failed to report density after scan
> 
> The device stops working until being replugged.
> 
> Fix this by lowering the priority to debug level and also by
> ratelimiting it.
> 
> Fixes: a82dfd33d1237 ("wifi: rtw88: Add common USB chip support")
> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
> ---
>  drivers/net/wireless/realtek/rtw88/usb.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/wireless/realtek/rtw88/usb.c b/drivers/net/wireless/realtek/rtw88/usb.c
> index 44a5fafb99055..976eafa739a2d 100644
> --- a/drivers/net/wireless/realtek/rtw88/usb.c
> +++ b/drivers/net/wireless/realtek/rtw88/usb.c
> @@ -535,7 +535,7 @@ static void rtw_usb_rx_handler(struct work_struct *work)
>  		}
>  
>  		if (skb_queue_len(&rtwusb->rx_queue) >= RTW_USB_MAX_RXQ_LEN) {
> -			rtw_err(rtwdev, "failed to get rx_queue, overflow\n");
> +			dev_dbg_ratelimited(rtwdev->dev, "failed to get rx_queue, overflow\n");

This is certainly an improvement. But as I understand things
it is still somewhat verbose if the condition persists.
Did you consider dev_dbg_once()?

>  			dev_kfree_skb_any(skb);
>  			continue;
>  		}
> -- 
> 2.39.2
> 

  reply	other threads:[~2023-05-24 11:35 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-24 10:39 [PATCH] wifi: rtw88: usb: silence log flooding error message Sascha Hauer
2023-05-24 11:34 ` Simon Horman [this message]
2023-05-26 10:17   ` Sascha Hauer
2023-05-30 19:59     ` Simon Horman
2023-05-25  0:45 ` Ping-Ke Shih
2023-05-26  9:33   ` Sascha Hauer
2023-05-26 11:34     ` Ping-Ke Shih
2023-05-27  8:31 ` Kalle Valo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZG32XKBsAub+Y+bO@corigine.com \
    --to=simon.horman@corigine.com \
    --cc=Larry.Finger@lwfinger.net \
    --cc=andreas@fatal.se \
    --cc=g0000ga@gmail.com \
    --cc=iam@valdikss.org.ru \
    --cc=kernel@pengutronix.de \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linux@ulli-kroll.de \
    --cc=morrownr@gmail.com \
    --cc=mr.nuke.me@gmail.com \
    --cc=petter@technux.se \
    --cc=pkshih@realtek.com \
    --cc=s.hauer@pengutronix.de \
    --cc=tpkuester@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).