]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.4-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 13 Dec 2019 17:38:30 +0000 (18:38 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 13 Dec 2019 17:38:30 +0000 (18:38 +0100)
added patches:
usb-gadget-configfs-fix-missing-spin_lock_init.patch

queue-4.4/series
queue-4.4/usb-gadget-configfs-fix-missing-spin_lock_init.patch [new file with mode: 0644]
queue-5.3/series [new file with mode: 0644]
queue-5.4/series [new file with mode: 0644]

index 375a5ceb65907d03513ad1204ce8f46dcc9589b6..edf0adeee3404667a0eca8c3048237e7b40943c6 100644 (file)
@@ -79,3 +79,4 @@ fs-proc-stop-reporting-eip-and-esp-in-proc-pid-stat.patch
 fs-proc-report-eip-esp-in-prod-pid-stat-for-coredumping.patch
 proc-fix-coredump-vs-read-proc-stat-race.patch
 fs-proc-array.c-allow-reporting-eip-esp-for-all-coredumping-threads.patch
+usb-gadget-configfs-fix-missing-spin_lock_init.patch
diff --git a/queue-4.4/usb-gadget-configfs-fix-missing-spin_lock_init.patch b/queue-4.4/usb-gadget-configfs-fix-missing-spin_lock_init.patch
new file mode 100644 (file)
index 0000000..77f5f88
--- /dev/null
@@ -0,0 +1,35 @@
+From 093edc2baad2c258b1f55d1ab9c63c2b5ae67e42 Mon Sep 17 00:00:00 2001
+From: Wei Yongjun <weiyongjun1@huawei.com>
+Date: Wed, 30 Oct 2019 03:40:46 +0000
+Subject: usb: gadget: configfs: Fix missing spin_lock_init()
+
+From: Wei Yongjun <weiyongjun1@huawei.com>
+
+commit 093edc2baad2c258b1f55d1ab9c63c2b5ae67e42 upstream.
+
+The driver allocates the spinlock but not initialize it.
+Use spin_lock_init() on it to initialize it correctly.
+
+This is detected by Coccinelle semantic patch.
+
+Fixes: 1a1c851bbd70 ("usb: gadget: configfs: fix concurrent issue between composite APIs")
+Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
+Cc: stable <stable@vger.kernel.org>
+Reviewed-by: Peter Chen <peter.chen@nxp.com>
+Link: https://lore.kernel.org/r/20191030034046.188808-1-weiyongjun1@huawei.com
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/usb/gadget/configfs.c |    1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/drivers/usb/gadget/configfs.c
++++ b/drivers/usb/gadget/configfs.c
+@@ -1542,6 +1542,7 @@ static struct config_group *gadgets_make
+       gi->composite.resume = NULL;
+       gi->composite.max_speed = USB_SPEED_SUPER;
++      spin_lock_init(&gi->spinlock);
+       mutex_init(&gi->lock);
+       INIT_LIST_HEAD(&gi->string_list);
+       INIT_LIST_HEAD(&gi->available_func);
diff --git a/queue-5.3/series b/queue-5.3/series
new file mode 100644 (file)
index 0000000..9b04749
--- /dev/null
@@ -0,0 +1,2 @@
+usb-gadget-configfs-fix-missing-spin_lock_init.patch
+usb-gadget-pch_udc-fix-use-after-free.patch
diff --git a/queue-5.4/series b/queue-5.4/series
new file mode 100644 (file)
index 0000000..9b04749
--- /dev/null
@@ -0,0 +1,2 @@
+usb-gadget-configfs-fix-missing-spin_lock_init.patch
+usb-gadget-pch_udc-fix-use-after-free.patch