Patch "bcache: Fix a shrinker deadlock" has been added to the 3.10-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    bcache: Fix a shrinker deadlock

to the 3.10-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     bcache-fix-a-shrinker-deadlock.patch
and it can be found in the queue-3.10 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.


>From a698e08c82dfb9771e0bac12c7337c706d729b6d Mon Sep 17 00:00:00 2001
From: Kent Overstreet <kmo@xxxxxxxxxxxxx>
Date: Mon, 23 Sep 2013 23:17:34 -0700
Subject: bcache: Fix a shrinker deadlock

From: Kent Overstreet <kmo@xxxxxxxxxxxxx>

commit a698e08c82dfb9771e0bac12c7337c706d729b6d upstream.

GFP_NOIO means we could be getting called recursively - mca_alloc() ->
mca_data_alloc() - definitely can't use mutex_lock(bucket_lock) then.
Whoops.

Signed-off-by: Kent Overstreet <kmo@xxxxxxxxxxxxx>
Signed-off-by: Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>

---
 drivers/md/bcache/btree.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/md/bcache/btree.c
+++ b/drivers/md/bcache/btree.c
@@ -633,7 +633,7 @@ static int bch_mca_shrink(struct shrinke
 		return mca_can_free(c) * c->btree_pages;
 
 	/* Return -1 if we can't do anything right now */
-	if (sc->gfp_mask & __GFP_WAIT)
+	if (sc->gfp_mask & __GFP_IO)
 		mutex_lock(&c->bucket_lock);
 	else if (!mutex_trylock(&c->bucket_lock))
 		return -1;


Patches currently in stable-queue which might be from kmo@xxxxxxxxxxxxx are

queue-3.10/bcache-fix-a-flush-fua-performance-bug.patch
queue-3.10/bcache-fix-for-when-no-journal-entries-are-found.patch
queue-3.10/block-fix-bio_copy_data.patch
queue-3.10/bcache-fix-for-handling-overlapping-extents-when-reading-in-a-btree-node.patch
queue-3.10/bcache-fix-a-dumb-cpu-spinning-bug-in-writeback.patch
queue-3.10/bcache-strip-endline-when-writing-the-label-through-sysfs.patch
queue-3.10/bcache-fix-flushes-in-writeback-mode.patch
queue-3.10/bcache-fix-a-shrinker-deadlock.patch
queue-3.10/bcache-fix-a-writeback-performance-regression.patch
queue-3.10/bcache-fix-a-dumb-journal-discard-bug.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]