From patchwork Tue Apr 14 11:06:55 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: rtatiya@codeaurora.org X-Patchwork-Id: 6214971 Return-Path: X-Original-To: patchwork-linux-arm-msm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 93EB1BF4A6 for ; Tue, 14 Apr 2015 11:07:33 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 8BC28202E9 for ; Tue, 14 Apr 2015 11:07:32 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 484722021F for ; Tue, 14 Apr 2015 11:07:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753447AbbDNLH3 (ORCPT ); Tue, 14 Apr 2015 07:07:29 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:58527 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753337AbbDNLH2 (ORCPT ); Tue, 14 Apr 2015 07:07:28 -0400 Received: from smtp.codeaurora.org (localhost [127.0.0.1]) by smtp.codeaurora.org (Postfix) with ESMTP id 57D3D1411F0; Tue, 14 Apr 2015 11:07:27 +0000 (UTC) Received: by smtp.codeaurora.org (Postfix, from userid 486) id 496DD1414A0; Tue, 14 Apr 2015 11:07:27 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Received: from BT-TEAM-001.ap.qualcomm.com (unknown [202.46.23.54]) (using TLSv1.2 with cipher AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: rtatiya@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id AF4841411F0; Tue, 14 Apr 2015 11:07:24 +0000 (UTC) From: Rupesh Tatiya To: sarah.a.sharp@linux.intel.com, linux-usb@vger.kernel.org, gregkh@linuxfoundation.org, oliver@neukum.org Cc: linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, Rupesh Tatiya Subject: [PATCH v2] usb: Enable LPM for USB 2.01+ full-speed devices Date: Tue, 14 Apr 2015 16:36:55 +0530 Message-Id: <1429009615-17354-1-git-send-email-rtatiya@codeaurora.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <6101704ff4dc2e95b67146ed26d01c9f.squirrel@www.codeaurora.org> References: <6101704ff4dc2e95b67146ed26d01c9f.squirrel@www.codeaurora.org> X-Virus-Scanned: ClamAV using ClamSMTP Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP USB 2.01+ full-speed devices can have extended descriptor as well and can support LPM. Signed-off-by: Rupesh Tatiya --- drivers/usb/core/hub.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c index 9ef2d2c..1ed7b5d 100644 --- a/drivers/usb/core/hub.c +++ b/drivers/usb/core/hub.c @@ -140,7 +140,7 @@ static int usb_device_supports_lpm(struct usb_device *udev) /* USB 2.1 (and greater) devices indicate LPM support through * their USB 2.0 Extended Capabilities BOS descriptor. */ - if (udev->speed == USB_SPEED_HIGH) { + if (udev->speed == USB_SPEED_HIGH || udev->speed == USB_SPEED_FULL) { if (udev->bos->ext_cap && (USB_LPM_SUPPORT & le32_to_cpu(udev->bos->ext_cap->bmAttributes)))