diff options
author | David Howells <dhowells@redhat.com> | 2020-08-19 17:27:17 +0300 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2020-08-20 20:21:28 +0300 |
commit | b95b30940ee46a4d892ca3de3ffb8249c4985b1f (patch) | |
tree | fcd9268473163fbca8d549a2f78fffa78b4b850e /fs/afs/vl_list.c | |
parent | fb72cd3d484ce548597c75ebeecc70483fe8bb6e (diff) | |
download | linux-b95b30940ee46a4d892ca3de3ffb8249c4985b1f.tar.xz |
afs: Don't use VL probe running state to make decisions outside probe code
Don't use the running state for VL server probes to make decisions about
which server to use as the state is cleared at the start of a probe and
intermediate values might also be misleading.
Instead, add a separate 'latest known' rtt in the afs_vlserver struct and a
flag to indicate if the server is known to be responding and update these
as and when we know what to change them to.
Fixes: 3bf0fb6f33dd ("afs: Probe multiple fileservers simultaneously")
Signed-off-by: David Howells <dhowells@redhat.com>
Diffstat (limited to 'fs/afs/vl_list.c')
-rw-r--r-- | fs/afs/vl_list.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/afs/vl_list.c b/fs/afs/vl_list.c index 8fea54eba0c2..38b2ba1d9ec0 100644 --- a/fs/afs/vl_list.c +++ b/fs/afs/vl_list.c @@ -21,6 +21,7 @@ struct afs_vlserver *afs_alloc_vlserver(const char *name, size_t name_len, rwlock_init(&vlserver->lock); init_waitqueue_head(&vlserver->probe_wq); spin_lock_init(&vlserver->probe_lock); + vlserver->rtt = UINT_MAX; vlserver->name_len = name_len; vlserver->port = port; memcpy(vlserver->name, name, name_len); |