Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp1821113rwb; Fri, 2 Dec 2022 01:21:43 -0800 (PST) X-Google-Smtp-Source: AA0mqf7DeGFKcBIQAxDQwRYR05EZ5S+KaLQzCo34/8zFJi9htvTj4UWe2hp+4brSO1CCkzi4nRFJ X-Received: by 2002:aa7:8505:0:b0:574:e18c:955a with SMTP id v5-20020aa78505000000b00574e18c955amr30790633pfn.27.1669972902862; Fri, 02 Dec 2022 01:21:42 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1669972902; cv=pass; d=google.com; s=arc-20160816; b=thlAZQSogUGFrsuQtsf1GEpdLSUHlBFdrktAKCkkxkQZXPfMduAm2wjA+9pTU16I63 h5TeIBaNiBvg1dQaoMvUf0cvI5co/IsQPUIb14PDYsEeiATme/MOkpPFAlIxVoHUU0cA 5/Wl+07h5TX5bewvMWS+gF+3ruzRPOSjVOfINQ5qV3D0Co0rK5RNrfozJv+VZEFH8zjo tPkCLm8QL4F50MviXfv1rQzTlN2j41taRO3MDlqK+cspTD+6Zqcy0m66ArWT1G7wuvU0 qubpxUYjk+fVk+UB4HkBBDGlGK7dQmAv+H6tZKQZLOkwtyhjsT2fqtLYl6lPu6pubUMc 6Lnw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=OLlTVhT3idm/OLIzzgRQz3I7RcmreMDAJB3HnjwLFY4=; b=MUsOx0OTQjCJodtUPWlYYtvUOn14slBov3ivnbtO/MM2JFYawrm+dAgRxjHSumTjpL TEmXgkXGp0SS2Z3QXQQFLY8oHwrQYYxw6bUcIzygK9a3N9bRv0cu4I9xYZzUwzS6H354 Z20Qqmtroo0Hv9Dh6WEuxZevUrEkY3LnvKKYLEVSfbie9xQjyM4VCkIbFRJzn2+KskOR BCr8XNJM8+m/wVCzRVd6NZzALoy7dMxVa+52cmuVvW4b0fmlS1IYtbs3JEnZw6hgBvxE gw79m81qs4a5XETenUG7woD/muQLBJWZjNlDYaGkFi7J/hBzOwX7fz3UinyaliL6Tku0 NvJQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@icenowy.me header.s=zmail header.b=Rpcfg4DC; arc=pass (i=1 spf=pass spfdomain=icenowy.me dkim=pass dkdomain=icenowy.me dmarc=pass fromdomain=icenowy.me>); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id mu1-20020a17090b388100b00219741bac53si5623049pjb.123.2022.12.02.01.21.32; Fri, 02 Dec 2022 01:21:42 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@icenowy.me header.s=zmail header.b=Rpcfg4DC; arc=pass (i=1 spf=pass spfdomain=icenowy.me dkim=pass dkdomain=icenowy.me dmarc=pass fromdomain=icenowy.me>); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232688AbiLBIUA (ORCPT + 82 others); Fri, 2 Dec 2022 03:20:00 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36232 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232619AbiLBISk (ORCPT ); Fri, 2 Dec 2022 03:18:40 -0500 Received: from sender4-op-o18.zoho.com (sender4-op-o18.zoho.com [136.143.188.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A400540900; Fri, 2 Dec 2022 00:18:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669969067; cv=none; d=zohomail.com; s=zohoarc; b=L07URF0wZwvYLggDZBZA2tPzDguru9spJ9HLUaaqTScJMHkVuHssoB9ao8PjKzH7h/4D+ZMzQpH8JSNNGspnc7ekTVIFZ8FmC7nutyVPTde77XZkgEBGFxJ/z6/c7ikC4uKyJR4fBKl7IU23cnZTV61Ci/On/iO1AUPb7f1p9tU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1669969067; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:To; bh=OLlTVhT3idm/OLIzzgRQz3I7RcmreMDAJB3HnjwLFY4=; b=KKamnyA3wSZPymAl9DS7KO6THAibSn+MZYwCiK/gENsyXlIKbLd0TXIqPcjiIjMVzW8iEBc0J/bVYYkpFQhzHu5tTVALp7naNIby+SUKhLJb7kYZEfHIseuJkb4JxKJONWG4C4tWG2akt2ERSWfPZ2n8V1bYCjyu4YX77G6whiw= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=icenowy.me; spf=pass smtp.mailfrom=uwu@icenowy.me; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1669969067; s=zmail; d=icenowy.me; i=uwu@icenowy.me; h=From:From:To:To:Cc:Cc:Subject:Subject:Date:Date:Message-Id:Message-Id:In-Reply-To:References:MIME-Version:Content-Transfer-Encoding:Reply-To; bh=OLlTVhT3idm/OLIzzgRQz3I7RcmreMDAJB3HnjwLFY4=; b=Rpcfg4DCnEPWtpEZBN6E7Z6qizn7lKTxr2I+JkilHnsS4lR9XRfqX/ubPC7VvTYH G2pui6pVqoFPgghqgpo0KTRffLktyAcGSw8OQ2qOzGLG5B7UvZTXdXQKKKCrek0/H6Y Y1McqnZa/FEqYxaXcAf4sLMNn/MKCfS0chYfXblk= Received: from edelgard.fodlan.icenowy.me (120.85.99.229 [120.85.99.229]) by mx.zohomail.com with SMTPS id 1669969066601638.7158094915221; Fri, 2 Dec 2022 00:17:46 -0800 (PST) From: Icenowy Zheng To: Rob Herring , Krzysztof Kozlowski , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Greg Kroah-Hartman , Matthias Kaehlcke , Andre Przywara Cc: devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org, Icenowy Zheng Subject: [PATCH v2 3/6] usb: misc: onboard_usb_hub: add Genesys Logic GL850G hub support Date: Fri, 2 Dec 2022 16:16:44 +0800 Message-Id: <20221202081647.3183870-4-uwu@icenowy.me> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221202081647.3183870-1-uwu@icenowy.me> References: <20221202081647.3183870-1-uwu@icenowy.me> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-ZohoMailClient: External X-Spam-Status: No, score=-0.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLACK autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Genesys Logic GL850G is a 4-port USB 2.0 STT hub that has a reset pin to toggle and a 3.3V core supply exported (although an integrated LDO is available for powering it with 5V). Add the support for this hub, for controlling the reset pin and the core power supply. Signed-off-by: Icenowy Zheng --- Changes in v2: - Sort things, by names or vendor IDs. drivers/usb/misc/onboard_usb_hub.c | 2 ++ drivers/usb/misc/onboard_usb_hub.h | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/drivers/usb/misc/onboard_usb_hub.c b/drivers/usb/misc/onboard_usb_hub.c index d63c63942af1..94e7966e199d 100644 --- a/drivers/usb/misc/onboard_usb_hub.c +++ b/drivers/usb/misc/onboard_usb_hub.c @@ -331,6 +331,7 @@ static struct platform_driver onboard_hub_driver = { /************************** USB driver **************************/ +#define VENDOR_ID_GENESYS 0x05e3 #define VENDOR_ID_MICROCHIP 0x0424 #define VENDOR_ID_REALTEK 0x0bda #define VENDOR_ID_TI 0x0451 @@ -407,6 +408,7 @@ static void onboard_hub_usbdev_disconnect(struct usb_device *udev) } static const struct usb_device_id onboard_hub_id_table[] = { + { USB_DEVICE(VENDOR_ID_GENESYS, 0x0608) }, /* Genesys Logic GL850G USB 2.0 */ { USB_DEVICE(VENDOR_ID_MICROCHIP, 0x2514) }, /* USB2514B USB 2.0 */ { USB_DEVICE(VENDOR_ID_REALTEK, 0x0411) }, /* RTS5411 USB 3.1 */ { USB_DEVICE(VENDOR_ID_REALTEK, 0x5411) }, /* RTS5411 USB 2.1 */ diff --git a/drivers/usb/misc/onboard_usb_hub.h b/drivers/usb/misc/onboard_usb_hub.h index 34beab8bce3d..62129a6a1ba5 100644 --- a/drivers/usb/misc/onboard_usb_hub.h +++ b/drivers/usb/misc/onboard_usb_hub.h @@ -22,10 +22,15 @@ static const struct onboard_hub_pdata ti_tusb8041_data = { .reset_us = 3000, }; +static const struct onboard_hub_pdata genesys_gl850g_data = { + .reset_us = 3, +}; + static const struct of_device_id onboard_hub_match[] = { { .compatible = "usb424,2514", .data = µchip_usb424_data, }, { .compatible = "usb451,8140", .data = &ti_tusb8041_data, }, { .compatible = "usb451,8142", .data = &ti_tusb8041_data, }, + { .compatible = "usb5e3,608", .data = &genesys_gl850g_data, }, { .compatible = "usbbda,411", .data = &realtek_rts5411_data, }, { .compatible = "usbbda,5411", .data = &realtek_rts5411_data, }, { .compatible = "usbbda,414", .data = &realtek_rts5411_data, }, -- 2.38.1