From: Waiman Long <longman@redhat.com>
To: "Luis R. Rodriguez" <mcgrof@kernel.org>,
Kees Cook <keescook@chromium.org>,
Andrew Morton <akpm@linux-foundation.org>,
Jonathan Corbet <corbet@lwn.net>
Cc: linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org,
linux-doc@vger.kernel.org, Al Viro <viro@zeniv.linux.org.uk>,
Matthew Wilcox <willy@infradead.org>,
"Eric W. Biederman" <ebiederm@xmission.com>,
Takashi Iwai <tiwai@suse.de>, Davidlohr Bueso <dbueso@suse.de>,
Manfred Spraul <manfred@colorfullife.com>,
Waiman Long <longman@redhat.com>
Subject: [PATCH v10 0/4] ipc: Increase IPCMNI limit & IPC id generation modes
Date: Mon, 5 Nov 2018 10:43:42 -0500 [thread overview]
Message-ID: <1541432626-27780-1-git-send-email-longman@redhat.com> (raw)
v9->v10:
- Drop v9 patches 1 & 2 because they have been merged upstream.
- Minor twist to fix checkpatch warnings.
- Add a new ipcid_mode sysctl parameter (new patches 3 & 4) to control
how the IPC ids are being generated.
v7 patch: https://lkml.org/lkml/2018/5/7/666
v8 patch: https://lkml.org/lkml/2018/6/18/706
v9 patch: https://lkml.org/lkml/2018/9/7/1141
There are users out there requesting increase in the IPCMNI value to
more than 32k. This patchset does that by using a boot kernel parameter
"ipcmni_extend" to increase the IPCMNI limit from 32k to 8M when that
boot command line option is specified.
To reduce the chance of id reuse, a new sysctl parameter ipcid_mode is
added for changing the way an IPC id is being generated. Currently,
three modes are supported - legacy, delete and cyclic. They differs
in the way the identifier and sequence number within an id are being
generated. This new mode is per IPC namespace.
The IPC id mode can be changed dynamically at run time, but extending
the IPCMNI number can only be done at boot time.
Patch 1 adds a "ipcmni_extend" boot command line parameter to extend
the IPCMNI limit from 32k to 8M.
Patch 2 changes how the sequence number within an id is being generated
to reduce the chance of id reuse with "ipcmni_extend".
Patch 3 decouples the new sequence generation mode into a new sysctl
parameter "ipcid_mode" so that it can be used even if "ipcmni_extend"
isn't specified.
Patch 4 adds a cyclic mode to "ipcid_mode" to allocate identifier
cyclically as well.
Waiman Long (4):
ipc: Allow boot time extension of IPCMNI from 32k to 8M
ipc: Conserve sequence numbers in extended IPCMNI mode
ipc: Make the new sequence number generation mode available to all
ipc: Add a cyclic mode for id generation
Documentation/admin-guide/kernel-parameters.txt | 3 ++
Documentation/sysctl/kernel.txt | 23 ++++++++++++
include/linux/ipc_namespace.h | 14 +++++++
ipc/ipc_sysctl.c | 25 ++++++++++++-
ipc/msg.c | 3 +-
ipc/namespace.c | 2 +
ipc/sem.c | 3 +-
ipc/shm.c | 3 +-
ipc/util.c | 41 +++++++++++++++------
ipc/util.h | 49 ++++++++++++++++++++-----
10 files changed, 140 insertions(+), 26 deletions(-)
--
1.8.3.1
next reply other threads:[~2018-11-06 1:06 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-05 15:43 Waiman Long [this message]
2018-11-05 15:43 ` [PATCH v10 1/4] ipc: Allow boot time extension of IPCMNI from 32k to 8M Waiman Long
2018-11-06 13:20 ` Matthew Wilcox
2018-11-08 21:29 ` Waiman Long
2018-11-05 15:43 ` [PATCH v10 2/4] ipc: Conserve sequence numbers in extended IPCMNI mode Waiman Long
2018-11-05 15:43 ` [PATCH v10 3/4] ipc: Make the new sequence number generation mode available to all Waiman Long
2018-11-06 4:53 ` kbuild test robot
2018-11-05 15:43 ` [PATCH v10 4/4] ipc: Add a cyclic mode for id generation Waiman Long
2018-11-06 13:02 ` Matthew Wilcox
2018-11-08 21:38 ` Waiman Long
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=1541432626-27780-1-git-send-email-longman@redhat.com \
--to=longman@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=corbet@lwn.net \
--cc=dbueso@suse.de \
--cc=ebiederm@xmission.com \
--cc=keescook@chromium.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=manfred@colorfullife.com \
--cc=mcgrof@kernel.org \
--cc=tiwai@suse.de \
--cc=viro@zeniv.linux.org.uk \
--cc=willy@infradead.org \
/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).