This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] getpt: use /dev/pts/ptmx as default ptmx master
- From: Christian Brauner <christian dot brauner at canonical dot com>
- To: Phil Blundell <pb at pbcl dot net>
- Cc: Christian Brauner <christian dot brauner at ubuntu dot com>, ebiederm at xmission dot com, libc-alpha at sourceware dot org
- Date: Thu, 15 Mar 2018 15:53:33 +0100
- Subject: Re: [PATCH] getpt: use /dev/pts/ptmx as default ptmx master
- References: <20180315120651.14107-1-christian.brauner@ubuntu.com> <1521124913.18801.73.camel@pbcl.net>
On Thu, Mar 15, 2018 at 02:41:53PM +0000, Phil Blundell wrote:
> On Thu, 2018-03-15 at 13:06 +0100, Christian Brauner wrote:
> > The idea has always been to slowly fade-out /dev/ptmx and switch to using
> > /dev/pts/ptmx exclusively.
>
> What's the reason for doing that? We've had /dev/ptmx for 20 years and
> it is widely documented as the interface for opening ptys (even if it
> was never formally standardised as such). Clearly it needs to stay
> around for compatibility purposes for the foreseeable future and it's
> not really obvious to me what advantage would be gained by phasing it
> out even over the longer term. Can you elaborate?
>
> Thanks
Sure, it is **not** intended to be faded out and it never will. It will
be the fallback and it will stay there just as we have fallbacks in
other places. Sorry, if this gives the impression that something will be
faded out. This is **not** the case or intention.
Opening the ptmx device node through /dev/pts/ptmx let's the kernel
easily verify that the devpts filesystem is available especially in the
face of bind-mounts where it has to resolve the bind-mounts. And like it
or not bind-mounts of /dev/ptmx are supported and not a bug. This has
worked forever.
Christian