Lines Matching refs:nfsi
73 struct nfs_inode *nfsi = NFS_I(dir); in alloc_nfs_open_dir_context() local
78 ctx->attr_gencount = nfsi->attr_gencount; in alloc_nfs_open_dir_context()
83 if (list_empty(&nfsi->open_files) && in alloc_nfs_open_dir_context()
84 (nfsi->cache_validity & NFS_INO_DATA_INVAL_DEFER)) in alloc_nfs_open_dir_context()
85 nfsi->cache_validity |= NFS_INO_INVALID_DATA | in alloc_nfs_open_dir_context()
87 list_add(&ctx->list, &nfsi->open_files); in alloc_nfs_open_dir_context()
254 nfs_readdir_inode_mapping_valid(struct nfs_inode *nfsi) in nfs_readdir_inode_mapping_valid() argument
256 if (nfsi->cache_validity & (NFS_INO_INVALID_ATTR|NFS_INO_INVALID_DATA)) in nfs_readdir_inode_mapping_valid()
259 return !test_bit(NFS_INO_INVALIDATING, &nfsi->flags); in nfs_readdir_inode_mapping_valid()
271 struct nfs_inode *nfsi = NFS_I(file_inode(desc->file)); in nfs_readdir_search_for_cookie() local
275 if (ctx->attr_gencount != nfsi->attr_gencount || in nfs_readdir_search_for_cookie()
276 !nfs_readdir_inode_mapping_valid(nfsi)) { in nfs_readdir_search_for_cookie()
278 ctx->attr_gencount = nfsi->attr_gencount; in nfs_readdir_search_for_cookie()
382 struct nfs_inode *nfsi; in nfs_same_file() local
391 nfsi = NFS_I(inode); in nfs_same_file()
392 if (entry->fattr->fileid != nfsi->fileid) in nfs_same_file()
394 if (entry->fh->size && nfs_compare_fh(entry->fh, &nfsi->fh) != 0) in nfs_same_file()
418 struct nfs_inode *nfsi = NFS_I(dir); in nfs_advise_use_readdirplus() local
421 !list_empty(&nfsi->open_files)) in nfs_advise_use_readdirplus()
422 set_bit(NFS_INO_ADVISE_RDPLUS, &nfsi->flags); in nfs_advise_use_readdirplus()
435 struct nfs_inode *nfsi = NFS_I(dir); in nfs_force_use_readdirplus() local
438 !list_empty(&nfsi->open_files)) { in nfs_force_use_readdirplus()
439 set_bit(NFS_INO_ADVISE_RDPLUS, &nfsi->flags); in nfs_force_use_readdirplus()
2174 struct nfs_inode *nfsi, *next; in nfs_do_access_cache_scan() local
2179 list_for_each_entry_safe(nfsi, next, &nfs_access_lru_list, access_cache_inode_lru) { in nfs_do_access_cache_scan()
2184 inode = &nfsi->vfs_inode; in nfs_do_access_cache_scan()
2186 if (list_empty(&nfsi->access_cache_entry_lru)) in nfs_do_access_cache_scan()
2188 cache = list_entry(nfsi->access_cache_entry_lru.next, in nfs_do_access_cache_scan()
2191 rb_erase(&cache->rb_node, &nfsi->access_cache); in nfs_do_access_cache_scan()
2193 if (!list_empty(&nfsi->access_cache_entry_lru)) in nfs_do_access_cache_scan()
2194 list_move_tail(&nfsi->access_cache_inode_lru, in nfs_do_access_cache_scan()
2198 list_del_init(&nfsi->access_cache_inode_lru); in nfs_do_access_cache_scan()
2200 clear_bit(NFS_INO_ACL_LRU_SET, &nfsi->flags); in nfs_do_access_cache_scan()
2244 static void __nfs_access_zap_cache(struct nfs_inode *nfsi, struct list_head *head) in __nfs_access_zap_cache() argument
2246 struct rb_root *root_node = &nfsi->access_cache; in __nfs_access_zap_cache()
2256 nfsi->cache_validity &= ~NFS_INO_INVALID_ACCESS; in __nfs_access_zap_cache()
2299 struct nfs_inode *nfsi = NFS_I(inode); in nfs_access_get_cached() local
2306 if (nfsi->cache_validity & NFS_INO_INVALID_ACCESS) in nfs_access_get_cached()
2329 list_move_tail(&cache->lru, &nfsi->access_cache_entry_lru); in nfs_access_get_cached()
2345 struct nfs_inode *nfsi = NFS_I(inode); in nfs_access_get_cached_rcu() local
2351 if (nfsi->cache_validity & NFS_INO_INVALID_ACCESS) in nfs_access_get_cached_rcu()
2353 lh = rcu_dereference(nfsi->access_cache_entry_lru.prev); in nfs_access_get_cached_rcu()
2355 if (lh == &nfsi->access_cache_entry_lru || in nfs_access_get_cached_rcu()
2372 struct nfs_inode *nfsi = NFS_I(inode); in nfs_access_add_rbtree() local
2373 struct rb_root *root_node = &nfsi->access_cache; in nfs_access_add_rbtree()
2394 list_add_tail(&set->lru, &nfsi->access_cache_entry_lru); in nfs_access_add_rbtree()
2399 list_add_tail(&set->lru, &nfsi->access_cache_entry_lru); in nfs_access_add_rbtree()