AXFS: exporting xip_file_fault() for use with AXFS
Subsystems (3)
PATCH 1/10 AXFS: exporting xip_file_fault() for use with AXFS
We'll need this for AXFS. The equivalent function in filemap.c is exported.
--- include/linux/mm.h | 4 ++++ mm/filemap_xip.c | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-)
include/linux/mm.h +4 -0
@@ -161,6 +161,10 @@ struct vm_fault {*/ }; +#ifdef CONFIG_FS_XIP +extern int xip_file_fault (struct vm_area_struct *vma,struct vm_fault *vmf); +#endif +/* * These are the virtual MM functions - opening of an area, closing and * unmapping it (needed to keep files on disk up-to-date etc), pointer
mm/filemap_xip.c +2 -1
@@ -206,7 +206,7 @@ __xip_unmap (struct address_space * mapping,* * This function is derived from filemap_fault, but used for execute in place */ -static int xip_file_fault (struct vm_area_struct *vma,struct vm_fault *vmf) +int xip_file_fault (struct vm_area_struct *vma,struct vm_fault *vmf) {struct file *file = vma->vm_file;struct address_space *mapping = file->f_mapping;
@@ -262,6 +262,7 @@ found:return 0 ; } } +EXPORT_SYMBOL_GPL (xip_file_fault);static struct vm_operations_struct xip_file_vm_ops = { .fault = xip_file_fault,
Quoted 13 lines · Jared Hulbert
We'll need this for AXFS. The equivalent function in
filemap.cis exported.Signed-off-by Jared Hulbert <[email protected]>--- include/linux/mm.h | 4 ++++ mm/filemap_xip.c | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-)include/linux/mm.h +0
-0
include/linux/mm.h struct vm_fault { · line 167
Quoted 7 lines
include/linux/mm.h +4
-0@@ -161,6 +161,10 @@ struct vm_fault {*/ }; +#ifdef CONFIG_FS_XIP +extern int xip_file_fault (struct vm_area_struct *vma,struct vm_fault *vmf); +#endif +
No need for #ifdef here as this function is compiled and exported in .c regardless of CONFIG_FS_XIP
Quoted 18 lines
include/linux/mm.h +0
-0/* * These are the virtual MM functions - opening of an area, closing and * unmapping it (needed to keep files on disk up-to-date etc), pointer mm/filemap_xip.c +1
-1@@ -206,7 +206,7 @@ __xip_unmap (struct address_space * mapping,* * This function is derived from filemap_fault, but used for execute in place */ -static int xip_file_fault (struct vm_area_struct *vma,struct vm_fault *vmf) +int xip_file_fault (struct vm_area_struct *vma,struct vm_fault *vmf) {struct file *file = vma->vm_file;struct address_space *mapping = file->f_mapping;
mm/filemap_xip.c found: · line 268
Quoted 7 lines
mm/filemap_xip.c +1
-0@@ -262,6 +262,7 @@ found:return 0 ; } } +EXPORT_SYMBOL_GPL (xip_file_fault);static struct vm_operations_struct xip_file_vm_ops = { .fault = xip_file_fault,
______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Quoted 17 lines · Paulius Zaleckas
Quoted 16 lines · Jared Hulbert
We'll need this for AXFS. The equivalent function in
filemap.cis exported.Signed-off-by Jared Hulbert <[email protected]>--- include/linux/mm.h | 4 ++++ mm/filemap_xip.c | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-)include/linux/mm.h +0
-0@@ -161,6 +161,10 @@ struct vm_fault {*/ };
Quoted 7 lines
include/linux/mm.h struct vm_fault { · line 167
Quoted 4 lines
include/linux/mm.h +4
-0+#ifdef CONFIG_FS_XIP +extern int xip_file_fault (struct vm_area_struct *vma,struct vm_fault *vmf); +#endif +No need for #ifdef here as this function is compiled and exported in .c regardless of
CONFIG_FS_XIP
Sorry I am wrong... Have to get more sleep :)
Quoted 30 lines
Quoted 18 lines
include/linux/mm.h +0
-0/* * These are the virtual MM functions - opening of an area, closing and * unmapping it (needed to keep files on disk up-to-date etc), pointer mm/filemap_xip.c +1
-1@@ -206,7 +206,7 @@ __xip_unmap (struct address_space * mapping,* * This function is derived from filemap_fault, but used for execute in place */ -static int xip_file_fault (struct vm_area_struct *vma,struct vm_fault *vmf) +int xip_file_fault (struct vm_area_struct *vma,struct vm_fault *vmf) {struct file *file = vma->vm_file;struct address_space *mapping = file->f_mapping;mm/filemap_xip.c found: · line 268
Quoted 7 lines
mm/filemap_xip.c +1
-0@@ -262,6 +262,7 @@ found:return 0 ; } } +EXPORT_SYMBOL_GPL (xip_file_fault);static struct vm_operations_struct xip_file_vm_ops = { .fault = xip_file_fault,______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Quoted 7 lines · Jared Hulbert
We'll need this for AXFS. The equivalent function in
filemap.cis exported.Signed-off-by Jared Hulbert <[email protected]>--- include/linux/mm.h | 4 ++++ mm/filemap_xip.c | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-)