afs: Introduce afs_IsDCacheFresh 35/13435/5
authorAndrew Deason <adeason@sinenomine.net>
Thu, 17 Jan 2019 21:45:36 +0000 (15:45 -0600)
committerBenjamin Kaduk <kaduk@mit.edu>
Fri, 12 Jul 2019 14:24:02 +0000 (10:24 -0400)
commit0d8ce846ab2e6c45166a61f04eb3af271cbd27db
treee205b3351bccce7a37514df5f654011e1ff23341
parentfb9de9e5fd4822df043a0d46e6a1101df2e08b85
afs: Introduce afs_IsDCacheFresh

Numerous places in libafs check the DV of a dcache against the DV of
the vcache for the same file, in order to check if the dcache is up to
date and can be used. Consolidate all of these checks into a new
function, afs_IsDCacheFresh, to make it easier for future commits to
alter this logic.

This commit should have no visible impact; it is just code
reorganization.

Change-Id: Iedc02b0f5d7d0542ab00ff1effdde03c2a851df4
Reviewed-on: https://gerrit.openafs.org/13435
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
Tested-by: Andrew Deason <adeason@sinenomine.net>
src/afs/LINUX/osi_export.c
src/afs/LINUX/osi_vnodeops.c
src/afs/SOLARIS/osi_vnodeops.c
src/afs/VNOPS/afs_vnop_create.c
src/afs/VNOPS/afs_vnop_lookup.c
src/afs/VNOPS/afs_vnop_read.c
src/afs/VNOPS/afs_vnop_readdir.c
src/afs/VNOPS/afs_vnop_remove.c
src/afs/VNOPS/afs_vnop_rename.c
src/afs/afs_dcache.c
src/afs/afs_prototypes.h