Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757899AbbBEPYp (ORCPT ); Thu, 5 Feb 2015 10:24:45 -0500 Received: from mx1.redhat.com ([209.132.183.28]:45967 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753311AbbBEPYo (ORCPT ); Thu, 5 Feb 2015 10:24:44 -0500 Organization: Red Hat UK Ltd. Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SI4 1TE, United Kingdom. Registered in England and Wales under Company Registration No. 3798903 From: David Howells In-Reply-To: <20150205023410.8382.13695.stgit@pluto.fritz.box> References: <20150205023410.8382.13695.stgit@pluto.fritz.box> <20150205021553.8382.16297.stgit@pluto.fritz.box> To: Ian Kent Cc: dhowells@redhat.com, Kernel Mailing List , Oleg Nesterov , Trond Myklebust , "J. Bruce Fields" , Benjamin Coddington , Al Viro , Jeff Layton , "Eric W. Biederman" Subject: Re: [RFC PATCH 3/8] kmod - teach call_usermodehelper() to use a namespace MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <12699.1423149876.1@warthog.procyon.org.uk> Date: Thu, 05 Feb 2015 15:24:36 +0000 Message-ID: <12701.1423149876@warthog.procyon.org.uk> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 895 Lines: 24 Ian Kent wrote: > To do this use the init process of the callers environment is used to setup > the namespaces in the same way the root init process is used otherwise. This probably doesn't need both "use" and "used". > +struct task_struct *umh_get_init_pid(void) > +int umh_enter_ns(struct task_struct *tsk, struct cred *new) These are exported, so should probably have doc comments. > + this = file_open_root(mnt->mnt_root, mnt, path, O_RDONLY); You probably should explain in the patch description or in a comment in the function why we're opening the ns files rather than just going directly to current->nsproxy. David -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/