Don't cargo-cult the same thing over and over.

Reviewed-by: Jan Kara <[email protected]>
Signed-off-by: Christian Brauner <[email protected]>
---
 ipc/namespace.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/ipc/namespace.c b/ipc/namespace.c
index 4df91ceeeafe..d4188a88ee57 100644
--- a/ipc/namespace.c
+++ b/ipc/namespace.c
@@ -61,12 +61,10 @@ static struct ipc_namespace *create_ipc_ns(struct 
user_namespace *user_ns,
        if (ns == NULL)
                goto fail_dec;
 
-       err = ns_alloc_inum(&ns->ns);
+       err = ns_common_init(&ns->ns, &ipcns_operations, true);
        if (err)
                goto fail_free;
-       ns->ns.ops = &ipcns_operations;
 
-       refcount_set(&ns->ns.count, 1);
        ns->user_ns = get_user_ns(user_ns);
        ns->ucounts = ucounts;
 

-- 
2.47.3


Reply via email to