kernel: pid_namespace: Add kernel-doc comments
PATCH 1/1 kernel: pid_namespace: Add kernel-doc comments
Add kernel-doc comments for functions.
Signed-off-by sayli karnik <[email protected]>
--- kernel/pid_namespace.c | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-)
kernel/pid_namespace.c +20 -1
@@ -91,7 +91,11 @@ static void dec_pid_namespaces(struct ucounts *ucounts) {dec_ucount (ucounts,UCOUNT_PID_NAMESPACES ); } - +/** +* create_pid_namespace - creates a new pid namespace +* @user_namespace: current user namespace +* @parent_pid_namespace: parent of the user namespace +*/ static struct pid_namespace *create_pid_namespace (struct user_namespace *user_ns,struct pid_namespace *parent_pid_ns) {
@@ -162,6 +166,11 @@ static void delayed_free_pidns(struct rcu_head *p)kmem_cache_free (pid_ns_cachep, ns); } +/** +* destroy_pid_namespace - Destroys the pid namespace +* @ns: namespace to be destroyed +* +*/ static void destroy_pid_namespace (struct pid_namespace *ns) {int i;
@@ -172,6 +181,12 @@ static void destroy_pid_namespace(struct pid_namespace *ns)call_rcu (&ns->rcu, delayed_free_pidns); } +/** +* copy_pid_ns - makes a copy of the pid namespace +* @user_ns: new namespace to be created +* @old_ns: namespace to be copied +* +*/ struct pid_namespace *copy_pid_ns (unsigned long flags,struct user_namespace *user_ns,struct pid_namespace *old_ns) {
@@ -182,6 +197,10 @@ struct pid_namespace *copy_pid_ns(unsigned long flags,return create_pid_namespace (user_ns, old_ns); } +/** +* free_pid_ns - frees memory allocated to the pid namespace +* @kref: reference of pid namespace to be freed +*/ static void free_pid_ns (struct kref *kref) {struct pid_namespace *ns;
Signature · 1 line
2.7.4