sunrpc: remove 'inuse' flag from struct cache_detail.
authorNeilBrown <neilb@suse.com>
Thu, 2 Jun 2016 06:31:03 +0000 (16:31 +1000)
committerJ. Bruce Fields <bfields@redhat.com>
Wed, 13 Jul 2016 19:32:47 +0000 (15:32 -0400)
This field is not currently in use.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
include/linux/sunrpc/cache.h
net/sunrpc/cache.c

index ed03c9f7f908d7a477ef5349f35439b30b014b85..62a60eeacb0aeaf9907a5247d42706851fec3ffb 100644 (file)
@@ -78,8 +78,6 @@ struct cache_detail {
        struct hlist_head *     hash_table;
        rwlock_t                hash_lock;
 
-       atomic_t                inuse; /* active user-space update or lookup */
-
        char                    *name;
        void                    (*cache_put)(struct kref *);
 
index 553bf95f700301a4821d4317e9277f784370bd22..4d8e11f94a35fb12390c291330c56331512f13d5 100644 (file)
@@ -362,7 +362,7 @@ void sunrpc_destroy_cache_detail(struct cache_detail *cd)
        cache_purge(cd);
        spin_lock(&cache_list_lock);
        write_lock(&cd->hash_lock);
-       if (cd->entries || atomic_read(&cd->inuse)) {
+       if (cd->entries) {
                write_unlock(&cd->hash_lock);
                spin_unlock(&cache_list_lock);
                goto out;