From: Sascha Hauer <s.hauer@pengutronix.de>
To: Simon Horman <simon.horman@corigine.com>
Cc: Pkshih <pkshih@realtek.com>,
Hans Ulli Kroll <linux@ulli-kroll.de>,
ValdikSS <iam@valdikss.org.ru>,
linux-wireless <linux-wireless@vger.kernel.org>,
Tim K <tpkuester@gmail.com>, Nick Morrow <morrownr@gmail.com>,
Viktor Petrenko <g0000ga@gmail.com>,
"Alex G ." <mr.nuke.me@gmail.com>,
kernel@pengutronix.de, petter@technux.se,
Andreas Henriksson <andreas@fatal.se>,
Larry Finger <Larry.Finger@lwfinger.net>
Subject: Re: [PATCH] wifi: rtw88: usb: silence log flooding error message
Date: Fri, 26 May 2023 12:17:36 +0200 [thread overview]
Message-ID: <20230526101736.GS17518@pengutronix.de> (raw)
In-Reply-To: <ZG32XKBsAub+Y+bO@corigine.com>
On Wed, May 24, 2023 at 01:34:52PM +0200, Simon Horman wrote:
> 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()?
My rationale was that dev_dbg() is normally disabled anyway. With
CONFIG_DYNAMIC_PRINTK you would still have fine grained control if you
want to see this message or not.
Personally I don't care that much, I would switch to dev_dbg_once() if
that's preferred.
Sascha
--
Pengutronix e.K. | |
Steuerwalder Str. 21 | http://www.pengutronix.de/ |
31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
next prev parent reply other threads:[~2023-05-26 10:17 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
2023-05-26 10:17 ` Sascha Hauer [this message]
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=20230526101736.GS17518@pengutronix.de \
--to=s.hauer@pengutronix.de \
--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=simon.horman@corigine.com \
--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).