diff options
author | Eric W. Biederman <ebiederm@xmission.com> | 2010-05-04 20:36:45 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-05-21 12:37:32 -0400 |
commit | 608b4b9548dedf4185ca47edcaae4bff2ceb62de (patch) | |
tree | 6855a119e99a4e0142c17b8cc4aa08968f3f6ab6 /include/linux/kobject.h | |
parent | 07e98962fa778b9782c8845dfcb06a84cc050744 (diff) |
netns: Teach network device kobjects which namespace they are in.
The problem. Network devices show up in sysfs and with the network
namespace active multiple devices with the same name can show up in
the same directory, ouch!
To avoid that problem and allow existing applications in network namespaces
to see the same interface that is currently presented in sysfs, this
patch enables the tagging directory support in sysfs.
By using the network namespace pointers as tags to separate out the
the sysfs directory entries we ensure that we don't have conflicts
in the directories and applications only see a limited set of
the network devices.
Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Acked-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'include/linux/kobject.h')
-rw-r--r-- | include/linux/kobject.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/kobject.h b/include/linux/kobject.h index b60d2dfe4e69..cf343a852534 100644 --- a/include/linux/kobject.h +++ b/include/linux/kobject.h | |||
@@ -142,6 +142,7 @@ extern const struct sysfs_ops kobj_sysfs_ops; | |||
142 | */ | 142 | */ |
143 | enum kobj_ns_type { | 143 | enum kobj_ns_type { |
144 | KOBJ_NS_TYPE_NONE = 0, | 144 | KOBJ_NS_TYPE_NONE = 0, |
145 | KOBJ_NS_TYPE_NET, | ||
145 | KOBJ_NS_TYPES | 146 | KOBJ_NS_TYPES |
146 | }; | 147 | }; |
147 | 148 | ||