Hi Alex, On 7/6/22 06:11, Alexandre Marciano Gimenez wrote:
Dear linux-man maintainers, Please consider the attached patch (also pasted below). Thanks, Alex Gimenez / raging@xxxxxxxxxx <mailto:raging@xxxxxxxxxx> === From f17223c4c89f29a73d92a21e6a8980072a4cc010 Mon Sep 17 00:00:00 2001 From: Alex Gimenez <raging@xxxxxxxxxx <mailto:raging@xxxxxxxxxx>> Date: Tue, 5 Jul 2022 14:07:38 +0900Subject: [PATCH] madvise.2: Add exception for pages locked by other processesAdd text to explicitly state that pages locked by a different mapping are eligible for the MADV_REMOVE operation. How found: first extrapolated based on the principle that mlocks local to a VMA. Then ran an experiment to prove it, with the code below: Source at (public link)https://chromium-review.googlesource.com/c/chromium/src/+/3742902 <https://chromium-review.googlesource.com/c/chromium/src/+/3742902>Results (will share upon request)https://docs.google.com/spreadsheets/d/19nwKcirI7a4IWBxg5XCUPqv7JGBt3ZVC9fDJh9WZ_1Q <https://docs.google.com/spreadsheets/d/19nwKcirI7a4IWBxg5XCUPqv7JGBt3ZVC9fDJh9WZ_1Q>To: linux-man@xxxxxxxxxxxxxxx <mailto:linux-man@xxxxxxxxxxxxxxx>, alx.manpages@xxxxxxxxx <mailto:alx.manpages@xxxxxxxxx>, mtk.manpages@xxxxxxxxx <mailto:mtk.manpages@xxxxxxxxx>Signed-off-by: Alex Gimenez <raging@xxxxxxxxxx <mailto:raging@xxxxxxxxxx>>
Would you mind CCing the relevant (linux-mm?) kernel list and/or kernel developers that are involved in this feature?
I don't understand most of this. Sorry. Thanks, Alex
--- man2/madvise.2 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/man2/madvise.2 b/man2/madvise.2 index 066194be9..b01d6972f 100644 --- a/man2/madvise.2 +++ b/man2/madvise.2 @@ -176,7 +176,9 @@ data with a value of zero. .\" hot-plug memory on UML. .IP The specified address range must be mapped shared and writable. -This flag cannot be applied to locked pages, or +This flag cannot be applied to locked pages, though it is possible to apply
man-pages(7): Use semantic newlines In the source of a manual page, new sentences should be started on new lines, long sentences should be split into lines at clause breaks (commas, semicolons, colons, and so on), and long clauses should be split at phrase bound‐ aries. This convention, sometimes known as "semantic newlines", makes it easier to see the effect of patches, which often operate at the level of individual sentences, clauses, or phrases.
+this flag to pages shared with locked portions of a different mapping. +This flag cannot be applied to .B VM_PFNMAP pages. .IP -- 2.37.0.rc0.161.g10f37bed90-goog
-- Alejandro Colomar <http://www.alejandro-colomar.es/>
Attachment:
OpenPGP_signature
Description: OpenPGP digital signature