[Devel] [PATCH 1/4] namespaces: make get_nsproxy nonstatic
Serge E. Hallyn
serue at us.ibm.com
Mon Feb 19 14:15:36 PST 2007
From: Serge E. Hallyn <serue at us.ibm.com>
Subject: [PATCH 1/4] namespaces: make get_nsproxy nonstatic
We'll need get_nsproxy accessible from containers code, but it is
statically defined in kernel/nsproxy.c. Make it inline in
include/linux/nsproxy.h.
Signed-off-by: Serge E. Hallyn <serue at us.ibm.com>
---
include/linux/nsproxy.h | 5 +++++
kernel/nsproxy.c | 5 -----
2 files changed, 5 insertions(+), 5 deletions(-)
ad2cf2568b8fe9cf094905ec7370149baafc6495
diff --git a/include/linux/nsproxy.h b/include/linux/nsproxy.h
index c55f20b..0255e27 100644
--- a/include/linux/nsproxy.h
+++ b/include/linux/nsproxy.h
@@ -31,6 +31,11 @@ struct nsproxy {
};
extern struct nsproxy init_nsproxy;
+static inline void get_nsproxy(struct nsproxy *ns)
+{
+ atomic_inc(&ns->count);
+}
+
struct nsproxy *dup_namespaces(struct nsproxy *orig);
int copy_namespaces(int flags, struct task_struct *tsk);
void get_task_namespaces(struct task_struct *tsk);
diff --git a/kernel/nsproxy.c b/kernel/nsproxy.c
index d174d1f..1123ab2 100644
--- a/kernel/nsproxy.c
+++ b/kernel/nsproxy.c
@@ -23,11 +23,6 @@
struct nsproxy init_nsproxy = INIT_NSPROXY(init_nsproxy);
-static inline void get_nsproxy(struct nsproxy *ns)
-{
- atomic_inc(&ns->count);
-}
-
void get_task_namespaces(struct task_struct *tsk)
{
struct nsproxy *ns = tsk->nsproxy;
--
1.1.6
More information about the Devel
mailing list