From: David Hildenbrand <david@redhat.com>
To: Dev Jain <dev.jain@arm.com>,
akpm@linux-foundation.org, kas@kernel.org, willy@infradead.org,
hughd@google.com
Cc: ziy@nvidia.com, baolin.wang@linux.alibaba.com,
lorenzo.stoakes@oracle.com, Liam.Howlett@oracle.com,
npache@redhat.com, ryan.roberts@arm.com, baohua@kernel.org,
linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: [RFC PATCH] mm: Enable khugepaged to operate on non-writable VMAs
Date: Mon, 1 Sep 2025 17:35:50 +0200 [thread overview]
Message-ID: <3b30e9fd-4035-42f2-a7ca-3a670bb79dd5@redhat.com> (raw)
In-Reply-To: <e52cac79-fe1a-401e-9259-747a4d587bd1@arm.com>
On 01.09.25 17:26, Dev Jain wrote:
>
> On 01/09/25 2:02 pm, David Hildenbrand wrote:
>> On 01.09.25 09:48, Dev Jain wrote:
>>>
>>> @@ -19,7 +19,7 @@
>>> EM( SCAN_PTE_NON_PRESENT, "pte_non_present") \
>>> EM( SCAN_PTE_UFFD_WP, "pte_uffd_wp") \
>>> EM( SCAN_PTE_MAPPED_HUGEPAGE, "pte_mapped_hugepage") \
>>> - EM( SCAN_PAGE_RO, "no_writable_page") \
>>> + EM( SCAN_PAGE_RO, "no_writable_page") /* deprecated */ \
>>> EM( SCAN_LACK_REFERENCED_PAGE, "lack_referenced_page") \
>>> EM( SCAN_PAGE_NULL, "page_null") \
>>> EM( SCAN_SCAN_ABORT, "scan_aborted") \
>>> diff --git a/mm/khugepaged.c b/mm/khugepaged.c
>>> index 4ec324a4c1fe..5ef8482597a9 100644
>>> --- a/mm/khugepaged.c
>>> +++ b/mm/khugepaged.c
>>> @@ -39,7 +39,7 @@ enum scan_result {
>>> SCAN_PTE_NON_PRESENT,
>>> SCAN_PTE_UFFD_WP,
>>> SCAN_PTE_MAPPED_HUGEPAGE,
>>> - SCAN_PAGE_RO,
>>> + SCAN_PAGE_RO, /* deprecated */
>>
>> Why can't we remove that completely.
>
> (I raised this query in the other mail but due to not snipping stuff in
> between,
>
I saw it but forgot to reply :)
> it may have been glossed over)
>
> I was wondering whether a userspace script could break which assumes
> scan_page_ro
>
> metric is there? I played with tracing long time back so I don't remember.
If it's part of a stable abi/api, then it could be a problem indeed.
I don't think trace events are in general not stable abi/api. In
practice I think some are (e.g., in scheduler).
I assume we can safely drop it, just like we can add new stuff.
After all, if "SCAN_PAGE_RO" never happens anymore, we would never be
running into the __print_symbolic() with that value.
--
Cheers
David / dhildenb
prev parent reply other threads:[~2025-09-01 15:35 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-01 7:48 [RFC PATCH] mm: Enable khugepaged to operate on non-writable VMAs Dev Jain
2025-09-01 8:23 ` Kiryl Shutsemau
2025-09-01 8:32 ` David Hildenbrand
2025-09-01 13:15 ` Kiryl Shutsemau
2025-09-01 13:43 ` David Hildenbrand
2025-09-01 8:39 ` Dev Jain
2025-09-01 8:32 ` David Hildenbrand
2025-09-01 8:50 ` Dev Jain
2025-09-01 15:26 ` Dev Jain
2025-09-01 15:35 ` David Hildenbrand [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3b30e9fd-4035-42f2-a7ca-3a670bb79dd5@redhat.com \
--to=david@redhat.com \
--cc=Liam.Howlett@oracle.com \
--cc=akpm@linux-foundation.org \
--cc=baohua@kernel.org \
--cc=baolin.wang@linux.alibaba.com \
--cc=dev.jain@arm.com \
--cc=hughd@google.com \
--cc=kas@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=lorenzo.stoakes@oracle.com \
--cc=npache@redhat.com \
--cc=ryan.roberts@arm.com \
--cc=willy@infradead.org \
--cc=ziy@nvidia.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).