Fix cache tracking for small fragsizes
authorAndrew Deason <adeason@sinenomine.net>
Thu, 27 Aug 2009 17:43:03 +0000 (12:43 -0500)
committerDerrick Brashear <shadow|account-1000005@unknown>
Tue, 1 Sep 2009 11:38:43 +0000 (04:38 -0700)
commit04aecc99e073b07fe781d65c5c274acee14d8d26
treecaacfd242c6a5dd3fb43b63db2197e76e1d55ecb
parent67bcc19c754e7bfd55d098e9fe17723340c275ba
Fix cache tracking for small fragsizes

The tracked amount of disk cache used by a client can be incorrect when
afs_fsfragsize is tuned to below 1023. Since we round up to the next
nearest afs_fsfragsize+1 then round down to the kb, if afs_fsfragsize+1
< 1kb, we can undershoot the cache usage.

This enforces afs_fsfragsize to always be at least 1023.

Reviewed-on: http://gerrit.openafs.org/338
Tested-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
src/afs/afs.h
src/afs/afs_dcache.c
src/afs/afs_init.c