From 318b83b71242998814a570c3420c042ee6165fca Mon Sep 17 00:00:00 2001 From: Colin Ian King Date: Thu, 20 Oct 2022 18:39:23 +0100 Subject: afs: remove variable nr_servers Variable nr_servers is no longer being used, the last reference to it was removed in commit 45df8462730d ("afs: Fix server list handling") so clean up the code by removing it. Signed-off-by: Colin Ian King Signed-off-by: David Howells cc: Marc Dionne cc: linux-afs@lists.infradead.org Link: https://lore.kernel.org/r/20221020173923.21342-1-colin.i.king@gmail.com/ --- fs/afs/volume.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/fs/afs/volume.c b/fs/afs/volume.c index f4937029dcd7..29d483c80281 100644 --- a/fs/afs/volume.c +++ b/fs/afs/volume.c @@ -70,11 +70,7 @@ static struct afs_volume *afs_alloc_volume(struct afs_fs_context *params, { struct afs_server_list *slist; struct afs_volume *volume; - int ret = -ENOMEM, nr_servers = 0, i; - - for (i = 0; i < vldb->nr_servers; i++) - if (vldb->fs_mask[i] & type_mask) - nr_servers++; + int ret = -ENOMEM; volume = kzalloc(sizeof(struct afs_volume), GFP_KERNEL); if (!volume) -- cgit v1.2.3