Received: by 10.223.176.5 with SMTP id f5csp1021581wra; Fri, 2 Feb 2018 09:51:09 -0800 (PST) X-Google-Smtp-Source: AH8x227Bfx/t6X9TvP3Hr3nxCW+mLz/JkedkyepY0o/fnRFUljWyOATLRB5xDgKU0pfDw4uoWSOP X-Received: by 10.98.14.208 with SMTP id 77mr2443461pfo.99.1517593869450; Fri, 02 Feb 2018 09:51:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517593869; cv=none; d=google.com; s=arc-20160816; b=eqY2f/wfoSdO10/bbPnEZ3fPEJoGeXEAl18RZBJed14bbff658Se3zTWSlnXmkZmBa 807O30RhTIyOJIHvFgVYPFKsIkAq9Cb9wKD5BF0t/p4w/HxynrkEUnmifNk+2XrC0VNS Ug4z20/8n1ZUpEH7OXaeVffgN9slIxTE5QJjYQxs667UxT4NnD/K+DDqdopn+ezL/iOn nLVG0rRVUjaTtGlI89GN7lYBsxaupPUMbOGe/q7xgGAWcz5RITnEurvbi2I/3IPv6ASi 2rWVLo6BOl6YKqYf/xmq9JtLeCnvWOqmtyXRwlu2G9Ig0Xk1sTTRKny/jeGzCtRe8sJh Ftig== 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 :arc-authentication-results; bh=7lZ3C2pPG7EA3gy9eR5cbyeu6c0h8r/7UM+KravkQ50=; b=ym6sAc/i5jxGE6AdTKcEdkB0y/tHe7ZC75+ZHXJ/kgf42UPsq+o8PdBASVWrkGpUI8 rHPxyC05SkXhomUlNTA7a0oZjcA86ckoBE/NR3SsXWVFDpbh5lugKTJT0xW1o6llzu2q m95AsqDWLvndw3WAo2h3Vp1vcafKMfYA6zbuCcRQA1qFqa88UMZrGyVURDAZO7YKp+OV XqE1Vq6A6b6OYs+gNdeyJ8Tt6S5oK6M4lrY+I2S6A/0WmaWvblzNXg1cGjIdOb5EIqYC zXiuOPBpkudMpPtMUMuU77r8li1U6F3WMepRqiq+BlybwHwfyR5oyPAX4ED0mPtVJ4/2 YSFA== ARC-Authentication-Results: i=1; mx.google.com; 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 z5-v6si2112079pln.677.2018.02.02.09.50.55; Fri, 02 Feb 2018 09:51:09 -0800 (PST) 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; 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 S1753476AbeBBRMv (ORCPT + 99 others); Fri, 2 Feb 2018 12:12:51 -0500 Received: from mail.linuxfoundation.org ([140.211.169.12]:36896 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752898AbeBBRG4 (ORCPT ); Fri, 2 Feb 2018 12:06:56 -0500 Received: from localhost (LFbn-1-12258-90.w90-92.abo.wanadoo.fr [90.92.71.90]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 46C1EE8D; Fri, 2 Feb 2018 17:06:55 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Shuah Khan Subject: [PATCH 4.9 84/86] usbip: vhci_hcd: clear just the USB_PORT_STAT_POWER bit Date: Fri, 2 Feb 2018 17:58:44 +0100 Message-Id: <20180202140830.395431799@linuxfoundation.org> X-Mailer: git-send-email 2.16.1 In-Reply-To: <20180202140822.679101338@linuxfoundation.org> References: <20180202140822.679101338@linuxfoundation.org> User-Agent: quilt/0.65 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.9-stable review patch. If anyone has any objections, please let me know. ------------------ From: Shuah Khan Upstream commit 1c9de5bf4286 ("usbip: vhci-hcd: Add USB3 SuperSpeed support") vhci_hcd clears all the bits port_status bits instead of clearing just the USB_PORT_STAT_POWER bit when it handles ClearPortFeature: USB_PORT_FEAT_POWER. This causes vhci_hcd attach to fail in a bad state, leaving device unusable by the client. The device is still attached and however client can't use it. The problem was fixed as part of larger change to add USB3 Super Speed support. This patch backports just the change to clear the USB_PORT_STAT_POWER. Signed-off-by: Shuah Khan Signed-off-by: Greg Kroah-Hartman --- drivers/usb/usbip/vhci_hcd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/usb/usbip/vhci_hcd.c +++ b/drivers/usb/usbip/vhci_hcd.c @@ -300,7 +300,7 @@ static int vhci_hub_control(struct usb_h case USB_PORT_FEAT_POWER: usbip_dbg_vhci_rh( " ClearPortFeature: USB_PORT_FEAT_POWER\n"); - dum->port_status[rhport] = 0; + dum->port_status[rhport] &= ~USB_PORT_STAT_POWER; dum->resuming = 0; break; case USB_PORT_FEAT_C_RESET: