]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/linux/namespace.h
[PATCH] swsusp: Improve handling of highmem
[linux-2.6-omap-h63xx.git] / include / linux / namespace.h
index 0e5a86f13b2f8b4bbac4b50f32836827fef9fae8..d137009f0b2be0feb70efcffba537f899195865d 100644 (file)
@@ -4,16 +4,19 @@
 
 #include <linux/mount.h>
 #include <linux/sched.h>
+#include <linux/nsproxy.h>
 
 struct namespace {
        atomic_t                count;
        struct vfsmount *       root;
        struct list_head        list;
-       struct rw_semaphore     sem;
+       wait_queue_head_t poll;
+       int event;
 };
 
 extern int copy_namespace(int, struct task_struct *);
 extern void __put_namespace(struct namespace *namespace);
+extern struct namespace *dup_namespace(struct task_struct *, struct fs_struct *);
 
 static inline void put_namespace(struct namespace *namespace)
 {
@@ -24,11 +27,8 @@ static inline void put_namespace(struct namespace *namespace)
 
 static inline void exit_namespace(struct task_struct *p)
 {
-       struct namespace *namespace = p->namespace;
+       struct namespace *namespace = p->nsproxy->namespace;
        if (namespace) {
-               task_lock(p);
-               p->namespace = NULL;
-               task_unlock(p);
                put_namespace(namespace);
        }
 }