From: Greg KH <gregkh@linuxfoundation.org>
To: Masatake YAMATO <yamato@redhat.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] pty: show associative slave of ptmx in fdinfo
Date: Mon, 28 Aug 2017 16:37:13 +0200 [thread overview]
Message-ID: <20170828143713.GA28831@kroah.com> (raw)
In-Reply-To: <20170717212759.21938-1-yamato@redhat.com>
On Tue, Jul 18, 2017 at 06:27:59AM +0900, Masatake YAMATO wrote:
> This patch adds "tty-index" field to /proc/PID/fdinfo/N if N
> specifies /dev/ptmx. The field shows the index of associative
> slave pts.
>
> Though a minor number is given for each pts instance, ptmx is not.
> It means there is no way in user-space to know the association between
> file descriptors for pts/n and ptmx. (n = 0, 1, ...)
>
> This is different from pipe. About pipe such association can be solved
> by inode of pipefs.
>
> Providing the way to know the association between pts/n and ptmx helps
> users understand the status of running system. lsof can utilize this field.
>
> Signed-off-by: Masatake YAMATO <yamato@redhat.com>
> ---
> drivers/tty/pty.c | 8 +++++++-
> drivers/tty/tty_io.c | 9 +++++++++
> include/linux/tty_driver.h | 2 ++
> 3 files changed, 18 insertions(+), 1 deletion(-)
Sorry for the delay, now applied.
greg k-h
prev parent reply other threads:[~2017-08-28 14:37 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-17 21:27 [PATCH v2] pty: show associative slave of ptmx in fdinfo Masatake YAMATO
2017-08-28 14:37 ` Greg KH [this message]
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=20170828143713.GA28831@kroah.com \
--to=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=yamato@redhat.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox