Date: Wed, 17 Apr 2002 13:31:19 -0700 From: Alfred Perlstein <alfred@freebsd.org> To: fs@freebsd.org Cc: mckusick@freebsd.org Subject: "notime fix" (forw) what do you think of this? Message-ID: <20020417203119.GA90826@elvis.mu.org>
next in thread | raw e-mail | index | archive | help
it's a hack to make ufs_vnops update atime if it is going to update mtime or ctime. I think this sort of makes sense, it allows one to run noatime to get good speed without the filesystem getting all "wonky" because access times aren't updated when they should be. ----- Forwarded message from Nick Johnson <spatula@spatula.net> ----- From: Nick Johnson <spatula@spatula.net> To: al <bright@wintelcom.net> Subject: what do you think of this? Date: Wed, 17 Apr 2002 13:05:08 -0700 (PDT) Message-ID: <Pine.BSF.4.30.0204171304250.1596-100000@yitiya.pair.com> --- ufs_vnops.c.orig Wed Apr 17 12:55:37 2002 +++ ufs_vnops.c Wed Apr 17 13:00:58 2002 @@ -162,6 +162,17 @@ ip->i_flag |= IN_LAZYMOD; else ip->i_flag |= IN_MODIFIED; + /* + * If we're going to be updating or changing, + * it makes sense that we're accessing as well. + * This changes the traditional semantics of + * mount -o noatime slightly. + */ + if (!(ip->i_flag & IN_ACCESS) && + ((ip->i_flag & IN_UPDATE) || + (ip->i_flag & IN_CHANGE))) { + ip->i_flag |= IN_ACCESS; + } if (ip->i_flag & IN_ACCESS) { ip->i_atime = ts.tv_sec; ip->i_atimensec = ts.tv_nsec; -- "The aptly-named morons.org is an obscenity-laced screed..." -- Robert P. Lockwood, Catholic League director of research Nick Johnson, version 2.0 http://www.spatula.net/ ----- End forwarded message ----- -- -Alfred Perlstein [alfred@freebsd.org] 'Instead of asking why a piece of software is using "1970s technology," start asking why software is ignoring 30 years of accumulated wisdom.' Tax deductible donations for FreeBSD: http://www.freebsdfoundation.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-fs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020417203119.GA90826>