Received: by 2002:a05:7412:d1aa:b0:fc:a2b0:25d7 with SMTP id ba42csp978847rdb; Tue, 30 Jan 2024 04:41:43 -0800 (PST) X-Google-Smtp-Source: AGHT+IG2ruQI5MMsaOwlTIrdXN+o7zd1iqNDF0Fn1auSBDPDPxpQN5lyzgX7SI1R37hvuWmDBh6Q X-Received: by 2002:a05:6830:20cd:b0:6dc:813:6c3f with SMTP id z13-20020a05683020cd00b006dc08136c3fmr6691545otq.38.1706618503125; Tue, 30 Jan 2024 04:41:43 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706618503; cv=pass; d=google.com; s=arc-20160816; b=AxIONw2t21G8JhH4yvfA8Y6B9LmxfgWQRWgXRzbWv/MW4lhM+uBlobOblu2j3k6MJC bPiRfY5Suo8psEH1qaBFktuQcXGiV8WHgsFRsrg5Y1iM1iLbBkjmAIQzsblyqxwgaK8H NBaiDc/cSRrPl9C+dN84NFH5tS8cIMcrT9x3B9G35E1IOxKiXU3hcOWdLoljomDI+H5O 0dUUiBpjKo9cEj6fhNemK46hGX1dqltIOPZXTlTNWy69LsanErk9p6A/Q2zATxaLUMz2 x+P9Pa9uH7DyY6iiA/k6shOHN7Q7lGMsAvuUBdI5RKufA1ppKhWeURD+JcJBU1aTgq4E Id2Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=9E9fNEeFFdKNQeI2jT56TsCksr5fvnlILv7YFbsabs8=; fh=K/3tLgnjog7Mg0tY03h9G/9de+5H8yQnm8e9yiVhA+U=; b=WLf+NEsMppHwemZw39TT04AgY0z1Sj67hjfO96hibZJiKGLOuBBYatukECkb9+xo2n V2UuEqqyV+tu9EezOC7MmYuAIXnbtoq0glOAXKf3aQSV/qPeHVgrr1CtwgNyN8uDCdct +o6eYXzrwnUlWhEQmb+e3N8tw6jBe4cPei6ra0bfSiHFcVI4MRiaKSzRAGx/6f86Hx/r krxhuPIB3TNwW3VG8x80gF/21MGwg7HzPk6L4da9SAb1a8zwEPOfDuXeceMlmMDgjEtC 1Yw3ou/giRsOh7mrHwCo50LjJ2qY3SqawIBVtyU669AlGgN0vKIefYjpa5fitELM/NmJ CYOg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=X+8jDO25; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-44584-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-44584-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id z67-20020a633346000000b005d8e379746fsi1130416pgz.469.2024.01.30.04.41.42 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Jan 2024 04:41:43 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-44584-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=X+8jDO25; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-44584-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-44584-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 74F0FB2F9AA for ; Tue, 30 Jan 2024 12:11:03 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B86B567E87; Tue, 30 Jan 2024 12:10:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="X+8jDO25" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C553367A10; Tue, 30 Jan 2024 12:10:09 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706616610; cv=none; b=aoTl/vprViuC6qNkB1eW8U5el6VFwcVL9+PMap8uI4J5G46p04dqPvKBSjpXIk4VgnRr7ct032I5RDEtGO1fhtZXyzHaq49dxK8O7fTaR1XqE9cX2o8SFT7Ode4uPKGIOuRqL6Y+by15IRlqjaaBT/OjzS96wOrAkBqVd6bfkfo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706616610; c=relaxed/simple; bh=Rf/2bGcKWqfTSjgtmsaV3E5nuVmMnoGUoJPbVEXxFeI=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=I4sxZEnSQuCdk1742zDOHRyPCcP9Vtdyq5HOWxA1VK1V2iRm/QEbtrdxfBJx5b3AssTQkkAVjOU8hLNuuTcfSsMonfmkLhvrbFsDYyx1Zuk4j9IkQIaTb3dsPpO66Bn8CTt/mFzFDg5kxOoOLL/OGpABkAsbeTsNvly2Mm7TEto= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=X+8jDO25; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 8F052C433F1; Tue, 30 Jan 2024 12:10:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1706616609; bh=Rf/2bGcKWqfTSjgtmsaV3E5nuVmMnoGUoJPbVEXxFeI=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=X+8jDO25v2bvERaOl4vwaKHzBrnOmKobZ/+ZmePShNGyf0ideGDJnp64b1Qu2vs2p EE1ilgNTQvaxik/9Axb9WMAzkb5Wa1zkTJFpxUJD9aKllfZ3yeqC6m0ETXND4vZaWJ Eg/ujl9CzT7lcV3wDgpwH6RexeZ8+puCvRS/5oS1t/YdefW4Grse2txtNloTsaN4Kb z5F5FoB/feoxCUAspsSZYdTSFM3R3YRISlY+CBkBMPBrGG4RTO+F7qTL3x5cvTBr0V /i51XP/uxTWl1mt6PsZlyo82BNknt7lCnkC/asNT9h/TSruINLU1HwzmdSEUZqSiDv fGBilTMvtcbCA== Message-ID: <30f0154c-37c7-468c-911e-027c51c8d69b@kernel.org> Date: Tue, 30 Jan 2024 14:10:03 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 2/2] arm64: dts: ti: k3-am62p: add the USB sub-system Content-Language: en-US To: Krzysztof Kozlowski , nm@ti.com, vigneshr@ti.com Cc: afd@ti.com, kristo@kernel.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, srk@ti.com, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org References: <20240126125951.18585-1-rogerq@kernel.org> <20240126125951.18585-3-rogerq@kernel.org> <0bc7081f-f279-4741-b14e-198b2d00d5d0@linaro.org> From: Roger Quadros In-Reply-To: <0bc7081f-f279-4741-b14e-198b2d00d5d0@linaro.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 26/01/2024 17:11, Krzysztof Kozlowski wrote: > On 26/01/2024 13:59, Roger Quadros wrote: >> From: Vignesh Raghavendra >> >> There are two USB instances available on the am62p5 starter kit. Include >> and enable them for use on the board. >> >> Signed-off-by: Vignesh Raghavendra >> Signed-off-by: Roger Quadros >> --- >> arch/arm64/boot/dts/ti/k3-am62p-main.dtsi | 46 ++++++++++++++++ >> arch/arm64/boot/dts/ti/k3-am62p5-sk.dts | 67 +++++++++++++++++++++++ >> 2 files changed, 113 insertions(+) >> >> diff --git a/arch/arm64/boot/dts/ti/k3-am62p-main.dtsi b/arch/arm64/boot/dts/ti/k3-am62p-main.dtsi >> index 4c51bae06b57..7e7cd749d9a5 100644 >> --- a/arch/arm64/boot/dts/ti/k3-am62p-main.dtsi >> +++ b/arch/arm64/boot/dts/ti/k3-am62p-main.dtsi >> @@ -560,6 +560,52 @@ sdhci2: mmc@fa20000 { >> status = "disabled"; >> }; >> >> + usbss0: dwc3-usb@f900000 { > > usb@ OK. > >> + compatible = "ti,am62-usb"; >> + reg = <0x00 0x0f900000 0x00 0x800>; >> + clocks = <&k3_clks 161 3>; >> + clock-names = "ref"; >> + ti,syscon-phy-pll-refclk = <&usb0_phy_ctrl 0x0>; >> + #address-cells = <2>; >> + #size-cells = <2>; >> + power-domains = <&k3_pds 178 TI_SCI_PD_EXCLUSIVE>; >> + ranges; >> + status = "disabled"; >> + >> + usb0: usb@31000000 { >> + compatible = "snps,dwc3"; >> + reg = <0x00 0x31000000 0x00 0x50000>; >> + interrupts = , /* irq.0 */ >> + ; /* irq.0 */ >> + interrupt-names = "host", "peripheral"; >> + maximum-speed = "high-speed"; >> + dr_mode = "otg"; >> + }; >> + }; >> + >> + usbss1: dwc3-usb@f910000 { > > usb@ > >> + compatible = "ti,am62-usb"; >> + reg = <0x00 0x0f910000 0x00 0x800>; >> + clocks = <&k3_clks 162 3>; >> + clock-names = "ref"; >> + ti,syscon-phy-pll-refclk = <&usb1_phy_ctrl 0x0>; >> + #address-cells = <2>; >> + #size-cells = <2>; >> + power-domains = <&k3_pds 179 TI_SCI_PD_EXCLUSIVE>; >> + ranges; >> + status = "disabled"; >> + >> + usb1: usb@31100000 { >> + compatible = "snps,dwc3"; >> + reg = <0x00 0x31100000 0x00 0x50000>; >> + interrupts = , /* irq.0 */ >> + ; /* irq.0 */ >> + interrupt-names = "host", "peripheral"; >> + maximum-speed = "high-speed"; >> + dr_mode = "otg"; >> + }; >> + }; >> + >> fss: bus@fc00000 { >> compatible = "simple-bus"; >> reg = <0x00 0x0fc00000 0x00 0x70000>; >> diff --git a/arch/arm64/boot/dts/ti/k3-am62p5-sk.dts b/arch/arm64/boot/dts/ti/k3-am62p5-sk.dts >> index 1773c05f752c..7a16e7a8ac66 100644 >> --- a/arch/arm64/boot/dts/ti/k3-am62p5-sk.dts >> +++ b/arch/arm64/boot/dts/ti/k3-am62p5-sk.dts >> @@ -27,6 +27,8 @@ aliases { >> spi0 = &ospi0; >> ethernet0 = &cpsw_port1; >> ethernet1 = &cpsw_port2; >> + usb0 = &usb0; >> + usb1 = &usb1; >> }; >> >> chosen { >> @@ -297,6 +299,12 @@ AM62PX_IOPAD(0x01b0, PIN_OUTPUT, 2) /* (G20) MCASP0_ACLKR.UART1_TXD */ >> bootph-all; >> }; >> >> + main_usb1_pins_default: main-usb1-default-pins { >> + pinctrl-single,pins = < >> + AM62PX_IOPAD(0x0258, PIN_INPUT, 0) /* (G21) USB1_DRVVBUS */ >> + >; >> + }; >> + >> main_wlirq_pins_default: main-wlirq-default-pins { >> pinctrl-single,pins = < >> AM62PX_IOPAD(0x0128, PIN_INPUT, 7) /* (K25) MMC2_SDWP.GPIO0_72 */ >> @@ -340,6 +348,36 @@ AM62PX_IOPAD(0x0124, PIN_INPUT, 7) /* (J25) MMC2_SDCD.GPIO0_71 */ >> }; >> }; >> >> +&main_i2c0 { >> + status = "okay"; >> + pinctrl-names = "default"; >> + pinctrl-0 = <&main_i2c0_pins_default>; >> + clock-frequency = <400000>; >> + >> + typec_pd0: tps6598x@3f { > > Node names should be generic. See also an explanation and list of > examples (not exhaustive) in DT specification: > https://devicetree-specification.readthedocs.io/en/latest/chapter2-devicetree-basics.html#generic-names-recommendation > got it. Thanks! > >> + compatible = "ti,tps6598x"; >> + reg = <0x3f>; >> + >> + connector { >> + compatible = "usb-c-connector"; >> + label = "USB-C"; >> + self-powered; >> + data-role = "dual"; >> + power-role = "sink"; >> + ports { > > > Best regards, > Krzysztof > -- cheers, -roger