mirror of
https://github.com/torvalds/linux.git
synced 2026-05-30 00:29:35 +08:00
ns: use NS_COMMON_INIT() for all namespaces
Now that we have a common initializer use it for all static namespaces. Signed-off-by: Christian Brauner <brauner@kernel.org>
This commit is contained in:
@@ -71,21 +71,16 @@ static int pid_max_max = PID_MAX_LIMIT;
|
||||
* the scheme scales to up to 4 million PIDs, runtime.
|
||||
*/
|
||||
struct pid_namespace init_pid_ns = {
|
||||
.ns.__ns_ref = REFCOUNT_INIT(2),
|
||||
.ns = NS_COMMON_INIT(init_pid_ns, 2),
|
||||
.idr = IDR_INIT(init_pid_ns.idr),
|
||||
.pid_allocated = PIDNS_ADDING,
|
||||
.level = 0,
|
||||
.child_reaper = &init_task,
|
||||
.user_ns = &init_user_ns,
|
||||
.ns.inum = ns_init_inum(&init_pid_ns),
|
||||
#ifdef CONFIG_PID_NS
|
||||
.ns.ops = &pidns_operations,
|
||||
#endif
|
||||
.pid_max = PID_MAX_DEFAULT,
|
||||
#if defined(CONFIG_SYSCTL) && defined(CONFIG_MEMFD_CREATE)
|
||||
.memfd_noexec_scope = MEMFD_NOEXEC_SCOPE_EXEC,
|
||||
#endif
|
||||
.ns.ns_type = ns_common_type(&init_pid_ns),
|
||||
};
|
||||
EXPORT_SYMBOL_GPL(init_pid_ns);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user