From a127656dea4eaa9f2125b73268a5749b25cbbbbd Mon Sep 17 00:00:00 2001 From: kib Date: Sat, 20 Sep 2008 19:50:52 +0000 Subject: fdescfs, devfs, mqueuefs, nfs, portalfs, pseudofs, tmpfs and xfs initialize the vattr structure in VOP_GETATTR() with VATTR_NULL(), vattr_null() or by zeroing it. Remove these to allow preinitialization of fields work in vn_stat(). This is needed to get birthtime initialized correctly. Submitted by: Jaakko Heinonen Discussed on: freebsd-fs MFC after: 1 month --- sys/fs/devfs/devfs_vnops.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'sys/fs/devfs/devfs_vnops.c') diff --git a/sys/fs/devfs/devfs_vnops.c b/sys/fs/devfs/devfs_vnops.c index d56e99b..94ea0dd 100644 --- a/sys/fs/devfs/devfs_vnops.c +++ b/sys/fs/devfs/devfs_vnops.c @@ -499,8 +499,6 @@ devfs_getattr(struct vop_getattr_args *ap) KASSERT(de != NULL, ("Null dir dirent in devfs_getattr vp=%p", vp)); } - bzero((caddr_t) vap, sizeof(*vap)); - vattr_null(vap); vap->va_uid = de->de_uid; vap->va_gid = de->de_gid; vap->va_mode = de->de_mode; @@ -543,6 +541,7 @@ devfs_getattr(struct vop_getattr_args *ap) } vap->va_gen = 0; vap->va_flags = 0; + vap->va_filerev = 0; vap->va_nlink = de->de_links; vap->va_fileid = de->de_inode; -- cgit v1.1