Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[PATCH] nanosecond resolution for stat(2)

2 views
Skip to first unread message

Linus Torvalds

unread,
Sep 23, 2002, 3:11:45 PM9/23/02
to Andi Kleen, linux-...@vger.kernel.org

On Mon, 23 Sep 2002, Andi Kleen wrote:
>
> Some drivers (like mouse drivers or tty) do dubious inode [mac] time
> accesses of the on disk inode and without even marking it dirty. This is
> likely a bug.

No, it is intentional. At least some versions of "w" (maybe all) will use
the tty access times to judge how long the tty has been idle. The point is
that this is all information that is interesting (and useful), but not
worth sending to disk - it is useful only as long as the inode remains
locked in-core for other reasons, ie being in use.

(It's not only "not worth it" to send to disk, but it would be positively
wrong to even _try_ updating the disk with the access times, since we want
these things to work even with a read-only /dev).

Linus

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majo...@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

Andi Kleen

unread,
Sep 23, 2002, 4:08:19 PM9/23/02
to Linus Torvalds, Andi Kleen, linux-...@vger.kernel.org
On Mon, Sep 23, 2002 at 08:57:32PM +0200, Linus Torvalds wrote:
>
> On Mon, 23 Sep 2002, Andi Kleen wrote:
> >
> > Some drivers (like mouse drivers or tty) do dubious inode [mac] time
> > accesses of the on disk inode and without even marking it dirty. This is
> > likely a bug.
>
> No, it is intentional. At least some versions of "w" (maybe all) will use
> the tty access times to judge how long the tty has been idle. The point is
> that this is all information that is interesting (and useful), but not
> worth sending to disk - it is useful only as long as the inode remains
> locked in-core for other reasons, ie being in use.
>
> (It's not only "not worth it" to send to disk, but it would be positively
> wrong to even _try_ updating the disk with the access times, since we want
> these things to work even with a read-only /dev).

Ok. But it is surely not needed for mouse drivers, isn't it ?
(I removed a few updates in them)

I didn't change tty in this regard anyways.

Would you consider to merge the patch ?

-Andi

Message has been deleted
0 new messages