This is a note to let you know that I've just added the patch titled
Btrfs: make sure there are not any read requests before stopping workers
to the 3.15-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:
btrfs-make-sure-there-are-not-any-read-requests-before-stopping-workers.patch
and it can be found in the queue-3.15 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <[email protected]> know about it.
>From de348ee022175401e77d7662b7ca6e231a94e3fd Mon Sep 17 00:00:00 2001
From: Wang Shilong <[email protected]>
Date: Wed, 9 Apr 2014 19:23:22 +0800
Subject: Btrfs: make sure there are not any read requests before stopping
workers
From: Wang Shilong <[email protected]>
commit de348ee022175401e77d7662b7ca6e231a94e3fd upstream.
In close_ctree(), after we have stopped all workers,there maybe still
some read requests(for example readahead) to submit and this *maybe* trigger
an oops that user reported before:
kernel BUG at fs/btrfs/async-thread.c:619!
By hacking codes, i can reproduce this problem with one cpu available.
We fix this potential problem by invalidating all btree inode pages before
stopping all workers.
Thanks to Miao for pointing out this problem.
Signed-off-by: Wang Shilong <[email protected]>
Reviewed-by: David Sterba <[email protected]>
Signed-off-by: Chris Mason <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
---
fs/btrfs/disk-io.c | 5 +++++
1 file changed, 5 insertions(+)
--- a/fs/btrfs/disk-io.c
+++ b/fs/btrfs/disk-io.c
@@ -3633,6 +3633,11 @@ int close_ctree(struct btrfs_root *root)
btrfs_free_block_groups(fs_info);
+ /*
+ * we must make sure there is not any read request to
+ * submit after we stopping all workers.
+ */
+ invalidate_inode_pages2(fs_info->btree_inode->i_mapping);
btrfs_stop_all_workers(fs_info);
free_root_pointers(fs_info, 1);
Patches currently in stable-queue which might be from
[email protected] are
queue-3.15/btrfs-set-right-total-device-count-for-seeding-support.patch
queue-3.15/btrfs-make-sure-there-are-not-any-read-requests-before-stopping-workers.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html