libafs: Flush vcaches in afs_shutdown
authorAndrew Deason <adeason@sinenomine.net>
Tue, 10 May 2011 19:16:06 +0000 (14:16 -0500)
committerDerrick Brashear <shadow@dementia.org>
Sun, 15 May 2011 13:01:54 +0000 (06:01 -0700)
commit80fe111f0044aa7a67215ad92210dc72cb7eb2c0
treed42796243e738e6e55c9ebd4727b2383573652d9
parent330cc7c83bf8470e1e63f6e6d514f1e82008f167
libafs: Flush vcaches in afs_shutdown

Currently, a few platforms (linux, linux24, solaris, irix) flush all
vcaches during shutdown. However, they do this before calling
afs_shutdown(), resulting in afs_FlushVCache queueing VCBs and
possibly trying to give the callbacks back to the server.

Instead of this, perform the flushes in afs_shutdown itself, so we do
this after we try to give up all callbacks to all servers, and we do
this while afs_shuttingdown is set, so we don't try to queue VCBs.
This also consolidates some of the duplicated code to flush all
vcaches, and now does this for all platforms.

Change-Id: I69c9e0862972f18ecc29ff709943d9a77f2db0a9
Reviewed-on: http://gerrit.openafs.org/4641
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
src/afs/LINUX/osi_prototypes.h
src/afs/LINUX/osi_vfsops.c
src/afs/LINUX24/osi_prototypes.h
src/afs/LINUX24/osi_vfsops.c
src/afs/SOLARIS/osi_vfsops.c
src/afs/afs_call.c
src/afs/afs_prototypes.h
src/afs/afs_vcache.c