]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
can: gs_usb: gs_usb_receive_bulk_callback(): fix error message
authorMarc Kleine-Budde <mkl@pengutronix.de>
Tue, 20 Jan 2026 09:40:22 +0000 (10:40 +0100)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Fri, 23 Jan 2026 17:16:37 +0000 (18:16 +0100)
commit494fc029f662c331e06b7c2031deff3c64200eed
treec0fd7b413b7b79f6966328cd19ad0e138a83ee27
parent0baa4d3170d72a2a8dc93bf729d6d04ad113dc72
can: gs_usb: gs_usb_receive_bulk_callback(): fix error message

Sinc commit 79a6d1bfe114 ("can: gs_usb: gs_usb_receive_bulk_callback():
unanchor URL on usb_submit_urb() error") a failing resubmit URB will print
an info message.

In the case of a short read where netdev has not yet been assigned,
initialize as NULL to avoid dereferencing an undefined value. Also report
the error value of the failed resubmit.

Fixes: 79a6d1bfe114 ("can: gs_usb: gs_usb_receive_bulk_callback(): unanchor URL on usb_submit_urb() error")
Reported-by: Jakub Kicinski <kuba@kernel.org>
Closes: https://lore.kernel.org/all/20260119181904.1209979-1-kuba@kernel.org/
Link: https://patch.msgid.link/20260120-gs_usb-fix-error-message-v1-1-6be04de572bc@pengutronix.de
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/usb/gs_usb.c