From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
To: linux-security-module@vger.kernel.org,
John Johansen <john.johansen@canonical.com>,
James Morris <jmorris@namei.org>,
"Serge E. Hallyn" <serge@hallyn.com>
Cc: tglx@linutronix.de
Subject: Re: [PATCH 1/2] apparmor: Use a memory pool instead per-CPU caches
Date: Mon, 15 Apr 2019 12:50:05 +0200 [thread overview]
Message-ID: <20190415105005.t6omvm5irdjhzbfs@linutronix.de> (raw)
In-Reply-To: <20190405133458.4809-1-bigeasy@linutronix.de>
On 2019-04-05 15:34:57 [+0200], To linux-security-module@vger.kernel.org wrote:
> The get_buffers() macro may provide one or two buffers to the caller.
> Those buffers are preallocated on init for each CPU. By default it
> allocates
> 2* 2 * MAX_PATH * POSSIBLE_CPU
>
> which equals 64KiB on a system with 4 CPUs or 1MiB with 64 CPUs and so
> on.
>
> Replace the per-CPU buffers with a common memory pool which is shared
> across all CPUs. The pool grows on demand and never shrinks.
> By using this pool it is possible to request a buffer and keeping
> preemption enabled which avoids the hack in profile_transition().
>
> During light testing I didn't get more than two buffers in total with
> this patch. So it seems to make sense to allocate the buffers on demand
> and keep them for further use for a quick access.
>
> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
a gentle ping.
Sebastian
next prev parent reply other threads:[~2019-04-15 10:50 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-05 13:34 [PATCH 1/2] apparmor: Use a memory pool instead per-CPU caches Sebastian Andrzej Siewior
2019-04-05 13:34 ` [PATCH 2/2] apparmor: Switch to GFP_KERNEL where possible Sebastian Andrzej Siewior
2019-05-07 19:57 ` John Johansen
2019-04-15 10:50 ` Sebastian Andrzej Siewior [this message]
2019-04-28 23:56 ` [PATCH 1/2] apparmor: Use a memory pool instead per-CPU caches John Johansen
2019-04-30 14:47 ` Sebastian Andrzej Siewior
2019-05-01 21:29 ` John Johansen
2019-05-02 10:51 ` Sebastian Andrzej Siewior
2019-05-02 13:17 ` Tetsuo Handa
2019-05-02 13:47 ` Sebastian Andrzej Siewior
2019-05-02 14:10 ` Tetsuo Handa
2019-05-03 11:48 ` [PATCH v2] " Sebastian Andrzej Siewior
2019-05-03 11:51 ` [PATCH v3] " Sebastian Andrzej Siewior
2019-05-03 12:41 ` Tetsuo Handa
2019-05-03 14:12 ` [PATCH v4] " Sebastian Andrzej Siewior
2019-05-07 19:57 ` John Johansen
2019-10-02 8:59 ` Sebastian Andrzej Siewior
2019-10-02 15:47 ` John Johansen
2019-10-02 15:52 ` Sebastian Andrzej Siewior
2019-05-02 19:33 ` [PATCH 1/2] " John Johansen
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=20190415105005.t6omvm5irdjhzbfs@linutronix.de \
--to=bigeasy@linutronix.de \
--cc=jmorris@namei.org \
--cc=john.johansen@canonical.com \
--cc=linux-security-module@vger.kernel.org \
--cc=serge@hallyn.com \
--cc=tglx@linutronix.de \
/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).