summaryrefslogtreecommitdiffstats
path: root/drivers/net/hyperv/netvsc_drv.c
diff options
context:
space:
mode:
authorstephen hemminger2017-03-22 22:50:59 +0100
committerDavid S. Miller2017-03-23 03:38:56 +0100
commit3071ada4916e26a8961c1b99f7766a73b9007bfc (patch)
treef02066f3d26e4024324a93d062217a0b5ad3f941 /drivers/net/hyperv/netvsc_drv.c
parentnetvsc: handle offline mtu and channel change (diff)
downloadkernel-qcow2-linux-3071ada4916e26a8961c1b99f7766a73b9007bfc.tar.gz
kernel-qcow2-linux-3071ada4916e26a8961c1b99f7766a73b9007bfc.tar.xz
kernel-qcow2-linux-3071ada4916e26a8961c1b99f7766a73b9007bfc.zip
netvsc: change max channel calculation
The default number of maximum channels should be limited to the number of cpus available on the numa node of the primary channel. This also makes sure maximum channels <= num_online_cpus Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/hyperv/netvsc_drv.c')
-rw-r--r--drivers/net/hyperv/netvsc_drv.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
index b3a7f508434b..2f9de2e9f38e 100644
--- a/drivers/net/hyperv/netvsc_drv.c
+++ b/drivers/net/hyperv/netvsc_drv.c
@@ -1503,8 +1503,7 @@ static int netvsc_probe(struct hv_device *dev,
/* Notify the netvsc driver of the new device */
memset(&device_info, 0, sizeof(device_info));
device_info.ring_size = ring_size;
- device_info.max_num_vrss_chns = min_t(u32, VRSS_CHANNEL_DEFAULT,
- num_online_cpus());
+ device_info.num_chn = VRSS_CHANNEL_DEFAULT;
ret = rndis_filter_device_add(dev, &device_info);
if (ret != 0) {
netdev_err(net, "unable to add netvsc device (ret %d)\n", ret);