From f540f245de4d7c19cf014c513dac60b99e472571 Mon Sep 17 00:00:00 2001 From: Xiaoming Gao Date: Tue, 21 Jan 2020 12:08:58 +0800 Subject: [PATCH] vm: fix isolate max_map_count, inherit the value of the parent namespace instead Signed-off-by: Xiaoming Gao --- kernel/pid_namespace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/pid_namespace.c b/kernel/pid_namespace.c index 01b2d3644..7b5ce005e 100644 --- a/kernel/pid_namespace.c +++ b/kernel/pid_namespace.c @@ -137,7 +137,7 @@ static struct pid_namespace *create_pid_namespace(struct user_namespace *user_ns ns->user_ns = get_user_ns(user_ns); ns->ucounts = ucounts; ns->nr_hashed = PIDNS_HASH_ADDING; - ns->max_map_count = DEFAULT_MAX_MAP_COUNT; + ns->max_map_count = parent_pid_ns->max_map_count; INIT_WORK(&ns->proc_work, proc_cleanup_work); set_bit(0, ns->pidmap[0].page);