Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp2004312imm; Thu, 24 May 2018 04:21:57 -0700 (PDT) X-Google-Smtp-Source: AB8JxZrlzC0Lcv50dLqwA1el6H5//3tGrADycCKLycdRtggi0kJBon1EpuPQSPGEmUY/2XG/ezqg X-Received: by 2002:a17:902:6046:: with SMTP id a6-v6mr2495850plt.59.1527160917003; Thu, 24 May 2018 04:21:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527160916; cv=none; d=google.com; s=arc-20160816; b=SKCfH+XPiIuWjbRMmNi8rCkJDBwzbarX2+HJvtFt9hHwSxkebuku6lVLnVAfPww2Vv t8Uiq+20L2AobO1pG1epRgqlRFgRZtiTTFwZKlx7ifAbTvou3JwyqE9xxyAjMOjQicaF +tAh+2mwaOG/j6T0IZkV0yHtit9x2uPvhDLxy8G620nMArbLIpkcOvf2+XiQ3BkUgsxh /tJIL1EZQvV3r0Ma64w//uqNM2Tli/edQK0EGCugXgffPtBpNH9JpLFDmXKjqmCfbxZZ Y/JH1/EuKVwp+1/b9OcgXu8WiMhesu/vLenzYvXQXx+rl6SiTw/WzeY6Dk8bJdYeyO2A 6Mug== 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=mlDYV8LHY2izse1JYSdt4naG7CFWHl8c6raHyMd4qiQ=; b=zH9bzbarb1G8tMikYo06CfMBSVuIZIzXPQ8zPTi8MzIbih0O2heb4M8+kCYRnhdakn PzHyK2FhEwMmBk/aX7TY0NGGr5GlEcchqf4EoBToDr9J1AFkR6m1FKEzbp40pRtSxuq0 +k2Yd+4lp2p/l8I27PmbY2yrcisRiVhSQjOnRZkSKu9lyJEiS6Nw/1Xdu9vtWbIADkFE CgY0/QcvyFfj6zX0oLZgRimYVXXkC7WCA4CDC4qR8fLQtgXkHCVaGMAgWL+8rM/vnkVm gAGX+pV+eSLKa7ilDNJDw6CDN1c+EOfaqLneQZVyU3wqNaagypCvBYWLLteaW10kbTfL lMTA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=i35rkWN2; 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 30-v6si21173167plb.531.2018.05.24.04.21.41; Thu, 24 May 2018 04:21:56 -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=i35rkWN2; 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 S968770AbeEXLVE (ORCPT + 99 others); Thu, 24 May 2018 07:21:04 -0400 Received: from mail.kernel.org ([198.145.29.99]:52760 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S967891AbeEXJwg (ORCPT ); Thu, 24 May 2018 05:52:36 -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 0519920847; Thu, 24 May 2018 09:52:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1527155555; bh=qGW2+7sJb4bpnvzUULBpqPuSf9f1kbGTd9/pdel3X6k=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=i35rkWN2B93CC/zMN9M/TRFJRDkrlFT0AVpZP4GJ9yuAC93mFu6bJeOBPAA9ENtUt ZEat8keVZDSITEAnIvPHd5duQmFwACBugjccBQdY+A1NoCgBDqlRxw9EwxZTG+6ah6 RENBDkQT3E8+IyciXS1cl5bl9mostCJZlnkycuUw= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Mohammed Gamal , "David S. Miller" Subject: [PATCH 4.14 031/165] hv_netvsc: Use Windows version instead of NVSP version on GPAD teardown Date: Thu, 24 May 2018 11:37:17 +0200 Message-Id: <20180524093623.233619150@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: Mohammed Gamal commit 2afc5d61a7197de25a61f54ea4ecfb4cb62b1d42A upstram When changing network interface settings, Windows guests older than WS2016 can no longer shutdown. This was addressed by commit 0ef58b0a05c12 ("hv_netvsc: change GPAD teardown order on older versions"), however the issue also occurs on WS2012 guests that share NVSP protocol versions with WS2016 guests. Hence we use Windows version directly to differentiate them. Fixes: 0ef58b0a05c12 ("hv_netvsc: change GPAD teardown order on older versions") Signed-off-by: Mohammed Gamal Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- drivers/net/hyperv/netvsc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/drivers/net/hyperv/netvsc.c +++ b/drivers/net/hyperv/netvsc.c @@ -569,13 +569,13 @@ void netvsc_device_remove(struct hv_devi netdev_dbg(ndev, "net device safe to remove\n"); /* older versions require that buffer be revoked before close */ - if (net_device->nvsp_version < NVSP_PROTOCOL_VERSION_4) + if (vmbus_proto_version < VERSION_WIN10) netvsc_teardown_gpadl(device, net_device); /* Now, we can close the channel safely */ vmbus_close(device->channel); - if (net_device->nvsp_version >= NVSP_PROTOCOL_VERSION_4) + if (vmbus_proto_version >= VERSION_WIN10) netvsc_teardown_gpadl(device, net_device); /* Release all resources */