From patchwork Fri Nov 3 11:23:15 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Roger Quadros X-Patchwork-Id: 117875 Delivered-To: patch@linaro.org Received: by 10.140.22.164 with SMTP id 33csp3334192qgn; Fri, 3 Nov 2017 04:23:26 -0700 (PDT) X-Google-Smtp-Source: ABhQp+SWkRmz3Pf3xT0qAL7QNE83ykMjdudoHBmBCdVrJr8ObFGnbkxrpqWOeNuf+CWesY3elIuj X-Received: by 10.99.175.80 with SMTP id s16mr6789098pgo.161.1509708206868; Fri, 03 Nov 2017 04:23:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1509708206; cv=none; d=google.com; s=arc-20160816; b=XI0O8aiR0thOTUycCRJoT6m4IAR7RuH4JOjcZbucm6i7yoa9x0aZgJwRadsjtJ7Df4 S133uac1049d/uiWeklYwzrlDojo+Pks6BiszcpBuFGSGI+YdmrV7RZptego8g6uDp0Y VcA5qajZj2ZmG54Q+ajMFCatiPRJKpnJ8UHEA/Gkc+rGe3B26mooF+uG4S+JN6zj8CcO OXo01B9QvgLDd11Q9wl6ruWlsipmPqa31M2y1IzFD1ErCDNPISoB7Iuph5UI1dS/dXFk Dnfcvc9Bqp/KbrqI5jNJZFXbdHNqN64DX08L19/j/WhYqWV3CD+t9y1IiSUjXpOl5AIw XvWg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:subject:cc :to:from:dkim-signature:arc-authentication-results; bh=gFgEtT6Femv+sNYYlltB/fv4VaMvV+jmni7JlIB9Tlc=; b=ZCHslZ/C/SS1QAfsV/IhRB21sXI3LuwSoE7OaBTkG0+hleqjC1Tn7Q3O6TSApdYpZT 8GSJTII9n6Zv9OYvP32jwa7C2p2A/qXZnLcYtHz5v/0X/T4lT021GMhV/CSIXvSyCHJI f9Qf+B08y5HTTWqGzQY2zOxWLEuIdnwQvsKcdqPOPCdalTnCWe49xCzXcF7WwLI1+Cd7 k3asLyhBL1h1JLnYcl3Lgir6TMq/VJeSBg0ndLbNQzrD6CiCfoIcisOdCjGfRCvLIHAn 4OVAZlGQlWWLYGlWxCt+KEz7DKVE5P9AqAVUWn8D/EPKvZClh+1K+OzY50lGv65VGZY3 FkVA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=c0UGne7i; 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; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w11si4901268plq.805.2017.11.03.04.23.26; Fri, 03 Nov 2017 04:23:26 -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=@ti.com header.s=ti-com-17Q1 header.b=c0UGne7i; 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; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756044AbdKCLXY (ORCPT + 26 others); Fri, 3 Nov 2017 07:23:24 -0400 Received: from lelnx193.ext.ti.com ([198.47.27.77]:24924 "EHLO lelnx193.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752854AbdKCLXX (ORCPT ); Fri, 3 Nov 2017 07:23:23 -0400 Received: from dflxv15.itg.ti.com ([128.247.5.124]) by lelnx193.ext.ti.com (8.15.1/8.15.1) with ESMTP id vA3BNKTo022966; Fri, 3 Nov 2017 06:23:20 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ti.com; s=ti-com-17Q1; t=1509708200; bh=hRtBySN/AroVh72M3KkNHn0tZczJb6gvJqo2smU8Db0=; h=From:To:CC:Subject:Date; b=c0UGne7iO8lbiWIXq4psxF68Cv2zV0yT0qxh2JGItn55hhd2OhsEMfNCerI40xVnZ yJcJonOJO3dtdymUC1ozXwp5xTQKVeXn9VlbtkmPNK3AS/InitszKJ8Jpzdebd0fWd oFHYX8oAkgnp6IGF53wRd7mln8sHA3JSQWsvlkyY= Received: from DLEE114.ent.ti.com (dlee114.ent.ti.com [157.170.170.25]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id vA3BNKmE005832; Fri, 3 Nov 2017 06:23:20 -0500 Received: from DLEE109.ent.ti.com (157.170.170.41) by DLEE114.ent.ti.com (157.170.170.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.1.845.34; Fri, 3 Nov 2017 06:23:20 -0500 Received: from dlep33.itg.ti.com (157.170.170.75) by DLEE109.ent.ti.com (157.170.170.41) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.845.34 via Frontend Transport; Fri, 3 Nov 2017 06:23:20 -0500 Received: from dlelxv97.itg.ti.com (dlelxv97.itg.ti.com [172.17.2.193]) by dlep33.itg.ti.com (8.14.3/8.13.8) with ESMTP id vA3BNK39006814; Fri, 3 Nov 2017 06:23:20 -0500 Received: from lta0400828d.ti.com (vboxa0400828d.emea.dhcp.ti.com [172.22.234.69]) by dlelxv97.itg.ti.com (8.14.3/8.13.8) with ESMTP id vA3BNIAY001719; Fri, 3 Nov 2017 06:23:18 -0500 From: Roger Quadros To: , CC: , , Roger Quadros Subject: [PATCH] USB: dummy-hcd: don't set gadget.speed in dummy_hub_control() Date: Fri, 3 Nov 2017 13:23:15 +0200 Message-ID: <1509708195-25699-1-git-send-email-rogerq@ti.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org There will never be a case when gadget.speed isn't already USB_SPEED_FULL if connection is not USB-3 and gadget.speed is not USB_SPEED_HIGH or USB_SPEED_LOW. Remove the unnecessary code. Signed-off-by: Roger Quadros --- drivers/usb/gadget/udc/dummy_hcd.c | 2 -- 1 file changed, 2 deletions(-) -- cheers, -roger Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki Acked-by: Alan Stern diff --git a/drivers/usb/gadget/udc/dummy_hcd.c b/drivers/usb/gadget/udc/dummy_hcd.c index c42ca8e..41cefc5 100644 --- a/drivers/usb/gadget/udc/dummy_hcd.c +++ b/drivers/usb/gadget/udc/dummy_hcd.c @@ -2166,8 +2166,6 @@ static int dummy_hub_control( USB_PORT_STAT_LOW_SPEED; break; default: - dum_hcd->dum->gadget.speed = - USB_SPEED_FULL; break; } }