From owner-freebsd-current Wed Aug 23 11:51:42 2000 Delivered-To: freebsd-current@freebsd.org Received: from critter.freebsd.dk (beachchick.freebsd.dk [212.242.34.254]) by hub.freebsd.org (Postfix) with ESMTP id 373A837B42C for ; Wed, 23 Aug 2000 11:51:34 -0700 (PDT) Received: from critter (localhost [127.0.0.1]) by critter.freebsd.dk (8.9.3/8.9.3) with ESMTP id UAA04854; Wed, 23 Aug 2000 20:51:28 +0200 (CEST) (envelope-from phk@critter.freebsd.dk) To: Siobhan Patricia Lynch Cc: freebsd-current@FreeBSD.ORG Subject: Re: weirdness with devfs? (time) In-Reply-To: Your message of "Wed, 23 Aug 2000 14:35:58 EDT." Date: Wed, 23 Aug 2000 20:51:28 +0200 Message-ID: <4852.967056688@critter> From: Poul-Henning Kamp Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In message , Siobhan Patricia Lynch writes: >On Wed, 23 Aug 2000, Poul-Henning Kamp wrote: > >> In message , >> Siobhan Patricia Lynch writes: >> >this is cute: >> >notice the dates, they predate the epoch. >> >> Because of your timezone. >> > >nod, figured that out already, however, is the epoch date intentional? No. I'm working on that issue right now. If you look in sys/ufs/ufs/ufs_vnops.c:ufs_spec{read|write}() you will see that the filesystem "hosting" the device node has to figure out for itself when to update the ACCESS, UPDATE and CHANGE timestamps relative to the access to the dev_t through specfs. Obviously wrong since all device node hosting filesystems (ufs, ext2fs, devfs cd9660 (well, not really but in principle...)) will have to duplicate that code. I'm looking at a patch right now which adds three flag bits to the dev_t and clone this code into sys/miscfs/specfs() where it will maintain these three bits. The hosting filesystem can then examine just those bits to determine when timestamps should be updated. The advantage to this scheme is that the drivers themselves can set these bits when for instance ioctl functions have "updated" or "accessed" the device. The secondary advantage is that we don't have to have this code mutated in multiple filesystems. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD coreteam member | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message