]> git.hungrycats.org Git - linux/commitdiff
btrfs: clear PF_NOFREEZE in cleaner_kthread()
authorJiri Kosina <jkosina@suse.cz>
Mon, 26 Oct 2015 06:06:19 +0000 (15:06 +0900)
committerZygo Blaxell <zblaxell@serenity.furryterror.org>
Thu, 29 Oct 2015 21:53:53 +0000 (17:53 -0400)
cleaner_kthread() kthread calls try_to_freeze() at the beginning of every
cleanup attempt. This operation can't ever succeed though, as the kthread
hasn't marked itself as freezable.

Before (hopefully eventually) kthread freezing gets converted to fileystem
freezing, we'd rather mark cleaner_kthread() freezable (as my
understanding is that it can generate filesystem I/O during suspend).

Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Chris Mason <clm@fb.com>
(cherry picked from commit 696249132158014d594896df3a81390616069c5c)
(cherry picked from commit f36bf5f7ad5d23d31709640fd582aab269148465)

fs/btrfs/disk-io.c

index 67d5375ec00d75b2570ae0a3b89aa728d2855ae7..0904147bacedf82955977c2810a7440a53f3dbe5 100644 (file)
@@ -1753,6 +1753,7 @@ static int cleaner_kthread(void *arg)
        int again;
        struct btrfs_trans_handle *trans;
 
+       set_freezable();
        do {
                again = 0;