Commit 7a2a0a84 authored by Stephen Hemminger's avatar Stephen Hemminger Committed by David S. Miller

hv_netvsc: make netvsc_destroy_buf void

No caller checks the return value.
Signed-off-by: default avatarStephen Hemminger <sthemmin@microsoft.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent bc304dd3
...@@ -206,12 +206,12 @@ static struct netvsc_device *get_inbound_net_device(struct hv_device *device) ...@@ -206,12 +206,12 @@ static struct netvsc_device *get_inbound_net_device(struct hv_device *device)
return net_device; return net_device;
} }
static int netvsc_destroy_buf(struct hv_device *device) static void netvsc_destroy_buf(struct hv_device *device)
{ {
struct nvsp_message *revoke_packet; struct nvsp_message *revoke_packet;
int ret = 0;
struct net_device *ndev = hv_get_drvdata(device); struct net_device *ndev = hv_get_drvdata(device);
struct netvsc_device *net_device = net_device_to_netvsc_device(ndev); struct netvsc_device *net_device = net_device_to_netvsc_device(ndev);
int ret;
/* /*
* If we got a section count, it means we received a * If we got a section count, it means we received a
...@@ -241,7 +241,7 @@ static int netvsc_destroy_buf(struct hv_device *device) ...@@ -241,7 +241,7 @@ static int netvsc_destroy_buf(struct hv_device *device)
if (ret != 0) { if (ret != 0) {
netdev_err(ndev, "unable to send " netdev_err(ndev, "unable to send "
"revoke receive buffer to netvsp\n"); "revoke receive buffer to netvsp\n");
return ret; return;
} }
} }
...@@ -256,7 +256,7 @@ static int netvsc_destroy_buf(struct hv_device *device) ...@@ -256,7 +256,7 @@ static int netvsc_destroy_buf(struct hv_device *device)
if (ret != 0) { if (ret != 0) {
netdev_err(ndev, netdev_err(ndev,
"unable to teardown receive buffer's gpadl\n"); "unable to teardown receive buffer's gpadl\n");
return ret; return;
} }
net_device->recv_buf_gpadl_handle = 0; net_device->recv_buf_gpadl_handle = 0;
} }
...@@ -300,7 +300,7 @@ static int netvsc_destroy_buf(struct hv_device *device) ...@@ -300,7 +300,7 @@ static int netvsc_destroy_buf(struct hv_device *device)
if (ret != 0) { if (ret != 0) {
netdev_err(ndev, "unable to send " netdev_err(ndev, "unable to send "
"revoke send buffer to netvsp\n"); "revoke send buffer to netvsp\n");
return ret; return;
} }
} }
/* Teardown the gpadl on the vsp end */ /* Teardown the gpadl on the vsp end */
...@@ -314,7 +314,7 @@ static int netvsc_destroy_buf(struct hv_device *device) ...@@ -314,7 +314,7 @@ static int netvsc_destroy_buf(struct hv_device *device)
if (ret != 0) { if (ret != 0) {
netdev_err(ndev, netdev_err(ndev,
"unable to teardown send buffer's gpadl\n"); "unable to teardown send buffer's gpadl\n");
return ret; return;
} }
net_device->send_buf_gpadl_handle = 0; net_device->send_buf_gpadl_handle = 0;
} }
...@@ -324,8 +324,6 @@ static int netvsc_destroy_buf(struct hv_device *device) ...@@ -324,8 +324,6 @@ static int netvsc_destroy_buf(struct hv_device *device)
net_device->send_buf = NULL; net_device->send_buf = NULL;
} }
kfree(net_device->send_section_map); kfree(net_device->send_section_map);
return ret;
} }
static int netvsc_init_buf(struct hv_device *device) static int netvsc_init_buf(struct hv_device *device)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment