mirror of
https://github.com/torvalds/linux.git
synced 2026-05-23 14:42:08 +02:00
cifs: cifs_pick_channel should try selecting active channels
cifs_pick_channel today just selects a channel based on the policy of least loaded channel. However, it does not take into account if the channel needs reconnect. As a result, we can have failures in send that can be completely avoided. This change doesn't make a channel a candidate for this selection if it needs reconnect. Signed-off-by: Shyam Prasad N <sprasad@microsoft.com> Signed-off-by: Steve French <stfrench@microsoft.com>
This commit is contained in:
parent
966cc171c8
commit
fc43a8ac39
|
|
@ -1026,6 +1026,9 @@ struct TCP_Server_Info *cifs_pick_channel(struct cifs_ses *ses)
|
||||||
if (!server || server->terminate)
|
if (!server || server->terminate)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
if (CIFS_CHAN_NEEDS_RECONNECT(ses, i))
|
||||||
|
continue;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* strictly speaking, we should pick up req_lock to read
|
* strictly speaking, we should pick up req_lock to read
|
||||||
* server->in_flight. But it shouldn't matter much here if we
|
* server->in_flight. But it shouldn't matter much here if we
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user