mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
Catch filesystems lacking s_bdi
noop_backing_dev_info is used only as a flag to mark filesystems that don't have any backing store, like tmpfs, procfs, spufs, etc. Signed-off-by: Joern Engel <[email protected]> Changed the BUG_ON() to a WARN_ON(). Note that adding dirty inodes to the noop_backing_dev_info is not legal and will not result in them being flushed, but we already catch this condition in __mark_inode_dirty() when checking for a registered bdi. Signed-off-by: Jens Axboe <[email protected]>
This commit is contained in:
parent
7e2455c1a1
commit
5129a469a9
4 changed files with 13 additions and 4 deletions
|
|
@ -14,6 +14,7 @@
|
|||
#include <linux/pagemap.h>
|
||||
#include <linux/quotaops.h>
|
||||
#include <linux/buffer_head.h>
|
||||
#include <linux/backing-dev.h>
|
||||
#include "internal.h"
|
||||
|
||||
#define VALID_FLAGS (SYNC_FILE_RANGE_WAIT_BEFORE|SYNC_FILE_RANGE_WRITE| \
|
||||
|
|
@ -32,7 +33,7 @@ static int __sync_filesystem(struct super_block *sb, int wait)
|
|||
* This should be safe, as we require bdi backing to actually
|
||||
* write out data in the first place
|
||||
*/
|
||||
if (!sb->s_bdi)
|
||||
if (!sb->s_bdi || sb->s_bdi == &noop_backing_dev_info)
|
||||
return 0;
|
||||
|
||||
if (sb->s_qcop && sb->s_qcop->quota_sync)
|
||||
|
|
|
|||
Loading…
Reference in a new issue