From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.9 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,INCLUDES_PATCH,MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_2 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id EEFBCC433EF for ; Wed, 15 Sep 2021 13:14:29 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id AC9786121E for ; Wed, 15 Sep 2021 13:14:29 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org AC9786121E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=RAsOqxvM0QElED8/xGPAZA9/ADxt7hhS9vNVyengFDI=; b=H53eNIx4ous/QE ZwMpcX64KpkVQbuTjwv2d20A/eDR9H6gGbxsFrkTf/OWCjDWUXzVdLp7u+0BDOML/nUzm+X9nSjrO gvC8V9WwcsaxEhkOn2acPjsCR1D2YAd76XNdTlAjs0KaglE3l6xFromcihEIgdgL6oqF36LfUKTCw 76RvOQQf0EdJ16U46UBNBn07/lNu3Qtky5pjDaQzmCze+dCEdmoAI6mx8mT0v9D5qwnQvag+LOBVB 26bEL+NM4zazbWEmavQixxsdvy01Grzmceu5xm/eNN0mmYaitpxjq4AhRZNDzGM7bIkGQfaeGHSrX Nh569y4VvCrcPmtReMkw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mQUiH-0098AY-H2; Wed, 15 Sep 2021 13:12:33 +0000 Received: from mail.kernel.org ([198.145.29.99]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mQUiC-00989x-PS for linux-arm-kernel@lists.infradead.org; Wed, 15 Sep 2021 13:12:30 +0000 Received: by mail.kernel.org (Postfix) with ESMTPSA id D6A9960EE9; Wed, 15 Sep 2021 13:12:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1631711548; bh=Tgj6lWad0kfmypMmQ8v100CX104+68bT6piB1POZn7c=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=Nnxzt6MkP7YiKDZqB2wuAHUa5ZLPfaNmsIEupx5IW23dL/E3ja+7mchQBgXEqy9LR XfFSyOF3g/4CP7Mm5oiKdisJvbz+XdytpqxT+KUJpMs6r7XPacjo9OWBycIMQaMG2D lbJG8gT824xCCbYmKdXos/u7pg3y/xMsyrLrk1HWGgOWLEopf9PWxNq0FK1gC0JTJg rbqN1OeDPISd553gqFuhtZ4BJZ0EUNyftWDCii3sXV750R7FWzLgm+a5oPBCwWHpba +LiZ4PGRD7z8RmXCW3tNIL5x3BPfhh/QmvAAdp6Yy61ZB9pBbcETv7nkSOPPuDF0pt np1PNhXcJ/uBw== Date: Wed, 15 Sep 2021 15:12:24 +0200 From: Mauro Carvalho Chehab To: Rob Herring , John Stultz Cc: linuxarm@huawei.com, mauro.chehab@huawei.com, Rob Herring , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v4 0/4] Make USB ports to work on HiKey960/970 Message-ID: <20210915151224.33e89d4f@coco.lan> In-Reply-To: References: X-Mailer: Claws Mail 4.0.0 (GTK+ 3.24.30; x86_64-redhat-linux-gnu) MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210915_061228_919806_6C617B57 X-CRM114-Status: GOOD ( 27.91 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi Rob, Em Fri, 3 Sep 2021 11:28:31 +0200 Mauro Carvalho Chehab escreveu: > Hi Rob, > > It follows the patchset adding a DT schema needed to power on and to > use the integrated USB hub found on HiKey 960 and Hikey 970 boards. > > Besides each board use a different chip for the hub, on both they're > controlled the same way. Such boards come with an integrated 4-port > USB hub on it, set on what it seems to be a non-standard way: on both > implementations, the USB type-C port is used to detect the USB role. > > When in host mode, the 3.3V power supply (VDD33 pins) for the hub > are disabled. That disables the USB I/O on type-A ports. > > When USB type-C is on device mode, the OTG is switched via a GPIO pin > to device mode, and the hub is powered on. > > A Type-C power supply line is also controlled depending on the role. Gentile ping. Regards, Mauro > > - > > The entire series which contains the remaining patches to support > PCI and USB on HiKey970, and USB on HiKey960 is at: > > https://github.com/mchehab/linux/commits/linux-master > > The patches needed by the USB on HiKey970 were already merged > upstream. So, the above branch applies on the top of Linux master > branch. > > Tested on HiKey 960: > > $ lsusb > Bus 002 Device 002: ID 0424:5734 Standard Microsystems Corp. > Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub > Bus 001 Device 004: ID 0424:2740 Standard Microsystems Corp. > Bus 001 Device 003: ID 046d:c52b Logitech, Inc. Unifying Receiver > Bus 001 Device 002: ID 0424:2734 Standard Microsystems Corp. > Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub > > Tested on HiKey 970: > > $ lsusb > Bus 002 Device 002: ID 0451:8140 Texas Instruments, Inc. TUSB8041 4-Port Hub > Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub > Bus 001 Device 003: ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode) > Bus 001 Device 002: ID 0451:8142 Texas Instruments, Inc. TUSB8041 4-Port Hub > Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub > > v4: > - Improved description at the DT schema; > - Use just one compatible, as there's no difference between > HiKey 960 and 970 with regards to how the hub should be > controlled; > - parse usb-role-switch property at the driver; > - make the properties that depends on usb-role-switch optional. > > v3: > - The examples at the dt-bindings were updated to reflect > the actual DTS content and won't produce any warnings; > - Added John Stultz SoB to Hikey960 DTS patch; > - Added a patch for the mux hub driver for it to work with > the newer schema; > > John Stultz (1): > arm64: dts: hisilicon: Add usb mux hub for hikey960 > > Mauro Carvalho Chehab (2): > misc: hisi_hikey_usb: change the DT schema > arm64: dts: hisilicon: Add usb mux hub for hikey970 > > Yu Chen (1): > dt-bindings: misc: add schema for USB hub on Kirin devices > > .../bindings/misc/hisilicon,hikey-usb.yaml | 87 +++++++++++++ > .../boot/dts/hisilicon/hi3660-hikey960.dts | 35 +++++- > .../boot/dts/hisilicon/hi3670-hikey970.dts | 23 ++++ > drivers/misc/hisi_hikey_usb.c | 119 +++++++++--------- > 4 files changed, 206 insertions(+), 58 deletions(-) > create mode 100644 Documentation/devicetree/bindings/misc/hisilicon,hikey-usb.yaml > Thanks, Mauro _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel