]> err.no Git - linux-2.6/commitdiff
coda: correctly invalidate cached access rights
authorJan Harkes <jaharkes@cs.cmu.edu>
Thu, 19 Jul 2007 08:48:42 +0000 (01:48 -0700)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Thu, 19 Jul 2007 17:04:48 +0000 (10:04 -0700)
Change the epoch value to forces a refresh instead of clearing the cached
rights mask and block all further accesses to the object.

Signed-off-by: Jan Harkes <jaharkes@cs.cmu.edu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/coda/cache.c

index fcb88fa8d2f2f0fdd045de83fcdd8f733e970474..11538a2b54230f207cafce906ea0716f53d2791f 100644 (file)
@@ -43,7 +43,7 @@ void coda_cache_enter(struct inode *inode, int mask)
 void coda_cache_clear_inode(struct inode *inode)
 {
        struct coda_inode_info *cii = ITOC(inode);
-        cii->c_cached_perm = 0;
+       cii->c_cached_epoch = atomic_read(&permission_epoch) - 1;
 }
 
 /* remove all acl caches */