dax: Use radix tree entry lock to protect cow faults
[sfrench/cifs-2.6.git] / include / linux / dax.h
index 756625c6d0ddbdd55221b6be0699619f39e638a8..7bf12277c006534f16a6ba49e6446f88eb438f68 100644 (file)
@@ -21,6 +21,7 @@ void dax_wake_mapping_entry_waiter(struct address_space *mapping,
 
 #ifdef CONFIG_FS_DAX
 struct page *read_dax_sector(struct block_device *bdev, sector_t n);
+void dax_unlock_mapping_entry(struct address_space *mapping, pgoff_t index);
 int __dax_zero_page_range(struct block_device *bdev, sector_t sector,
                unsigned int offset, unsigned int length);
 #else
@@ -29,6 +30,12 @@ static inline struct page *read_dax_sector(struct block_device *bdev,
 {
        return ERR_PTR(-ENXIO);
 }
+/* Shouldn't ever be called when dax is disabled. */
+static inline void dax_unlock_mapping_entry(struct address_space *mapping,
+                                           pgoff_t index)
+{
+       BUG();
+}
 static inline int __dax_zero_page_range(struct block_device *bdev,
                sector_t sector, unsigned int offset, unsigned int length)
 {