summaryrefslogtreecommitdiff
path: root/fs/buffer.c
diff options
context:
space:
mode:
authorStephen Rothwell <sfr@canb.auug.org.au>2011-04-26 17:51:29 +1000
committerStephen Rothwell <sfr@canb.auug.org.au>2011-04-26 17:51:29 +1000
commit03fbade434cffb612cb03a8e9fd1242601327d6e (patch)
tree19f560c4566a98ce2264f96c8b0d394b70e0914f /fs/buffer.c
parente3ed20790b7c483d82467434fc27a482acf0d2d0 (diff)
parente046b9640996aa07d240865d97527ed3ea26289d (diff)
Merge remote-tracking branch 'cleancache/linux-next'
Diffstat (limited to 'fs/buffer.c')
-rw-r--r--fs/buffer.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/buffer.c b/fs/buffer.c
index a08bb8e61c6f..de05703b184b 100644
--- a/fs/buffer.c
+++ b/fs/buffer.c
@@ -41,6 +41,7 @@
#include <linux/bitops.h>
#include <linux/mpage.h>
#include <linux/bit_spinlock.h>
+#include <linux/cleancache.h>
static int fsync_buffers_list(spinlock_t *lock, struct list_head *list);
@@ -269,6 +270,10 @@ void invalidate_bdev(struct block_device *bdev)
invalidate_bh_lrus();
lru_add_drain_all(); /* make sure all lru add caches are flushed */
invalidate_mapping_pages(mapping, 0, -1);
+ /* 99% of the time, we don't need to flush the cleancache on the bdev.
+ * But, for the strange corners, lets be cautious
+ */
+ cleancache_flush_inode(mapping);
}
EXPORT_SYMBOL(invalidate_bdev);