summaryrefslogtreecommitdiff
path: root/drivers/net/hyperv/netvsc_drv.c
diff options
context:
space:
mode:
authorstephen hemminger <stephen@networkplumber.org>2017-01-25 00:06:07 +0300
committerDavid S. Miller <davem@davemloft.net>2017-01-25 00:28:59 +0300
commitb8b835a89b2f7a7fe681983dfe5c489cb9ad9500 (patch)
tree156d3537cbf6ca51b7148690d868b38f6f37da7a /drivers/net/hyperv/netvsc_drv.c
parentceaaea0483cf82a2c817781f3cbacf29f2c5cc97 (diff)
downloadlinux-b8b835a89b2f7a7fe681983dfe5c489cb9ad9500.tar.xz
netvsc: group all per-channel state together
Put all the per-channel state together in one data struct. 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.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
index f96b44eee270..da5863641703 100644
--- a/drivers/net/hyperv/netvsc_drv.c
+++ b/drivers/net/hyperv/netvsc_drv.c
@@ -135,7 +135,7 @@ static int netvsc_close(struct net_device *net)
while (true) {
aread = 0;
for (i = 0; i < nvdev->num_chn; i++) {
- chn = nvdev->chn_table[i];
+ chn = nvdev->chan_table[i].channel;
if (!chn)
continue;
@@ -225,7 +225,7 @@ static u16 netvsc_select_queue(struct net_device *ndev, struct sk_buff *skb,
q_idx = new_idx;
}
- if (unlikely(!nvsc_dev->chn_table[q_idx]))
+ if (unlikely(!nvsc_dev->chan_table[q_idx].channel))
q_idx = 0;
return q_idx;
@@ -545,7 +545,6 @@ no_memory:
++net_device_ctx->eth_stats.tx_no_memory;
goto drop;
}
-
/*
* netvsc_linkstatus_callback - Link up/down notification
*/