From: Benjamin Thery <benjamin.thery@bull.net>
To: Greg KH <gregkh@suse.de>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Eric Biederman <ebiederm@xmission.com>,
Serge Hallyn <serue@us.ibm.com>,
linux-kernel@vger.kernel.org, Tejun Heo <htejun@gmail.com>,
Al Viro <viro@ftp.linux.org.uk>,
Daniel Lezcano <dlezcano@fr.ibm.com>
Subject: Re: [PATCH 09/10] netns: Enable tagging for net_class directories in sysfs
Date: Tue, 03 Jun 2008 17:24:21 +0200 [thread overview]
Message-ID: <48456225.6070505@bull.net> (raw)
In-Reply-To: <20080603040818.GA18507@suse.de>
Greg KH wrote:
> On Mon, Jun 02, 2008 at 03:46:08PM +0200, Benjamin Thery wrote:
>> net: Enable tagging for net_class directories in sysfs
>>
>> 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.
>
> I don't like it how the network subsystem is starting to leach into the
> sysfs core here. What happens when the next subsystem wants to do the
> same thing? And then the next one? Will they all have to do this kind
> of intrusive changes to sysfs?
>
> Can't this be done only in the network subsystem?
I'm not sure to understand exactly what you mean.
What you don't like is seeing these hunks of network code in
fs/sysfs/mount.c? And you prefer to see these bits of code resides in
the network subsystem instead and see only "generic" sysfs services in
fs/sysfs/mount.c?
If this is it, I have some idea to implement a less intrusive
sysfs_net_exit(), which can be shared with the other namespaces.
Serge introduces the same kind of changes in patch 10 to fix an issue in
user namespace. I think we can share a bit of code and move the parts
specific to each namespace in their own subsystems.
Benjamin
>
> thanks,
>
> greg k-h
>
>
--
B e n j a m i n T h e r y - BULL/DT/Open Software R&D
http://www.bull.com
next prev parent reply other threads:[~2008-06-03 15:24 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-06-02 13:44 [PATCH 00/10] sysfs tagged directories V4 Benjamin Thery
2008-06-02 13:44 ` [PATCH 01/10] sysfs: Support for preventing unmounts Benjamin Thery
2008-06-02 13:44 ` [PATCH 02/10] sysfs: sysfs_get_dentry add a sb parameter Benjamin Thery
2008-06-02 13:45 ` [PATCH 03/10] sysfs: Implement __sysfs_get_dentry Benjamin Thery
2008-06-02 13:45 ` [PATCH 04/10] sysfs: Rename Support multiple superblocks Benjamin Thery
2008-06-02 13:45 ` [PATCH 05/10] sysfs: sysfs_chmod_file handle " Benjamin Thery
2008-06-02 13:45 ` [PATCH 06/10] sysfs: Implement sysfs tagged directory support Benjamin Thery
2008-06-02 13:45 ` [PATCH 07/10] sysfs: Implement sysfs_delete_link and sysfs_rename_link Benjamin Thery
2008-06-02 13:45 ` [PATCH 08/10] driver core: Implement tagged directory support for device classes Benjamin Thery
2008-06-02 13:46 ` [PATCH 09/10] netns: Enable tagging for net_class directories in sysfs Benjamin Thery
2008-06-03 4:08 ` Greg KH
2008-06-03 12:16 ` Serge E. Hallyn
2008-06-03 15:24 ` Benjamin Thery [this message]
2008-06-03 16:35 ` Greg KH
2008-06-03 19:10 ` Benjamin Thery
2008-06-02 13:46 ` [PATCH 10/10] sysfs: user namespaces: fix bug with clone(CLONE_NEWUSER) with fairsched Benjamin Thery
2008-06-02 19:24 ` Serge E. Hallyn
2008-06-02 21:17 ` [PATCH 00/10] sysfs tagged directories V4 Dan Smith
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=48456225.6070505@bull.net \
--to=benjamin.thery@bull.net \
--cc=akpm@linux-foundation.org \
--cc=dlezcano@fr.ibm.com \
--cc=ebiederm@xmission.com \
--cc=gregkh@suse.de \
--cc=htejun@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=serue@us.ibm.com \
--cc=viro@ftp.linux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.