lkml.org 
[lkml]   [2018]   [May]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 4.14 023/165] hv_netvsc: fix error unwind handling if vmbus_open fails
    Date
    4.14-stable review patch.  If anyone has any objections, please let me know.

    ------------------

    From: Stephen Hemminger <stephen@networkplumber.org>

    [ Commit fcfb4a00d1e514e8313277a01ef919de1113025b upstream. ]

    Need to delete NAPI association if vmbus_open fails.

    Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>
    Signed-off-by: David S. Miller <davem@davemloft.net>
    Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
    ---
    drivers/net/hyperv/netvsc.c | 2 +-
    1 file changed, 1 insertion(+), 1 deletion(-)

    --- a/drivers/net/hyperv/netvsc.c
    +++ b/drivers/net/hyperv/netvsc.c
    @@ -1288,7 +1288,6 @@ struct netvsc_device *netvsc_device_add(
    net_device->chan_table);

    if (ret != 0) {
    - netif_napi_del(&net_device->chan_table[0].napi);
    netdev_err(ndev, "unable to open channel: %d\n", ret);
    goto cleanup;
    }
    @@ -1321,6 +1320,7 @@ close:
    vmbus_close(device->channel);

    cleanup:
    + netif_napi_del(&net_device->chan_table[0].napi);
    free_netvsc_device(&net_device->rcu);

    return ERR_PTR(ret);

    \
     
     \ /
      Last update: 2018-05-24 13:23    [W:2.629 / U:0.100 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site