linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Vlastimil Babka <vbabka@suse.cz>
To: Kees Cook <keescook@chromium.org>
Cc: Christoph Lameter <cl@linux.com>,
	David Rientjes <rientjes@google.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Roman Gushchin <roman.gushchin@linux.dev>,
	Hyeonggon Yoo <42.hyeyoo@gmail.com>,
	linux-mm@kvack.org, linux-kernel@vger.kernel.org,
	Kent Overstreet <kent.overstreet@linux.dev>,
	Suren Baghdasaryan <surenb@google.com>
Subject: Re: [PATCH] mm, slab: don't wrap internal functions with alloc_hooks()
Date: Mon, 27 May 2024 09:15:25 +0200	[thread overview]
Message-ID: <d63a0457-6333-4bd0-b1b7-b868ed753894@suse.cz> (raw)
In-Reply-To: <202405241625.9FF3B5E@keescook>

On 5/25/24 1:26 AM, Kees Cook wrote:
> On Wed, May 22, 2024 at 11:50:37AM +0200, Vlastimil Babka wrote:
>> The functions __kmalloc_noprof(), kmalloc_large_noprof(),
>> kmalloc_trace_noprof() and their _node variants are all internal to the
>> implementations of kmalloc_noprof() and kmalloc_node_noprof() and are
>> only declared in the "public" slab.h and exported so that those
>> implementations can be static inline and distinguish the build-time
>> constant size variants. The only other users for some of the internal
>> functions are slub_kunit and fortify_kunit tests which make very
>> short-lived allocations.
> 
> If it's only internal, I'm happy to drop it from fortify_kunit.

Yeah, looks like you already have static and dynamic size parameter variants
of the tests so testing kmalloc() will call __kmalloc_noprof() in the
dynamic case (ditto _node variant) and is the best way to exercise that. So
So in v2 I will drop those from fortify_kunit instead of adjusting names.

> -Kees
> 



      reply	other threads:[~2024-05-27  7:15 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-22  9:50 Vlastimil Babka
2024-05-22 11:43 ` Kent Overstreet
2024-05-24 23:26 ` Kees Cook
2024-05-27  7:15   ` Vlastimil Babka [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=d63a0457-6333-4bd0-b1b7-b868ed753894@suse.cz \
    --to=vbabka@suse.cz \
    --cc=42.hyeyoo@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=cl@linux.com \
    --cc=keescook@chromium.org \
    --cc=kent.overstreet@linux.dev \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=rientjes@google.com \
    --cc=roman.gushchin@linux.dev \
    --cc=surenb@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