Linux-mm Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "David Hildenbrand (Arm)" <david@kernel.org>
To: Hongfu Li <lihongfu@kylinos.cn>
Cc: akpm@linux-foundation.org, hongfu.li@linux.dev,
	jhubbard@nvidia.com, joey.gouly@arm.com, keith.lucas@oracle.com,
	kevin.brodsky@arm.com, liam@infradead.org,
	linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org,
	linux-mm@kvack.org, ljs@kernel.org, mhocko@suse.com,
	rppt@kernel.org, shuah@kernel.org, surenb@google.com,
	usama.anjum@collabora.com, vbabka@kernel.org,
	yury.khrustalev@arm.com, zwisler@google.com
Subject: Re: [PATCH v9 1/5] selftests/mm: move pkey selftest helpers to pkey_util.c
Date: Mon, 6 Jul 2026 15:46:55 +0200	[thread overview]
Message-ID: <4913bf32-3695-4983-9ad7-ea0638807453@kernel.org> (raw)
In-Reply-To: <20260706103143.3638104-1-lihongfu@kylinos.cn>

On 7/6/26 12:31, Hongfu Li wrote:
> Hi,
> 
>>> diff --git a/tools/testing/selftests/mm/pkey_util.c b/tools/testing/selftests/mm/pkey_util.c
>>> index 255b332f7a08..fbef3cd45447 100644
>>> --- a/tools/testing/selftests/mm/pkey_util.c
>>> +++ b/tools/testing/selftests/mm/pkey_util.c
>>> @@ -2,9 +2,99 @@
>>>  #define __SANE_USERSPACE_TYPES__
>>>  #include <sys/syscall.h>
>>>  #include <unistd.h>
>>> +#include <fcntl.h>
>>> +#include <stdio.h>
>>> +#include <string.h>
>>>  
>>>  #include "pkey-helpers.h"
>>>  
>>> +int iteration_nr = 1;
>>> +int test_nr;
>>> +int dprint_in_signal;
>>> +
>>> +#if CONTROL_TRACING > 0
>>
>> Who sets that CONTROL_TRACING? And if it's nobody, why are we dragging this along?
> 
> Thanks a lot for your comment.
> 
> CONTROL_TRACING is disabled by default. It can be enabled at build time
> with -DCONTROL_TRACING=1 to capture extra debug info via ftrace for pkey
> failure debugging. This patch just moves the tracing and abort-hook code
> to the shared pkey_util.c, fully retaining the original opt-in debug logic.
> This is based on my understanding of the existing code design, are
> there any corner cases I overlooked?

This is not documented anywhere, so it's rather odd. I wonder if there is a
single person on earth that uses this :)

-- 
Cheers,

David


      reply	other threads:[~2026-07-06 13:47 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20260702062332.911786-1-lihongfu@kylinos.cn>
2026-07-05 20:48 ` [PATCH v9 0/5] selftests/mm: refactor pkey helpers and fix mmap error handling Andrew Morton
2026-07-06  7:32   ` Hongfu Li
     [not found] ` <20260702062332.911786-2-lihongfu@kylinos.cn>
2026-07-06  9:28   ` [PATCH v9 1/5] selftests/mm: move pkey selftest helpers to pkey_util.c David Hildenbrand (Arm)
2026-07-06 10:31     ` Hongfu Li
2026-07-06 13:46       ` David Hildenbrand (Arm) [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=4913bf32-3695-4983-9ad7-ea0638807453@kernel.org \
    --to=david@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=hongfu.li@linux.dev \
    --cc=jhubbard@nvidia.com \
    --cc=joey.gouly@arm.com \
    --cc=keith.lucas@oracle.com \
    --cc=kevin.brodsky@arm.com \
    --cc=liam@infradead.org \
    --cc=lihongfu@kylinos.cn \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=ljs@kernel.org \
    --cc=mhocko@suse.com \
    --cc=rppt@kernel.org \
    --cc=shuah@kernel.org \
    --cc=surenb@google.com \
    --cc=usama.anjum@collabora.com \
    --cc=vbabka@kernel.org \
    --cc=yury.khrustalev@arm.com \
    --cc=zwisler@google.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