Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

f2fs: add remap_pages as generic_file_remap_pages

This was added for all the file systems before.

See the following commit.

commit id: 0b173bc4daa8f8ec03a85abf5e47b23502ff80af

[PATCH] mm: kill vma flag VM_CAN_NONLINEAR

This patch moves actual ptes filling for non-linear file mappings
into special vma operation: ->remap_pages().

File system must implement this method to get non-linear mappings support,
if it uses filemap_fault() then generic_file_remap_pages() can be used.

Now device drivers can implement this method and obtain nonlinear vma support."

Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>

+3 -2
+3 -2
fs/f2fs/file.c
··· 96 96 } 97 97 98 98 static const struct vm_operations_struct f2fs_file_vm_ops = { 99 - .fault = filemap_fault, 100 - .page_mkwrite = f2fs_vm_page_mkwrite, 99 + .fault = filemap_fault, 100 + .page_mkwrite = f2fs_vm_page_mkwrite, 101 + .remap_pages = generic_file_remap_pages, 101 102 }; 102 103 103 104 static int need_to_sync_dir(struct f2fs_sb_info *sbi, struct inode *inode)