Message ID | 20231006101028.1973730-1-jbrunet@baylibre.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:a888:0:b0:403:3b70:6f57 with SMTP id x8csp211828vqo; Fri, 6 Oct 2023 03:11:23 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEzgRcVIiBUYl9QquESIUYHpy1jsXddPwzVZQ2PLSR0fx3IHjodLuMvUJxsessN480XOkpd X-Received: by 2002:a05:6a20:5485:b0:136:e26b:6401 with SMTP id i5-20020a056a20548500b00136e26b6401mr9336916pzk.16.1696587082913; Fri, 06 Oct 2023 03:11:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696587082; cv=none; d=google.com; s=arc-20160816; b=JtYfgIbSl29MdwhcjXj2BNqi53h8MB3zGG0TJbYuNhYhl/qtDkU4HGDZTH24G6cAEZ HH1fLOyby4/jJEcd5qbKOMpXeN4Dy2sdag5kN8chJ1r0GyDCS4NIiQtduTexYH0l73Lp OTB7ejv6g5yTBi2ZdIS+R5kf2zdvC+63/8qLybU8J7aHczO11vsbF2W/sjl0WfH2Fgyw oEqBnoYHPZNd36MT1OBtMZORVj2cvmTwLR2VrSYWrDQw3yeKsYKThxaeXtxzOnHv0Vcs rK4J4WWim64uhJ9TU9dGnK20gSMjUNrtirkxB1lIUO+ceoBPE0pvSq8mzrmNMWSiIZBb zyCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=hwWW0sABsjh41YiHpOu0oUsWiTPmoqzV+38FlfE5YNs=; fh=+oY607+JTs/mlaByQ0Zw5MzFSjYyq6XldQrpQVP23Bg=; b=G/W8bLwSEnDoCQLqV8zaPz0mB5ZMY5rbPmcXyeNhHMr+i0UAxtM2XK1hxLf5wavF1o xwoZLP2w24fksx7k3e3T4T6vlsP+92piNMjCpw0+xL4MTKavvKPeBbY4OMcQxHAedCod d5UQ2q4+mJJ797JNjPAWelIqf0ktgC+32lEkLMoctB05HWx8qA6owfp//xGeFCxgDVW8 bRJhE3jwU+clQUiXLO4PIVlQJg3h1LKslRYdkA+EbZ3Dyx8PagXCeiAWpV0W5nlAMq5u fXetIK7F/WeWGAoPbVcuqncUHypQugsyeARLsKcEYFEdR9WcJqii10j0+CUSajAqhH2d 1ZpQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20230601.gappssmtp.com header.s=20230601 header.b=nq+s4fQj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from morse.vger.email (morse.vger.email. [2620:137:e000::3:1]) by mx.google.com with ESMTPS id s16-20020a63af50000000b005859f4b7e7asi3412595pgo.51.2023.10.06.03.11.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Oct 2023 03:11:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 as permitted sender) client-ip=2620:137:e000::3:1; Authentication-Results: mx.google.com; dkim=pass header.i=@baylibre-com.20230601.gappssmtp.com header.s=20230601 header.b=nq+s4fQj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by morse.vger.email (Postfix) with ESMTP id 92842809C388; Fri, 6 Oct 2023 03:11:20 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at morse.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231680AbjJFKLF (ORCPT <rfc822;ezelljr.billy@gmail.com> + 18 others); Fri, 6 Oct 2023 06:11:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44090 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231597AbjJFKLD (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Fri, 6 Oct 2023 06:11:03 -0400 Received: from mail-wr1-x434.google.com (mail-wr1-x434.google.com [IPv6:2a00:1450:4864:20::434]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 55EBEBE for <linux-kernel@vger.kernel.org>; Fri, 6 Oct 2023 03:11:01 -0700 (PDT) Received: by mail-wr1-x434.google.com with SMTP id ffacd0b85a97d-32483535e51so1889106f8f.0 for <linux-kernel@vger.kernel.org>; Fri, 06 Oct 2023 03:11:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1696587060; x=1697191860; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=hwWW0sABsjh41YiHpOu0oUsWiTPmoqzV+38FlfE5YNs=; b=nq+s4fQj2mcftSGpPJ2EBRBAnnIRD6UutYjjTtbkPeXDutqKQ/rVkaVNP8cZ3/SYA/ Oh5FQkXLs4Li74fyA403SR5pTAixifsN3eaSB1LWW1l+GMbwdYn7PkmKPr2nC9k8OydE 8BosMxXQaccUMa2qmsUclp8d0eaH9U0Gp8IXd+iYOOjyPmVhcuGh/5r8TPeu7oHF0Iz/ 9s/F1o6jQieoq2HCr7jKwSLaZQ26jwBPUcV1UpDhxikAZCwm9PaVMSGSPZHHHvmxHutW dsZYlFYV9fRcXKg7AT1qrOELsh1V5stRLBtQqCy7+aSccevK062+9TtF8xPTgwDqulnM 24ow== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696587060; x=1697191860; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=hwWW0sABsjh41YiHpOu0oUsWiTPmoqzV+38FlfE5YNs=; b=gbXH6rV6K5mNiNvQO8G/9kS++cB8CKFwfq1z8Xr6qQj99HsZw5iSHxq629UREctzt6 rhPeRi27vjbe8Gpm72qNHjZUPSA3NaJrWmDJgJv1Ru9zkzn0/Vinai4ZggJshtVu+wD3 Z1ZkojqhlDO700ncL1CIhfLr7tKo9duUUmo5weuwtYb/xA24S6HHj7anlUJRGBrEw/HS NM1l5TkIoHo9OwERoaLR8Drez9nGDe21uZ4RuNtDEVSauhWZyFWXDE1yG6SNDwL5wXSM HH0YTRa0u1FmRx57IsLkdoMjnNJnkd0/hwCxuGWZh5fSXL6g4QRZ+zHE65DiHz0Uf/Ng j3tQ== X-Gm-Message-State: AOJu0YyFrsOe5XCrO3XTyLo94BOP5zpmZTH2fAT6tN00e6iVINU4YnLL LWmHjMTUfDDotp5HvaaEaOu+qQ== X-Received: by 2002:a5d:574f:0:b0:321:63d0:1f0e with SMTP id q15-20020a5d574f000000b0032163d01f0emr6520490wrw.20.1696587059529; Fri, 06 Oct 2023 03:10:59 -0700 (PDT) Received: from toaster.lan ([2a01:e0a:3c5:5fb1:8f44:72b3:5bcb:6c6b]) by smtp.googlemail.com with ESMTPSA id t6-20020adff046000000b003231a0ca5ebsm1287343wro.49.2023.10.06.03.10.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Oct 2023 03:10:59 -0700 (PDT) From: Jerome Brunet <jbrunet@baylibre.com> To: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Jerome Brunet <jbrunet@baylibre.com>, linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org, Neil Armstrong <neil.armstrong@linaro.org> Subject: [PATCH] usb: misc: onboard_usb_hub: extend gl3510 reset duration Date: Fri, 6 Oct 2023 12:10:28 +0200 Message-Id: <20231006101028.1973730-1-jbrunet@baylibre.com> X-Mailer: git-send-email 2.40.1 MIME-Version: 1.0 X-Patchwork-Bot: notify Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=2.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_SBL_CSS, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on morse.vger.email Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (morse.vger.email [0.0.0.0]); Fri, 06 Oct 2023 03:11:20 -0700 (PDT) X-Spam-Level: ** X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1779000497185969961 X-GMAIL-MSGID: 1779000497185969961 |
Series |
usb: misc: onboard_usb_hub: extend gl3510 reset duration
|
|
Commit Message
Jerome Brunet
Oct. 6, 2023, 10:10 a.m. UTC
Initial tests with the gl3510 has been done on libretech aml-a311d-cc.
A 50us reset was fine as long as the hub node was under the usb phy node it
DT. DT schema does not allow that. Moving the hub under the dwc3 controller
caused issues, such as:
onboard-usb-hub 1-1: Failed to suspend device, error -32
onboard-usb-hub 1-1: can't set config #1, error -71
onboard-usb-hub 1-1: Failed to suspend device, error -32
onboard-usb-hub 1-1: USB disconnect, device number 2
Extending the reset duration solves the problem.
Since there is no documentation available for this hub, it is difficult to
know the actual required reset duration. 200us seems to work fine so far.
Suggested-by: Neil Armstrong <neil.armstrong@linaro.org>
Fixes: 65009ccf7e8f ("usb: misc: onboard_usb_hub: add Genesys Logic gl3510 hub support")
Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>
---
drivers/usb/misc/onboard_usb_hub.h | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
Comments
On Fri, Oct 06, 2023 at 12:10:28PM +0200, Jerome Brunet wrote: > Initial tests with the gl3510 has been done on libretech aml-a311d-cc. > A 50us reset was fine as long as the hub node was under the usb phy node it > DT. DT schema does not allow that. Moving the hub under the dwc3 controller > caused issues, such as: > > onboard-usb-hub 1-1: Failed to suspend device, error -32 > onboard-usb-hub 1-1: can't set config #1, error -71 > onboard-usb-hub 1-1: Failed to suspend device, error -32 > onboard-usb-hub 1-1: USB disconnect, device number 2 > > Extending the reset duration solves the problem. > Since there is no documentation available for this hub, it is difficult to > know the actual required reset duration. 200us seems to work fine so far. > > Suggested-by: Neil Armstrong <neil.armstrong@linaro.org> > Fixes: 65009ccf7e8f ("usb: misc: onboard_usb_hub: add Genesys Logic gl3510 hub support") I can't find this git id, what tree is it in? thanks, greg k-h
On Tue 10 Oct 2023 at 08:56, Greg Kroah-Hartman <gregkh@linuxfoundation.org> wrote: > On Fri, Oct 06, 2023 at 12:10:28PM +0200, Jerome Brunet wrote: >> Initial tests with the gl3510 has been done on libretech aml-a311d-cc. >> A 50us reset was fine as long as the hub node was under the usb phy node it >> DT. DT schema does not allow that. Moving the hub under the dwc3 controller >> caused issues, such as: >> >> onboard-usb-hub 1-1: Failed to suspend device, error -32 >> onboard-usb-hub 1-1: can't set config #1, error -71 >> onboard-usb-hub 1-1: Failed to suspend device, error -32 >> onboard-usb-hub 1-1: USB disconnect, device number 2 >> >> Extending the reset duration solves the problem. >> Since there is no documentation available for this hub, it is difficult to >> know the actual required reset duration. 200us seems to work fine so far. >> >> Suggested-by: Neil Armstrong <neil.armstrong@linaro.org> >> Fixes: 65009ccf7e8f ("usb: misc: onboard_usb_hub: add Genesys Logic gl3510 hub support") > > I can't find this git id, what tree is it in? Silly mistake. I must have taken the git id I had before you merged it. Sorry. The correct tag with usb-next is Fixes: b447e9efe50a ("usb: misc: onboard_usb_hub: add Genesys Logic gl3510 hub support") Should I resend it ? > > thanks, > > greg k-h
On Tue, Oct 10, 2023 at 10:27:32AM +0200, Jerome Brunet wrote: > > On Tue 10 Oct 2023 at 08:56, Greg Kroah-Hartman <gregkh@linuxfoundation.org> wrote: > > > On Fri, Oct 06, 2023 at 12:10:28PM +0200, Jerome Brunet wrote: > >> Initial tests with the gl3510 has been done on libretech aml-a311d-cc. > >> A 50us reset was fine as long as the hub node was under the usb phy node it > >> DT. DT schema does not allow that. Moving the hub under the dwc3 controller > >> caused issues, such as: > >> > >> onboard-usb-hub 1-1: Failed to suspend device, error -32 > >> onboard-usb-hub 1-1: can't set config #1, error -71 > >> onboard-usb-hub 1-1: Failed to suspend device, error -32 > >> onboard-usb-hub 1-1: USB disconnect, device number 2 > >> > >> Extending the reset duration solves the problem. > >> Since there is no documentation available for this hub, it is difficult to > >> know the actual required reset duration. 200us seems to work fine so far. > >> > >> Suggested-by: Neil Armstrong <neil.armstrong@linaro.org> > >> Fixes: 65009ccf7e8f ("usb: misc: onboard_usb_hub: add Genesys Logic gl3510 hub support") > > > > I can't find this git id, what tree is it in? > > Silly mistake. I must have taken the git id I had before you merged it. Sorry. > The correct tag with usb-next is > > Fixes: b447e9efe50a ("usb: misc: onboard_usb_hub: add Genesys Logic gl3510 hub support") > > Should I resend it ? Please do.
diff --git a/drivers/usb/misc/onboard_usb_hub.h b/drivers/usb/misc/onboard_usb_hub.h index a9e2f6023c1c..38de22452963 100644 --- a/drivers/usb/misc/onboard_usb_hub.h +++ b/drivers/usb/misc/onboard_usb_hub.h @@ -31,6 +31,11 @@ static const struct onboard_hub_pdata cypress_hx3_data = { .num_supplies = 2, }; +static const struct onboard_hub_pdata genesys_gl3510_data = { + .reset_us = 200, + .num_supplies = 1, +}; + static const struct onboard_hub_pdata genesys_gl850g_data = { .reset_us = 3, .num_supplies = 1, @@ -56,7 +61,7 @@ static const struct of_device_id onboard_hub_match[] = { { .compatible = "usb5e3,608", .data = &genesys_gl850g_data, }, { .compatible = "usb5e3,610", .data = &genesys_gl852g_data, }, { .compatible = "usb5e3,620", .data = &genesys_gl852g_data, }, - { .compatible = "usb5e3,626", .data = &genesys_gl852g_data, }, + { .compatible = "usb5e3,626", .data = &genesys_gl3510_data, }, { .compatible = "usbbda,411", .data = &realtek_rts5411_data, }, { .compatible = "usbbda,5411", .data = &realtek_rts5411_data, }, { .compatible = "usbbda,414", .data = &realtek_rts5411_data, },