Merge tag 'ntfs3_for_6.0' of https://github.com/Paragon-Software-Group/linux-ntfs3
[sfrench/cifs-2.6.git] / fs / ntfs3 / ntfs_fs.h
index c37fa9ca56896d11bbe5c0b8177514263ea8bfc3..2c791222c4e273a867c05476f177ccedbe2403cb 100644 (file)
@@ -619,7 +619,7 @@ int ntfs_write_bh(struct ntfs_sb_info *sbi, struct NTFS_RECORD_HEADER *rhdr,
                  struct ntfs_buffers *nb, int sync);
 int ntfs_bio_pages(struct ntfs_sb_info *sbi, const struct runs_tree *run,
                   struct page **pages, u32 nr_pages, u64 vbo, u32 bytes,
-                  u32 op);
+                  enum req_op op);
 int ntfs_bio_fill_1(struct ntfs_sb_info *sbi, const struct runs_tree *run);
 int ntfs_vbo_to_lbo(struct ntfs_sb_info *sbi, const struct runs_tree *run,
                    u64 vbo, u64 *lbo, u64 *bytes);
@@ -691,6 +691,11 @@ int ntfs_set_size(struct inode *inode, u64 new_size);
 int reset_log_file(struct inode *inode);
 int ntfs_get_block(struct inode *inode, sector_t vbn,
                   struct buffer_head *bh_result, int create);
+int ntfs_write_begin(struct file *file, struct address_space *mapping,
+                    loff_t pos, u32 len, struct page **pagep, void **fsdata);
+int ntfs_write_end(struct file *file, struct address_space *mapping,
+                  loff_t pos, u32 len, u32 copied, struct page *page,
+                  void *fsdata);
 int ntfs3_write_inode(struct inode *inode, struct writeback_control *wbc);
 int ntfs_sync_inode(struct inode *inode);
 int ntfs_flush_inodes(struct super_block *sb, struct inode *i1,
@@ -893,13 +898,8 @@ static inline struct page *ntfs_map_page(struct address_space *mapping,
 {
        struct page *page = read_mapping_page(mapping, index, NULL);
 
-       if (!IS_ERR(page)) {
+       if (!IS_ERR(page))
                kmap(page);
-               if (!PageError(page))
-                       return page;
-               ntfs_unmap_page(page);
-               return ERR_PTR(-EIO);
-       }
        return page;
 }