fs: Add helper to clean bdev aliases under a bh and use it
[sfrench/cifs-2.6.git] / fs / ntfs / file.c
index bf72a2c58b75b4d2a5de956a00d1eb59af2039bb..99510d811a8c87bbaba51419a63816a7036ece89 100644 (file)
@@ -740,8 +740,7 @@ map_buffer_cached:
                                        set_buffer_uptodate(bh);
                                if (unlikely(was_hole)) {
                                        /* We allocated the buffer. */
-                                       unmap_underlying_metadata(bh->b_bdev,
-                                                       bh->b_blocknr);
+                                       clean_bdev_bh_alias(bh);
                                        if (bh_end <= pos || bh_pos >= end)
                                                mark_buffer_dirty(bh);
                                        else
@@ -784,7 +783,7 @@ map_buffer_cached:
                                continue;
                        }
                        /* We allocated the buffer. */
-                       unmap_underlying_metadata(bh->b_bdev, bh->b_blocknr);
+                       clean_bdev_bh_alias(bh);
                        /*
                         * If the buffer is fully outside the write, zero it,
                         * set it uptodate, and mark it dirty so it gets