mm: update the description for madvise_remove
Subsystems (4)
PATCH 1/1 mm: update the description for madvise_remove
Currently, we have more filesystems supporting fallocate, e.g ext4/btrfs. Remove the outdated comment for madvise_remove.
--- mm/madvise.c | 3 --- 1 file changed, 3 deletions(-)
mm/madvise.c +0 -3
@@ -292,9 +292,6 @@ static long madvise_dontneed(struct vm_area_struct *vma,/* * Application wants to free up the pages and associated backing store. * This is effectively punching a hole into the middle of a file. -* -* NOTE: Currently, only shmfs/tmpfs is supported for this operation. -* Other filesystems return -ENOSYS. */ static long madvise_remove(struct vm_area_struct *vma, struct vm_area_struct **prev,
Signature · 7 lines
1.8.3.2 -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
Quoted 5 lines · Wang Sheng-Hui
Currently, we have more filesystems supporting fallocate, e.g ext4/btrfs. Remove the outdated comment for
madvise_remove.Signed-off-by Wang Sheng-Hui <[email protected]>
Looks good to me.
Quoted 27 lines
--- mm/madvise.c | 3 --- 1 file changed, 3 deletions(-)mm/madvise.c +0
-3@@ -292,9 +292,6 @@ static long madvise_dontneed(struct vm_area_struct *vma,/* * Application wants to free up the pages and associated backing store. * This is effectively punching a hole into the middle of a file. -* -* NOTE: Currently, only shmfs/tmpfs is supported for this operation. -* Other filesystems return -ENOSYS. */ static long madvise_remove(struct vm_area_struct *vma, struct vm_area_struct **prev,Signature · 7 lines
1.8.3.2 -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
Quoted 14 lines · Wang Sheng-Hui
Currently, we have more filesystems supporting fallocate, e.g ext4/btrfs. Remove the outdated comment for
madvise_remove.Signed-off-by Wang Sheng-Hui <[email protected]>--- mm/madvise.c | 3 --- 1 file changed, 3 deletions(-)mm/madvise.c +0
-0
mm/madvise.c static long madvise_dontneed(struct vm_area_struct *vma, · line 297
Quoted 9 lines
mm/madvise.c +0
-3@@ -292,9 +292,6 @@ static long madvise_dontneed(struct vm_area_struct *vma,/* * Application wants to free up the pages and associated backing store. * This is effectively punching a hole into the middle of a file. -* -* NOTE: Currently, only shmfs/tmpfs is supported for this operation. -* Other filesystems return -ENOSYS. */ static long madvise_remove(struct vm_area_struct *vma, struct vm_area_struct **prev,
[For those without context: this patch has been merged into the -mm tree.]
This reference also exists in the man-page for madvise(2), are you planning on removing it as well?
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
Patch to man-page.
[PATCH] madvise.2: update the description for MADV_REMOVE
Currently we have more filesystems supporting fallcate, e.g ext4/btrfs, which can response to MADV_REMOVE gracefully.
And if filesystems don't support fallocate, the return error would be EOPNOTSUPP, instead of ENOSYS.
--- man2/madvise.2 | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-)
man2/madvise.2 +3 -7
@@ -99,13 +99,9 @@ or zero-fill-on-demand pages for mappings without an underlying file. .TP .BR MADV_REMOVE " (since Linux 2.6.16)" -Free up a given range of pages -and its associated backing store. -Currently, -.\" 2.6.18-rc5 -only shmfs/tmpfs supports this; other filesystems return with the -error -.BR ENOSYS . +Free up a given range of pages and its associated backing store. +Filesystems that don't support fallocate will return error +.BR EOPNOTSUPP. .\" Databases want to use this feature to drop a section of their .\" bufferpool (shared memory segments) - without writing back to .\" disk/swap space. This feature is also useful for supporting
Signature · 1 line
1.8.3.2
Quoted 31 lines · David Rientjes
Quoted 14 lines · Wang Sheng-Hui
Currently, we have more filesystems supporting fallocate, e.g ext4/btrfs. Remove the outdated comment for
madvise_remove.Signed-off-by Wang Sheng-Hui <[email protected]>--- mm/madvise.c | 3 --- 1 file changed, 3 deletions(-)mm/madvise.c +0
-0mm/madvise.c static long madvise_dontneed(struct vm_area_struct *vma, · line 297
Quoted 9 lines
mm/madvise.c +0
-3@@ -292,9 +292,6 @@ static long madvise_dontneed(struct vm_area_struct *vma,/* * Application wants to free up the pages and associated backing store. * This is effectively punching a hole into the middle of a file. -* -* NOTE: Currently, only shmfs/tmpfs is supported for this operation. -* Other filesystems return -ENOSYS. */ static long madvise_remove(struct vm_area_struct *vma, struct vm_area_struct **prev,[For those without context: this patch has been merged into the -mm tree.]
This reference also exists in the man-page for madvise(2), are you planning on removing it as well?
Quoted 11 lines · Wang Sheng-Hui
Patch to man-page.
[PATCH] madvise.2: update the description for
MADV_REMOVECurrently we have more filesystems supporting fallcate, e.g ext4/btrfs, which can response to
MADV_REMOVEgracefully.And if filesystems don't support fallocate, the return error would be EOPNOTSUPP, instead of ENOSYS.
Signed-off-by Wang Sheng-Hui <[email protected]>
Great, thanks! This looks like it can be applied immediately and doesn't require us to wait for any kernel change.
Good catch with the return value.
Quoted 15 lines
--- man2/madvise.2 | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-)man2/madvise.2 +0
-3@@ -99,13 +99,9 @@ or zero-fill-on-demand pages for mappings without an underlying file. .TP .BR MADV_REMOVE " (since Linux 2.6.16)" -Free up a given range of pages -and its associated backing store. -Currently,
man2/madvise.2 or zero-fill-on-demand pages for mappings · line 107
Quoted 10 lines
man2/madvise.2 +3
-4-.\" 2.6.18-rc5 -only shmfs/tmpfs supports this; other filesystems return with the -error -.BR ENOSYS . +Free up a given range of pages and its associated backing store. +Filesystems that don't support fallocate will return error +.BR EOPNOTSUPP. .\" Databases want to use this feature to drop a section of their .\" bufferpool (shared memory segments) - without writing back to .\" disk/swap space. This feature is also useful for supporting
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>