]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - kernel/utsname.c
make proc_ns_operations work with struct ns_common * instead of void *
[karo-tx-linux.git] / kernel / utsname.c
index 1917f74be8ecedba6bf80e1191bbdec3ea2b3113..20697befe46632fd2d08fa7df1273b0b905f588e 100644 (file)
@@ -93,7 +93,7 @@ static inline struct uts_namespace *to_uts_ns(struct ns_common *ns)
        return container_of(ns, struct uts_namespace, ns);
 }
 
-static void *utsns_get(struct task_struct *task)
+static struct ns_common *utsns_get(struct task_struct *task)
 {
        struct uts_namespace *ns = NULL;
        struct nsproxy *nsproxy;
@@ -109,12 +109,12 @@ static void *utsns_get(struct task_struct *task)
        return ns ? &ns->ns : NULL;
 }
 
-static void utsns_put(void *ns)
+static void utsns_put(struct ns_common *ns)
 {
        put_uts_ns(to_uts_ns(ns));
 }
 
-static int utsns_install(struct nsproxy *nsproxy, void *new)
+static int utsns_install(struct nsproxy *nsproxy, struct ns_common *new)
 {
        struct uts_namespace *ns = to_uts_ns(new);
 
@@ -128,16 +128,10 @@ static int utsns_install(struct nsproxy *nsproxy, void *new)
        return 0;
 }
 
-static unsigned int utsns_inum(void *vp)
-{
-       return ((struct ns_common *)vp)->inum;
-}
-
 const struct proc_ns_operations utsns_operations = {
        .name           = "uts",
        .type           = CLONE_NEWUTS,
        .get            = utsns_get,
        .put            = utsns_put,
        .install        = utsns_install,
-       .inum           = utsns_inum,
 };