diff options
Diffstat (limited to 'fs/btrfs')
-rw-r--r-- | fs/btrfs/disk-io.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c index 9e41ea93ebce..76ee7a4ae00c 100644 --- a/fs/btrfs/disk-io.c +++ b/fs/btrfs/disk-io.c | |||
@@ -381,6 +381,13 @@ int btrfs_wq_submit_bio(struct btrfs_fs_info *fs_info, struct inode *inode, | |||
381 | { | 381 | { |
382 | struct async_submit_bio *async; | 382 | struct async_submit_bio *async; |
383 | 383 | ||
384 | /* | ||
385 | * inline writerback should stay inline, only hop to the async | ||
386 | * queue if we're pdflush | ||
387 | */ | ||
388 | if (!current_is_pdflush()) | ||
389 | return submit_bio_hook(inode, rw, bio, mirror_num); | ||
390 | |||
384 | async = kmalloc(sizeof(*async), GFP_NOFS); | 391 | async = kmalloc(sizeof(*async), GFP_NOFS); |
385 | if (!async) | 392 | if (!async) |
386 | return -ENOMEM; | 393 | return -ENOMEM; |