Skip to content

Commit

Permalink
can: gs_usb: gs_usb_disconnect(): remove not needed usb_kill_anchored…
Browse files Browse the repository at this point in the history
…_urbs()

In gs_usb_disconnect(), all channels are destroyed first, then all
anchored RX URBs (parent->rx_submitted) are disposed with
usb_kill_anchored_urbs().

The call to usb_kill_anchored_urbs() is not needed, as
gs_destroy_candev() of the last active channel already disposes the RX
URBS.

Remove not needed call to usb_kill_anchored_urbs() from
gs_usb_disconnect().

Link: https://lore.kernel.org/all/20230718-gs_usb-cleanups-v1-11-c3b9154ec605@pengutronix.de
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
  • Loading branch information
Marc Kleine-Budde committed Jul 28, 2023
1 parent 5391e0c commit d4cfb83
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion drivers/net/can/usb/gs_usb.c
Original file line number Diff line number Diff line change
Expand Up @@ -1471,7 +1471,6 @@ static void gs_usb_disconnect(struct usb_interface *intf)
if (parent->canch[i])
gs_destroy_candev(parent->canch[i]);

usb_kill_anchored_urbs(&parent->rx_submitted);
kfree(parent);
}

Expand Down

0 comments on commit d4cfb83

Please sign in to comment.