]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.10-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 11 Oct 2013 16:12:31 +0000 (09:12 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 11 Oct 2013 16:12:31 +0000 (09:12 -0700)
added patches:
bcache-fix-a-null-ptr-deref-regression.patch

queue-3.10/bcache-fix-a-null-ptr-deref-regression.patch [new file with mode: 0644]
queue-3.10/series

diff --git a/queue-3.10/bcache-fix-a-null-ptr-deref-regression.patch b/queue-3.10/bcache-fix-a-null-ptr-deref-regression.patch
new file mode 100644 (file)
index 0000000..43989e5
--- /dev/null
@@ -0,0 +1,41 @@
+From 2fe80d3bbf1c8bd9efc5b8154207c8dd104e7306 Mon Sep 17 00:00:00 2001
+From: Kent Overstreet <kmo@daterainc.com>
+Date: Thu, 10 Oct 2013 17:31:15 -0700
+Subject: bcache: Fix a null ptr deref regression
+
+From: Kent Overstreet <kmo@daterainc.com>
+
+commit 2fe80d3bbf1c8bd9efc5b8154207c8dd104e7306 upstream.
+
+Commit c0f04d88e46d ("bcache: Fix flushes in writeback mode") was fixing
+a reported data corruption bug, but it seems some last minute
+refactoring or rebasing introduced a null pointer deref.
+
+Signed-off-by: Kent Overstreet <kmo@daterainc.com>
+Reported-by: Gabriel de Perthuis <g2p.code@gmail.com>
+Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/md/bcache/request.c |    3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+--- a/drivers/md/bcache/request.c
++++ b/drivers/md/bcache/request.c
+@@ -1055,6 +1055,7 @@ static void request_write(struct cached_
+       } else {
+               trace_bcache_writeback(s->orig_bio);
+               bch_writeback_add(dc, bio_sectors(bio));
++              s->op.cache_bio = bio;
+               if (bio->bi_rw & REQ_FLUSH) {
+                       /* Also need to send a flush to the backing device */
+@@ -1067,8 +1068,6 @@ static void request_write(struct cached_
+                       flush->bi_private = cl;
+                       closure_bio_submit(flush, cl, s->d);
+-              } else {
+-                      s->op.cache_bio = bio;
+               }
+       }
+ out:
index 530fc1286d42082f55c8ab22015caeb1776411e8..b06412f23067523fecc50bf52ca76ced4d6b3240 100644 (file)
@@ -108,3 +108,4 @@ hid-roccat-add-support-for-konepureoptical-v2.patch
 hid-uhid-add-devname-module-alias.patch
 hid-uhid-allocate-static-minor.patch
 net-qmi_wwan-add-new-qualcomm-devices.patch
+bcache-fix-a-null-ptr-deref-regression.patch