Re: [RFC] tty: Add get- ioctls to fetch tty status
From: H. Peter Anvin
Date: Thu Sep 27 2012 - 10:18:01 EST
On 09/27/2012 07:14 AM, Cyrill Gorcunov wrote:
On Thu, Sep 27, 2012 at 03:14:47PM +0100, Alan Cox wrote:
Alan, Greg, what's opinion? This flags fetching is the same as say fetching
of termios settings, once fetched they can be changed immediately, and it's
up to caller what to do with termios settings. No?
I think you need to explain what you expect to be doing with it, and why
it is safe in that application.
OK, it seems it was unclear from changelog. We need to know this parameters
to be able to restore tty connection after checkpoint.
While we easily can fetch termios settings and such, there are few bits which
are missed to expord. So this patch provides them to user-space.
What bothers me (and the same applies to termios) is that you have NO
idea if your particular process is the "owner" of that tty. tty users
use out-of-band protocols, often implicit, to determine which process
"owns" the tty state.
If you can't guarantee that ALL those processes are stopped and
checkpointed/restarted, you have a huge problem.
-hpa
--
H. Peter Anvin, Intel Open Source Technology Center
I work for Intel. I don't speak on their behalf.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/