From: Greg Kroah-Hartman Date: Fri, 11 Oct 2013 16:12:39 +0000 (-0700) Subject: 3.11-stable patches X-Git-Tag: v3.0.100~4 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=cf89d7f17c6d4cf69f3bbf8eb81fb3464597d938;p=thirdparty%2Fkernel%2Fstable-queue.git 3.11-stable patches added patches: bcache-fix-a-null-ptr-deref-regression.patch --- diff --git a/queue-3.11/bcache-fix-a-null-ptr-deref-regression.patch b/queue-3.11/bcache-fix-a-null-ptr-deref-regression.patch new file mode 100644 index 00000000000..2ce9b236a1f --- /dev/null +++ b/queue-3.11/bcache-fix-a-null-ptr-deref-regression.patch @@ -0,0 +1,41 @@ +From 2fe80d3bbf1c8bd9efc5b8154207c8dd104e7306 Mon Sep 17 00:00:00 2001 +From: Kent Overstreet +Date: Thu, 10 Oct 2013 17:31:15 -0700 +Subject: bcache: Fix a null ptr deref regression + +From: Kent Overstreet + +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 +Reported-by: Gabriel de Perthuis +Signed-off-by: Linus Torvalds +Signed-off-by: Greg Kroah-Hartman + +--- + 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 +@@ -996,6 +996,7 @@ static void request_write(struct cached_ + closure_bio_submit(bio, cl, s->d); + } else { + bch_writeback_add(dc); ++ s->op.cache_bio = bio; + + if (bio->bi_rw & REQ_FLUSH) { + /* Also need to send a flush to the backing device */ +@@ -1008,8 +1009,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: diff --git a/queue-3.11/series b/queue-3.11/series index b39624b8880..0c1a4f7af4f 100644 --- a/queue-3.11/series +++ b/queue-3.11/series @@ -133,3 +133,4 @@ hid-add-holtek-usb-id-04d9-a081-sharkoon-darkglider.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