Re: tty idle time and hooking inode_ops from a chardev

From: Phillip Susi
Date: Fri Dec 16 2011 - 13:22:07 EST


On 12/16/2011 12:57 PM, Greg KH wrote:
Don't worry about it, as it's not really an important issue at all? :)

That's why it has been broken for years; because nobody cares enough about it to fix it, but that kind of thing irks me.

It seems that your userspace programs aren't properly measuring the
correct thing here, it's not that the kernel is doing something wrong,
right?

I thought so at first, but it appears that the tty layer was originally written specifically to work this way.

And atime on a character node is pretty undefined, isn't it?

Is it? I would have thought so but after looking at all of this code, it looks like it is one of those things that has just been around for decades, but nobody knows about, kind of like FIONREAD.

I wonder if that's how who has always worked going back to AT&T Unix. If it is, then I'd like to stick with it ( but fix it ) rather than say, add an ioctl to read the idle time and change coreutils to use that instead.
--
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/