• S
    pid namespaces: introduce struct upid · 4c3f2ead
    Sukadev Bhattiprolu 提交于
    Since task will be visible from different pid namespaces each of them have to
    be addressed by multiple pids.  struct upid is to store the information about
    which id refers to which namespace.
    
    The constuciton looks like this.  Each struct pid carried the reference
    counter and the list of tasks attached to this pid.  At its end it has a
    variable length array of struct upid-s.  Each struct upid has a numerical id
    (pid itself), pointer to the namespace, this ID is valid in and is hashed into
    a pid_hash for searching the pids.
    
    The nr and pid_chain fields are kept in struct pid for a while to make kernel
    still work (no patch initialize the upids yet), but it will be removed at the
    end of this series when we switch to upids completely.
    Signed-off-by: NSukadev Bhattiprolu <sukadev@us.ibm.com>
    Signed-off-by: NPavel Emelyanov <xemul@openvz.org>
    Cc: Oleg Nesterov <oleg@tv-sign.ru>
    Cc: Paul Menage <menage@google.com>
    Cc: "Eric W. Biederman" <ebiederm@xmission.com>
    Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
    4c3f2ead
init_task.h 5.4 KB