summaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel
diff options
context:
space:
mode:
authorAl Viro2019-05-12 18:42:58 +0200
committerAl Viro2019-05-25 23:59:54 +0200
commitf7a9945184100b531f0de3b12c617a349236dd8a (patch)
treebe83490fcfad13c338adb4973a72ed923695f249 /arch/x86/kernel
parentmount_pseudo(): drop 'name' argument, switch to d_make_root() (diff)
downloadkernel-qcow2-linux-f7a9945184100b531f0de3b12c617a349236dd8a.tar.gz
kernel-qcow2-linux-f7a9945184100b531f0de3b12c617a349236dd8a.tar.xz
kernel-qcow2-linux-f7a9945184100b531f0de3b12c617a349236dd8a.zip
no need to protect against put_user_ns(NULL)
it's a no-op Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'arch/x86/kernel')
-rw-r--r--arch/x86/kernel/cpu/resctrl/rdtgroup.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/x86/kernel/cpu/resctrl/rdtgroup.c b/arch/x86/kernel/cpu/resctrl/rdtgroup.c
index 333c177a2471..68bd609026e6 100644
--- a/arch/x86/kernel/cpu/resctrl/rdtgroup.c
+++ b/arch/x86/kernel/cpu/resctrl/rdtgroup.c
@@ -2108,8 +2108,7 @@ static int rdt_init_fs_context(struct fs_context *fc)
ctx->kfc.magic = RDTGROUP_SUPER_MAGIC;
fc->fs_private = &ctx->kfc;
fc->ops = &rdt_fs_context_ops;
- if (fc->user_ns)
- put_user_ns(fc->user_ns);
+ put_user_ns(fc->user_ns);
fc->user_ns = get_user_ns(&init_user_ns);
fc->global = true;
return 0;