diff options
| author | Matthew Wilcox <matthew.r.wilcox@intel.com> | 2015-02-16 18:59:02 -0500 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2015-02-16 20:56:03 -0500 |
| commit | f7ca90b160307d63aaedab8bd451c24a182db20f (patch) | |
| tree | 687eb94acbc8ebfab6d5e12a57dc336ce21b7c64 /include | |
| parent | 289c6aedac981533331428bc933fff21ae332c9e (diff) | |
dax,ext2: replace the XIP page fault handler with the DAX page fault handler
Instead of calling aops->get_xip_mem from the fault handler, the
filesystem passes a get_block_t that is used to find the appropriate
blocks.
This requires that all architectures implement copy_user_page(). At the
time of writing, mips and arm do not. Patches exist and are in progress.
[akpm@linux-foundation.org: remap_file_pages went away]
Signed-off-by: Matthew Wilcox <matthew.r.wilcox@intel.com>
Reviewed-by: Jan Kara <jack@suse.cz>
Cc: Andreas Dilger <andreas.dilger@intel.com>
Cc: Boaz Harrosh <boaz@plexistor.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Dave Chinner <david@fromorbit.com>
Cc: Jens Axboe <axboe@kernel.dk>
Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Cc: Randy Dunlap <rdunlap@infradead.org>
Cc: Ross Zwisler <ross.zwisler@linux.intel.com>
Cc: Theodore Ts'o <tytso@mit.edu>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/fs.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h index 8084934a5676..6bad6d4c579b 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
| @@ -51,6 +51,7 @@ struct swap_info_struct; | |||
| 51 | struct seq_file; | 51 | struct seq_file; |
| 52 | struct workqueue_struct; | 52 | struct workqueue_struct; |
| 53 | struct iov_iter; | 53 | struct iov_iter; |
| 54 | struct vm_fault; | ||
| 54 | 55 | ||
| 55 | extern void __init inode_init(void); | 56 | extern void __init inode_init(void); |
| 56 | extern void __init inode_init_early(void); | 57 | extern void __init inode_init_early(void); |
| @@ -2590,9 +2591,10 @@ extern int nonseekable_open(struct inode * inode, struct file * filp); | |||
| 2590 | ssize_t dax_do_io(int rw, struct kiocb *, struct inode *, struct iov_iter *, | 2591 | ssize_t dax_do_io(int rw, struct kiocb *, struct inode *, struct iov_iter *, |
| 2591 | loff_t, get_block_t, dio_iodone_t, int flags); | 2592 | loff_t, get_block_t, dio_iodone_t, int flags); |
| 2592 | int dax_clear_blocks(struct inode *, sector_t block, long size); | 2593 | int dax_clear_blocks(struct inode *, sector_t block, long size); |
| 2594 | int dax_fault(struct vm_area_struct *, struct vm_fault *, get_block_t); | ||
| 2595 | #define dax_mkwrite(vma, vmf, gb) dax_fault(vma, vmf, gb) | ||
| 2593 | 2596 | ||
| 2594 | #ifdef CONFIG_FS_XIP | 2597 | #ifdef CONFIG_FS_XIP |
| 2595 | extern int xip_file_mmap(struct file * file, struct vm_area_struct * vma); | ||
| 2596 | extern int xip_truncate_page(struct address_space *mapping, loff_t from); | 2598 | extern int xip_truncate_page(struct address_space *mapping, loff_t from); |
| 2597 | #else | 2599 | #else |
| 2598 | static inline int xip_truncate_page(struct address_space *mapping, loff_t from) | 2600 | static inline int xip_truncate_page(struct address_space *mapping, loff_t from) |
