[RFC] fix devpts mount behavior

Kay Sievers kay.sievers at vrfy.org
Sat Jan 28 21:32:06 UTC 2012


On Sat, Jan 28, 2012 at 21:52, Eric W. Biederman <ebiederm at xmission.com> wrote:
> Serge Hallyn <serge.hallyn at canonical.com> writes:
>
>> Quoting Kay Sievers (kay.sievers at vrfy.org):
>>> We might also thing about changing /sys/class/tty/ptmx/, and have the
>>> kernel create the symlink? The loops through userspace to setup
>>> default kernel stuff are kind of crazy ...

>> sorry, there is something I'm missing here.  Without a target kobj
>> to link to, how would we go about telling the kernel that /dev/ptmx
>> should be a symlink to /dev/pts/ptmx?  Is there a way to do that?

There is no support for symlinks in the core at the moment. But I
guess we could just add support for it to the driver core and devtmpfs
to create a symlink in /dev instead of a device node.

The ptmx device would need to pass that information along to the
driver core call when creating the ptmx device.

> There is precedent in the /dev/fd symlinks, so I expect you want
> to look and see where the configuration for that comes from.

That's a static list of stuff created at startup. But it's easier to
do in usersace, because /proc is not configurable or optional for
usual use cases, so we can just do it unconditionally in userspace.
They also can not conflict with device nodes.

Kay


More information about the Containers mailing list