From: netdev-bot+sashiko@kernel.org
To: mkl@pengutronix.de
Cc: netdev@vger.kernel.org, davem@davemloft.net, kuba@kernel.org,
linux-can@vger.kernel.org, kernel@pengutronix.de,
shuangpeng.kernel@gmail.com, stable@vger.kernel.org,
vadim.fedorenko@linux.dev
Subject: Re: [PATCH net-next 8/9] can: gs_usb: gs_usb_receive_bulk_callback(): use dev_info_ratelimited() to print re-submit info messages
Date: Tue, 01 Dec 2026 09:41:30 +0000 [thread overview]
Message-ID: <179611809021.3146.12955719357828172247@kernel.org> (raw)
In-Reply-To: <20261130092003.1946901-9-mkl@pengutronix.de>
Thank you for your contribution! Sashiko AI review found more severe
issue(s) in other patches of this series. This mail is only an FYI, in case
you want to address the nit picks below when you respin.
Low priority / nit picks for your consideration:
- [Low] The commit "can: gs_usb: gs_usb_receive_bulk_callback(): use
dev_info_ratelimited() to print re-submit info messages" fixes a…
--
can: gs_usb: gs_usb_receive_bulk_callback(): use dev_info_ratelimited() to print re-submit info messages
When re-submitting the IN URB fails in gs_usb_receive_bulk_callback(),
the message is now printed with dev_info_ratelimited() on the USB device.
It used to go through net_ratelimit() and netdev_info(). This avoids
logging against a NULL net_device when the URB is resubmitted before the
netdev is known, and it drops the NULL initialization of netdev.
Link: https://patch.msgid.link/20261130-gs_usb-fixes-v12-8-9ba1f84c179a@pengutronix.de
> diff --git a/drivers/net/can/usb/gs_usb.c b/drivers/net/can/usb/gs_usb.c
> index 2b23246fb8ebd..10769296c6e0b 100644
> --- a/drivers/net/can/usb/gs_usb.c
> +++ b/drivers/net/can/usb/gs_usb.c
[ ... ]
> @@ -797,9 +797,10 @@ static void gs_usb_receive_bulk_callback(struct urb *urb)
> if (parent->canch[rc])
> netif_device_detach(parent->canch[rc]->netdev);
> }
> - } else if (rc != -ESHUTDOWN && net_ratelimit()) {
> - netdev_info(netdev, "failed to re-submit IN URB: %pe\n",
> - ERR_PTR(rc));
> + } else if (rc != -ESHUTDOWN) {
> + dev_info_ratelimited(&parent->udev->dev,
> + "failed to re-submit IN URB: %pe\n",
> + ERR_PTR(rc));
> }
> }
[Severity: Low]
This patch fixes a reported problem and has Reported-by: and Closes:
tags, but it has no Fixes: tag. Should one be added?
The NULL netdev case comes from the early header length check in
gs_usb_receive_bulk_callback(), which commit 6fe9f3279f7d added:
minimum_length = sizeof(hf->header);
if (urb->actual_length < minimum_length) {
dev_err_ratelimited(&parent->udev->dev,
"short read (actual_length=%u, minimum_length=%u)\n",
urb->actual_length, minimum_length);
goto resubmit_urb;
}
This goto reaches resubmit_urb before netdev = dev->netdev runs. If
usb_submit_urb() then fails with an error other than -ENODEV or
-ESHUTDOWN, the old netdev_info() call logged "(NULL net_device)".
Before 6fe9f3279f7d, every goto resubmit_urb ran after netdev was
assigned.
Commit 6fe9f3279f7d has its own Fixes: tag, so stable trees may pick it
up. Without a Fixes: tag here, those trees could miss this follow-up.
Would this tag fit?
Fixes: 6fe9f3279f7d ("can: gs_usb: gs_usb_receive_bulk_callback(): check actual_length before accessing header")
--
Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261130092003.1946901-2-mkl%40pengutronix.de
next prev parent reply other threads:[~2026-12-01 9:41 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-30 9:15 [PATCH net-next 0/9] pull-request: can-next 2026-11-30 Marc Kleine-Budde
2026-11-30 9:15 ` [PATCH net-next 1/9] can: gs_usb: gs_usb_probe(): init netdev completely before register_candev() Marc Kleine-Budde
2026-11-30 9:23 ` netdev-bot+sinfo
2026-11-30 20:34 ` Marc Kleine-Budde
2026-12-01 9:41 ` netdev-bot+sashiko
2026-11-30 9:15 ` [PATCH net-next 2/9] can: gs_usb: gs_usb_receive_bulk_callback(): update state even if SKB allocations fails Marc Kleine-Budde
2026-11-30 9:15 ` [PATCH net-next 3/9] can: gs_usb: gs_usb_receive_bulk_callback(): check for overflow flag if SKB allocation fails Marc Kleine-Budde
2026-11-30 9:15 ` [PATCH net-next 4/9] can: gs_usb: gs_usb_receive_bulk_callback(): add missing call to can_rx_offload_irq_finish Marc Kleine-Budde
2026-12-01 9:20 ` sashiko-bot
2026-11-30 9:15 ` [PATCH net-next 5/9] can: gs_usb: fix hardware timestamp state for mixed channels Marc Kleine-Budde
2026-11-30 9:15 ` [PATCH net-next 6/9] can: gs_usb: add support for context analysis Marc Kleine-Budde
2026-11-30 9:15 ` [PATCH net-next 7/9] can: gs_usb: gs_make_candev(): check can_rx_offload_add_manual() return value Marc Kleine-Budde
2026-11-30 9:15 ` [PATCH net-next 8/9] can: gs_usb: gs_usb_receive_bulk_callback(): use dev_info_ratelimited() to print re-submit info messages Marc Kleine-Budde
2026-12-01 9:41 ` netdev-bot+sashiko [this message]
2026-11-30 9:15 ` [PATCH net-next 9/9] can: gs_usb: gs_usb_receive_bulk_callback(): emit error message on invalid channel instead of disconnecting interfaces Marc Kleine-Budde
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=179611809021.3146.12955719357828172247@kernel.org \
--to=netdev-bot+sashiko@kernel.org \
--cc=davem@davemloft.net \
--cc=kernel@pengutronix.de \
--cc=kuba@kernel.org \
--cc=linux-can@vger.kernel.org \
--cc=mkl@pengutronix.de \
--cc=netdev@vger.kernel.org \
--cc=shuangpeng.kernel@gmail.com \
--cc=stable@vger.kernel.org \
--cc=vadim.fedorenko@linux.dev \
/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