diff options
Diffstat (limited to 'include/linux/utsname.h')
-rw-r--r-- | include/linux/utsname.h | 19 |
1 files changed, 4 insertions, 15 deletions
diff --git a/include/linux/utsname.h b/include/linux/utsname.h index e10267d402c5..f8d3b326e93a 100644 --- a/include/linux/utsname.h +++ b/include/linux/utsname.h | |||
@@ -49,9 +49,7 @@ static inline void get_uts_ns(struct uts_namespace *ns) | |||
49 | } | 49 | } |
50 | 50 | ||
51 | #ifdef CONFIG_UTS_NS | 51 | #ifdef CONFIG_UTS_NS |
52 | extern int unshare_utsname(unsigned long unshare_flags, | 52 | extern struct uts_namespace *copy_utsname(int flags, struct uts_namespace *ns); |
53 | struct uts_namespace **new_uts); | ||
54 | extern int copy_utsname(int flags, struct task_struct *tsk); | ||
55 | extern void free_uts_ns(struct kref *kref); | 53 | extern void free_uts_ns(struct kref *kref); |
56 | 54 | ||
57 | static inline void put_uts_ns(struct uts_namespace *ns) | 55 | static inline void put_uts_ns(struct uts_namespace *ns) |
@@ -59,21 +57,12 @@ static inline void put_uts_ns(struct uts_namespace *ns) | |||
59 | kref_put(&ns->kref, free_uts_ns); | 57 | kref_put(&ns->kref, free_uts_ns); |
60 | } | 58 | } |
61 | #else | 59 | #else |
62 | static inline int unshare_utsname(unsigned long unshare_flags, | 60 | static inline struct uts_namespace *copy_utsname(int flags, |
63 | struct uts_namespace **new_uts) | 61 | struct uts_namespace *ns) |
64 | { | 62 | { |
65 | if (unshare_flags & CLONE_NEWUTS) | 63 | return ns; |
66 | return -EINVAL; | ||
67 | |||
68 | return 0; | ||
69 | } | 64 | } |
70 | 65 | ||
71 | static inline int copy_utsname(int flags, struct task_struct *tsk) | ||
72 | { | ||
73 | if (flags & CLONE_NEWUTS) | ||
74 | return -EINVAL; | ||
75 | return 0; | ||
76 | } | ||
77 | static inline void put_uts_ns(struct uts_namespace *ns) | 66 | static inline void put_uts_ns(struct uts_namespace *ns) |
78 | { | 67 | { |
79 | } | 68 | } |