2
Subject: Export namespace semaphore
5
Export global namespace_sem (this used to be a per namespace semaphore).
6
Alas, this isn't going to win _any_ points for style.
7
Patch is not in mainline -- pending AppArmor code submission to lkml
9
Index: linux-2.6.15/fs/namespace.c
10
===================================================================
11
--- linux-2.6.15.orig/fs/namespace.c
12
+++ linux-2.6.15/fs/namespace.c
13
@@ -46,7 +46,8 @@ static int event;
14
static struct list_head *mount_hashtable;
15
static int hash_mask __read_mostly, hash_bits __read_mostly;
16
static kmem_cache_t *mnt_cache;
17
-static struct rw_semaphore namespace_sem;
18
+struct rw_semaphore namespace_sem;
19
+EXPORT_SYMBOL_GPL(namespace_sem);
22
decl_subsys(fs, NULL, NULL);
23
Index: linux-2.6.15/include/linux/namespace.h
24
===================================================================
25
--- linux-2.6.15.orig/include/linux/namespace.h
26
+++ linux-2.6.15/include/linux/namespace.h
28
#include <linux/mount.h>
29
#include <linux/sched.h>
31
+/* exported for AppArmor (SubDomain) */
32
+extern struct rw_semaphore namespace_sem;
36
struct vfsmount * root;