aboutsummaryrefslogtreecommitdiff
path: root/sys/gnu/fs/ext2fs
diff options
context:
space:
mode:
authorPoul-Henning Kamp <phk@FreeBSD.org>2004-09-07 09:17:05 +0000
committerPoul-Henning Kamp <phk@FreeBSD.org>2004-09-07 09:17:05 +0000
commit1affa3adc82a89fb52a7ec86ad5caf03a5caf622 (patch)
tree7e7bb052b21a301fd0dd0598358f0d815c6f142b /sys/gnu/fs/ext2fs
parent35f134080f66c7b325d5281467a6ec45d7b443ce (diff)
downloadsrc-1affa3adc82a89fb52a7ec86ad5caf03a5caf622.tar.gz
src-1affa3adc82a89fb52a7ec86ad5caf03a5caf622.zip
Create simple function init_va_filerev() for initializing a va_filerev
field. Replace three instances of longhaired initialization va_filerev fields. Added XXX comment wondering why we don't use random bits instead of uptime of the system for this purpose.
Notes
Notes: svn path=/head/; revision=134899
Diffstat (limited to 'sys/gnu/fs/ext2fs')
-rw-r--r--sys/gnu/fs/ext2fs/ext2_vnops.c25
1 files changed, 1 insertions, 24 deletions
diff --git a/sys/gnu/fs/ext2fs/ext2_vnops.c b/sys/gnu/fs/ext2fs/ext2_vnops.c
index cf04778ad9f8..b3441734e74b 100644
--- a/sys/gnu/fs/ext2fs/ext2_vnops.c
+++ b/sys/gnu/fs/ext2fs/ext2_vnops.c
@@ -201,23 +201,6 @@ static struct vnodeopv_desc ext2fs_fifoop_opv_desc =
#include <gnu/ext2fs/ext2_readwrite.c>
-union _qcvt {
- int64_t qcvt;
- int32_t val[2];
-};
-#define SETHIGH(q, h) { \
- union _qcvt tmp; \
- tmp.qcvt = (q); \
- tmp.val[_QUAD_HIGHWORD] = (h); \
- (q) = tmp.qcvt; \
-}
-#define SETLOW(q, l) { \
- union _qcvt tmp; \
- tmp.qcvt = (q); \
- tmp.val[_QUAD_LOWWORD] = (l); \
- (q) = tmp.qcvt; \
-}
-
/*
* A virgin directory (no blushing please).
* Note that the type and namlen fields are reversed relative to ext2.
@@ -1741,7 +1724,6 @@ ext2_vinit(mntp, specops, fifoops, vpp)
{
struct inode *ip;
struct vnode *vp;
- struct timeval tv;
vp = *vpp;
ip = VTOI(vp);
@@ -1763,12 +1745,7 @@ ext2_vinit(mntp, specops, fifoops, vpp)
}
if (ip->i_number == ROOTINO)
vp->v_vflag |= VV_ROOT;
- /*
- * Initialize modrev times
- */
- getmicrouptime(&tv);
- SETHIGH(ip->i_modrev, tv.tv_sec);
- SETLOW(ip->i_modrev, tv.tv_usec * 4294);
+ ip->i_modrev = init_va_filerev();
*vpp = vp;
return (0);
}