FAILED: patch "[PATCH] can: gs_usb: gs_usb_receive_bulk_callback(): resubmit URB on" failed to apply to 6.1-stable tree
Subsystems (2)
[email protected]
maintainerThe patch below does not apply to the 6.1-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.
To reproduce the conflict and resubmit, you may use the following commands:
git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.1.y
git checkout FETCH_HEAD
git cherry-pick -x 68c5724ecd159992f76edb7b57dc508a44c8b7da
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2026080558-reassign-construct-c82a@gregkh' --subject-prefix 'PATCH 6.1.y' 'HEAD^..'
Possible dependencies:
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
From 68c5724ecd159992f76edb7b57dc508a44c8b7da Mon Sep 17 00:00:00 2001
From: Marc Kleine-Budde <[email protected]>
Date: Thu, 9 Jul 2026 09:54:26 +0200
Subject: [PATCH] can: gs_usb: gs_usb_receive_bulk_callback(): resubmit URB on
skb allocation failure
If the allocation of the SKB in gs_usb_receive_bulk_callback() fails, the driver returns from the callback without resubmitting the URB in order to receive further USB in URBs.
This results in a silent performance degradation which, if it occurs repeatedly, results in starvation of USB in traffic.
Instead of returning immediately, try to resend the URB. If this also fails, this is logged as an info message.
drivers/net/can/usb/gs_usb.c +2 -2
@@ -674,7 +674,7 @@ static void gs_usb_receive_bulk_callback(struct urb *urb)if (hf->flags &GS_CAN_FLAG_FD ) { skb =alloc_canfd_skb (netdev, &cfd);if (!skb) -return ; + goto resubmit_urb; cfd->can_id =le32_to_cpu (hf->can_id); cfd->len = data_length;
@@ -687,7 +687,7 @@ static void gs_usb_receive_bulk_callback(struct urb *urb) }else { skb =alloc_can_skb (netdev, &cf);if (!skb) -return ; + goto resubmit_urb; cf->can_id =le32_to_cpu (hf->can_id);can_frame_set_cc_len (cf, hf->can_dlc, dev->can.ctrlmode);
Sasha Levin
maintainerPATCH 1/1 can: gs_usb: gs_usb_receive_bulk_callback(): resubmit URB on skb allocation failure
From: Marc Kleine-Budde <[email protected]>
[ Upstream commit 68c5724ecd159992f76edb7b57dc508a44c8b7da ]
If the allocation of the SKB in gs_usb_receive_bulk_callback() fails, the driver returns from the callback without resubmitting the URB in order to receive further USB in URBs.
This results in a silent performance degradation which, if it occurs repeatedly, results in starvation of USB in traffic.
Instead of returning immediately, try to resend the URB. If this also fails, this is logged as an info message.
--- drivers/net/can/usb/gs_usb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/net/can/usb/gs_usb.c +2 -2
@@ -574,7 +574,7 @@ static void gs_usb_receive_bulk_callback(struct urb *urb)if (hf->flags &GS_CAN_FLAG_FD ) { skb =alloc_canfd_skb (dev->netdev, &cfd);if (!skb) -return ; + goto resubmit_urb; cfd->can_id =le32_to_cpu (hf->can_id); cfd->len =can_fd_dlc2len (hf->can_dlc);
@@ -587,7 +587,7 @@ static void gs_usb_receive_bulk_callback(struct urb *urb) }else { skb =alloc_can_skb (dev->netdev, &cf);if (!skb) -return ; + goto resubmit_urb; cf->can_id =le32_to_cpu (hf->can_id);can_frame_set_cc_len (cf, hf->can_dlc, dev->can.ctrlmode);
Signature · 1 line
2.53.0