• Josef Bacik's avatar
    Btrfs: use a worker thread to do caching · bab39bf9
    Josef Bacik authored
    A user reported a deadlock when copying a bunch of files.  This is because they
    were low on memory and kthreadd got hung up trying to migrate pages for an
    allocation when starting the caching kthread.  The page was locked by the person
    starting the caching kthread.  To fix this we just need to use the async thread
    stuff so that the threads are already created and we don't have to worry about
    deadlocks.  Thanks,
    Reported-by: default avatarRoman Mamedov <rm@romanrm.ru>
    Signed-off-by: default avatarJosef Bacik <josef@redhat.com>
    bab39bf9
disk-io.c 82.8 KB