cifs: distribute channels across interfaces based on speed

[ Upstream commit a6d8fb54a5 ]

Today, if the server interfaces RSS capable, we simply
choose the fastest interface to setup a channel. This is not
a scalable approach, and does not make a lot of attempt to
distribute the connections.

This change does a weighted distribution of channels across
all the available server interfaces, where the weight is
a function of the advertised interface speed.

Also make sure that we don't mix rdma and non-rdma for channels.

Signed-off-by: Shyam Prasad N <sprasad@microsoft.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
Stable-dep-of: fa1d0508bd ("cifs: account for primary channel in the interface list")
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
Shyam Prasad N 2022-12-26 11:24:56 +00:00 • committed by Greg Kroah-Hartman
commit 548893404c
3 changed files with 88 additions and 14 deletions