All of lore.kernel.org
 help / color / mirror / Atom feed
From: Cyrill Gorcunov <gorcunov@gmail.com>
To: Peter Hurley <peter@hurleysoftware.com>
Cc: LKML <linux-kernel@vger.kernel.org>, Jiri Slaby <jslaby@suse.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Andrey Vagin <avagin@virtuozzo.com>,
	Pavel Emelianov <xemul@virtuozzo.com>,
	Vladimir Davydov <vdavydov@virtuozzo.com>,
	Konstantin Khorenko <khorenko@virtuozzo.com>
Subject: Re: [PATCH resend v2] tty: n_tty -- Add new TIOCPEEKRAW ioctl to peek unread data
Date: Thu, 26 May 2016 22:32:52 +0300	[thread overview]
Message-ID: <20160526193252.GB9392@uranus> (raw)
In-Reply-To: <20160411214211.GT2000@uranus.lan>

On Tue, Apr 12, 2016 at 12:42:11AM +0300, Cyrill Gorcunov wrote:
...
> I think so. At least this gives some kind of consistensy while we're
> fetching data. Something close to peeking data from pipes/sockets.
> 
> > In that case, I think just write trylocking the termios rwsem should
> > prevent any parallel i/o, at least for the N_TTY line discipline.
> > 
> > This should only interfere with processes not being dumped because
> > ptrace signalling should have ejected any process to be dumped out
> > of their i/o loops (readers or writers).
> > 
> > Also, I think we should further limit the interface based on what is
> > supported currently; IOW, check that the driver is either pty or vt,
> > assert that the line discipline is N_TTY at both ends, etc.
> 
> Thats a good idea, thanks, will do!

It's almost a month passed, so I'm really sorry for delay in response
(been trying to implement pty c/r on userspace level together with
other stuff). Peter, I believe your initial idea of fetching data
via native read inside criu works well for us so far. We've been
playing with tests and they are passing just fine. Thanks a huge
for all your comments and overall help!

	Cyrill

      reply	other threads:[~2016-05-26 19:32 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-07 12:53 [PATCH resend v2] tty: n_tty -- Add new TIOCPEEKRAW ioctl to peek unread data Cyrill Gorcunov
2016-04-11  5:43 ` Peter Hurley
2016-04-11  9:01   ` Cyrill Gorcunov
2016-04-11 17:20     ` Peter Hurley
2016-04-11 21:42       ` Cyrill Gorcunov
2016-05-26 19:32         ` Cyrill Gorcunov [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=20160526193252.GB9392@uranus \
    --to=gorcunov@gmail.com \
    --cc=avagin@virtuozzo.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=jslaby@suse.com \
    --cc=khorenko@virtuozzo.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=peter@hurleysoftware.com \
    --cc=vdavydov@virtuozzo.com \
    --cc=xemul@virtuozzo.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 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.