]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.18-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 13 Jan 2018 17:47:00 +0000 (18:47 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 13 Jan 2018 17:47:00 +0000 (18:47 +0100)
added patches:
revert-can-kvaser_usb-free-buf-in-error-paths.patch

queue-3.18/revert-can-kvaser_usb-free-buf-in-error-paths.patch [new file with mode: 0644]
queue-3.18/series

diff --git a/queue-3.18/revert-can-kvaser_usb-free-buf-in-error-paths.patch b/queue-3.18/revert-can-kvaser_usb-free-buf-in-error-paths.patch
new file mode 100644 (file)
index 0000000..7c63c4a
--- /dev/null
@@ -0,0 +1,37 @@
+From 66d409a60bcf1504ba6f0021cd0be58d93491197 Mon Sep 17 00:00:00 2001
+From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+Date: Sat, 13 Jan 2018 18:45:25 +0100
+Subject: [PATCH] Revert "can: kvaser_usb: free buf in error paths"
+
+From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+This reverts commit 70d9dccf50152b0d7bfb2697d8c51e9fab9f782c which was
+commit 435019b48033138581a6171093b181fc6b4d3d30 upstream.
+
+Jimmy Assarsson asks that it be reverted as it's not correct there.
+
+Reported-by: Jimmy Assarsson <jimmyassarsson@gmail.com>
+Cc: Marc Kleine-Budde <mkl@pengutronix.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/net/can/usb/kvaser_usb.c |    2 --
+ 1 file changed, 2 deletions(-)
+
+--- a/drivers/net/can/usb/kvaser_usb.c
++++ b/drivers/net/can/usb/kvaser_usb.c
+@@ -602,7 +602,6 @@ static int kvaser_usb_simple_msg_async(s
+       if (err) {
+               netdev_err(netdev, "Error transmitting URB\n");
+               usb_unanchor_urb(urb);
+-              kfree(buf);
+               usb_free_urb(urb);
+               kfree(buf);
+               return err;
+@@ -1389,7 +1388,6 @@ static netdev_tx_t kvaser_usb_start_xmit
+               atomic_dec(&priv->active_tx_urbs);
+               usb_unanchor_urb(urb);
+-              kfree(buf);
+               stats->tx_dropped++;
index 278da41878c893cf053cd535e188f7c5061bf6ca..e7da8d3bd18e57239b36ef2b75244a5a00343c95 100644 (file)
@@ -34,3 +34,4 @@ crypto-algapi-fix-null-dereference-in-crypto_remove_spawns.patch
 x86-microcode-intel-extend-bdw-late-loading-with-a-revision-check.patch
 iscsi-target-make-task_reassign-use-proper-se_cmd-cmd_kref.patch
 target-avoid-early-cmd_t_pre_execute-failures-during-abort_task.patch
+revert-can-kvaser_usb-free-buf-in-error-paths.patch