Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp2005616imm; Thu, 24 May 2018 04:23:20 -0700 (PDT) X-Google-Smtp-Source: AB8JxZp2nynlS0S5N0IJHFHiCd71L0lwTBVF3Fb9tLdiwaXZ9OVhzF4ngBfCfspWlRo90oEJ2uvn X-Received: by 2002:a17:902:20e5:: with SMTP id v34-v6mr6983156plg.127.1527161000107; Thu, 24 May 2018 04:23:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527161000; cv=none; d=google.com; s=arc-20160816; b=zx+ZzeS1X4NAzR/CJ4mxqsU51DGRWL38WPM19++GtPgSMZX+fCqqraDfTLY5qwPABA qMn8A33SVQ1cj55USiboRjZI+zU2yOehgHxFblGc0tbpzi2uJ2ddEcw/DDqI3pfJm99h mfC420lvo2/HybGG59+RPMKuHApXW/C1a38A/uX+YwnVMM0E6dH0qLFnx7eKrfSAkMl1 GIke80iLK2YyOAGxRsmLn+0HMHo3b/Z2ECPdoMowWL4XGENhX64hZEhvv6MVRDvHh5Qs RjUeENuOfCM+h1FjC4WUcbsMz9G+1dhdOGw4ji8Gn3gnj+GP7Lg0AxoNt2zAcbtN/JjT KtOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=mggcbjxF8LuHdM7fDH6jscEQMDQSyddyfsAxBHE0dmw=; b=P+ALVLjdVS8GYybInTykjGqu3m/vJVGjdxoCpm4hsk5q7s0lL/2SVg6oRtPHX5CsmH ybPwbUbaGPzZTkJKN7j4K/Lk7cwOLp866MU6cTuyFXENxUIWAhGWwSmckNr7BSg23Fnx +COv5wO9AOj7BhDVQ+wr931Dau1nXQjZHI9Ms0yVBD33Vn9P+Qn4zG1tSbRgJBQ8u7B3 YF7IdVf2IOz4/pITzGkk3UkpZkAFqWy84A0p3f3CMVWajKlHqwkHARIg12SMDQK0b7xD 3mEtERMNoJN1AaF6GnGe1FKQVRKtEqiJTDy9dSTS9/nmmETZI+IUZQ7TIbpX58imKXsV 116Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=V6XkdS22; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t6-v6si16468177pgp.594.2018.05.24.04.23.05; Thu, 24 May 2018 04:23:20 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=V6XkdS22; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S967843AbeEXJwT (ORCPT + 99 others); Thu, 24 May 2018 05:52:19 -0400 Received: from mail.kernel.org ([198.145.29.99]:50762 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S967007AbeEXJwO (ORCPT ); Thu, 24 May 2018 05:52:14 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 0236220890; Thu, 24 May 2018 09:52:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1527155533; bh=iyIMFju3NGFHHCvK9TiwQhZ+g4grI84/QMRKXrSHhbM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=V6XkdS22ZtrBZ8vq8/Y0qQwWC9bxE+KHhQB7xiSoIxWy376ChpWdKuWu3oZPmHqZ2 8JDz5g/U/elw0DhPORI+aqbz20KjH4+RkfZ7sSDpw2Qp0BOpGqsIM6c4Ckonvv1dHX 8CT3NrRRs2A/mKCgM21vlXQFf5iiFbvBN2tpxugQ= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Stephen Hemminger , "David S. Miller" Subject: [PATCH 4.14 023/165] hv_netvsc: fix error unwind handling if vmbus_open fails Date: Thu, 24 May 2018 11:37:09 +0200 Message-Id: <20180524093622.916036459@linuxfoundation.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180524093621.979359379@linuxfoundation.org> References: <20180524093621.979359379@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.14-stable review patch. If anyone has any objections, please let me know. ------------------ From: Stephen Hemminger [ Commit fcfb4a00d1e514e8313277a01ef919de1113025b upstream. ] Need to delete NAPI association if vmbus_open fails. Signed-off-by: Stephen Hemminger Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- 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);