From patchwork Mon Feb 5 13:59:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Roger Quadros X-Patchwork-Id: 196833 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:168b:b0:106:860b:bbdd with SMTP id ma11csp892557dyb; Mon, 5 Feb 2024 06:03:48 -0800 (PST) X-Google-Smtp-Source: AGHT+IGzzfnz3gt9ysrvY2zx+X04DJ4ZPNx3T1clW07wN6JKIxmaiAHTKhYaIKwFUXQSb50jHbbh X-Received: by 2002:ac8:48d5:0:b0:42a:b153:2331 with SMTP id l21-20020ac848d5000000b0042ab1532331mr3790925qtr.0.1707141827839; Mon, 05 Feb 2024 06:03:47 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707141827; cv=pass; d=google.com; s=arc-20160816; b=ytLJ5BNysfBXgStweyrHnKRuuv7dSlUYLfRLPFDwjQGwbvuYJcioTlcmjQMEuaQZwo 2CROGVKLUKAL89jkOHbU5Vr08nVVrT7izO0hGY9KDxuJ+fxsz51iyDrNS79WlLI9KCFL xhG2LzThfF+iUZQUXPZW2TlMJcNBGQdvb8apSUCdIIasPSyZ3DV+7NTeuUwSnOBLP4uV gJ8ZTLkqkPCH5ZCiP595cWlNV+oFd2U/pN3EVEiqneINShe0TDrn4zLqkCsej5tYunJW CsyceJ1DiR0tgKxy9Dakl3hHgenYkoOvDmVCHlzOjGIWOoZBZJZihU3UOW21s3JAbqmd i8fw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=UlJKK3TYe1LfT5pZ0vAB32pXg5aahGL0IXy3bvT8ocM=; fh=8Z+cR8tglEV3/2sJWiNjSv+14qzTT93verB/plST6kg=; b=M4Lu1EXyWwD6cY/SAzgWjr/Cu1Hm3gWnZZmutEcmGjlCYVGl8vauLUyB4LQFa0yk1X 3QIUprgEwz+In5iIlL5LbZbbvo/TPdbmTVETfrYx1Hn7zX55QPogzW7WHWp7g2/0TP+k XFEInOcGYsqFQWwOD4gTNytJsj0HX0TOZ/HCHTit7y/STQ4aJugtf6XVt6xn56WXCyyO MlWBUeQYRJccwvWFJWdUowJL81RK1bj6w/E3xhCrhyEhDNrfHO6ztF+R494zkeyW8D4l k2pvsQT1S1Fj+w5GvTeUzrsdlGjS9UJRO1JDj9Abwgw0qcn2N5zdqfUDNCtqnLVeUK/h 9xEA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Ao7fJbAS; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-52767-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-52767-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org X-Forwarded-Encrypted: i=1; AJvYcCWfRDff98Sr/ZOCyW1Bx1ze6TMP1/Sz5Wbibez3Q5SwFGxoPJR+Zek0ib5J8uujoGUbjJjYoptYmzAaz7zbKF9hQ9q4oA== Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id i15-20020ac85e4f000000b0042c2a62dd53si1171646qtx.785.2024.02.05.06.03.47 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 06:03:47 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-52767-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Ao7fJbAS; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-52767-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-52767-ouuuleilei=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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 3F3BB1C21B61 for ; Mon, 5 Feb 2024 14:00:10 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 060262C6B5; Mon, 5 Feb 2024 13:59:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Ao7fJbAS" 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 4C3222C694; Mon, 5 Feb 2024 13:59:19 +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=1707141560; cv=none; b=BOvElu1HHLSlGJy+5F7WYBVmkIldh828CLWwIMmea20v/lhfFhCpW5fuhlyUQOof2GBLW8yHyhdUKL7NNINbilIXcqDLZAXySd05nimq4l1PfSLmJZBXJpa8t/LpPT80Ipr5gYL7M85nfP4+qM91AqRfQ/ATj/pSS6WY5Ye1KTw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707141560; c=relaxed/simple; bh=e5Ol44cNhbsUA6CtDEObMa0YcRvE9WJtvaMsnXPBe0I=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=ILImiFviRBfWeu5/WOCww9OdbrzLtZ06zp147Vsdx1YT4JhCVkBRcn5+DxHGDn/og9isB2nykXZ2Nm3It2WcK8gDyLVEEbEZ6Cc5zar3Tpu23kGxpQ0MnLj14XJLZffHm4xUDPSjGf9i6bH3nMKwXfwhEWFeWlLZ10615VG0oUY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Ao7fJbAS; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 52925C433C7; Mon, 5 Feb 2024 13:59:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1707141559; bh=e5Ol44cNhbsUA6CtDEObMa0YcRvE9WJtvaMsnXPBe0I=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Ao7fJbASJoBH9GKzma11WC4oZ4jnlg+TWrWxAdIMkI168FpDcqw4p9ZiE0EmfBF/y HQsq2YBX8LSMjho2HTtnSuxMzFf5rTLBRPGo+b3KVdfSuv2LmL2xUG+uHRnLioc2dp dT99AFV1qST8MehPP2v/TLjB6TqjVi418S/Ia2+7d6Sdrh8tvcwcfsj3d4AZrfcGLM QFxrpFEWVycxtHtEnPZJIirHKvEAJdABRIYJ8aJKEle9YC8v3wvMUK1TxMf4OCCNhb h0+XuGxogW5WFkTcDhTFNQueOVQJullbt5T9TVxj86UEm+s3yHQXqVHwjgIqI2WpQt +UJWlLPeUGwpw== From: Roger Quadros To: 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, r-gunasekaran@ti.com, b-liu@ti.com, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Roger Quadros , Rob Herring Subject: [PATCH v4 1/3] dt-bindings: mfd: syscon: Add ti,am62-usb-phy-ctrl compatible Date: Mon, 5 Feb 2024 15:59:06 +0200 Message-Id: <20240205135908.54656-2-rogerq@kernel.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240205135908.54656-1-rogerq@kernel.org> References: <20240205135908.54656-1-rogerq@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790067949351483418 X-GMAIL-MSGID: 1790067949351483418 Add the compatible for TI AM62 USB PHY Control register. This register is found in the TI AM62 WKUP_CTRL_MMR0 space [1]. It is used to indicate the USB PHY PLL reference clock rate and core voltage level to the USB controller. [1] - https://www.ti.com/lit/pdf/spruiv7 Signed-off-by: Roger Quadros Acked-by: Rob Herring --- Notes: Changelog: v4 - no change. Added Rob's Acked-by v3 - add compatibles in alphabetical order https://lore.kernel.org/all/20240201120332.4811-2-rogerq@kernel.org/ v2 - New patch Documentation/devicetree/bindings/mfd/syscon.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/mfd/syscon.yaml b/Documentation/devicetree/bindings/mfd/syscon.yaml index 084b5c2a2a3c..9437705af92f 100644 --- a/Documentation/devicetree/bindings/mfd/syscon.yaml +++ b/Documentation/devicetree/bindings/mfd/syscon.yaml @@ -72,6 +72,7 @@ properties: - rockchip,rk3588-qos - rockchip,rv1126-qos - starfive,jh7100-sysmain + - ti,am62-usb-phy-ctrl - ti,am654-dss-oldi-io-ctrl - const: syscon From patchwork Mon Feb 5 13:59:07 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Roger Quadros X-Patchwork-Id: 196834 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:168b:b0:106:860b:bbdd with SMTP id ma11csp892843dyb; Mon, 5 Feb 2024 06:04:05 -0800 (PST) X-Google-Smtp-Source: AGHT+IGjvwoe/marCrjrp7Q+XRgcDDxRiCtJri/FjCbT8mwJ6q79v6Cqh5eWdsUsh9Xpx2a6SucP X-Received: by 2002:a05:6870:b50c:b0:219:a4e:e6b0 with SMTP id v12-20020a056870b50c00b002190a4ee6b0mr9766083oap.29.1707141844929; Mon, 05 Feb 2024 06:04:04 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707141844; cv=pass; d=google.com; s=arc-20160816; b=LWfHJSXop4TctnELXIPvxsysYfr/pt0CibWj5qfyUk/aj/r6HU/+h1mq+4PkX0kUGB FOck8ckiN3capc8d2UVZNqzAFcSMJ/aAdgJKzeq2QzENSW0eBLgNs0KfdNSJfatRCNv0 vftqDAAPTUYpkCRkdiQPHge6pKcKsxTekbccsFcfEdJzqtdxeOGgYp/34DNx2mQVCxRS QBUeYxPVjEvvbYxLxVXZoCMVAnDuAsCBm9rLOiRItCt4m1eGG4224fwrbhhDv2h3pfEy 08jCu5PA5tFbGXze0tXeOXK7QmdueE82Q6Q+yELCuFc2a8lpWEmgdM8z+D8i+TtL4pl+ eI0Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=wg/9MD0KvSmEQjrv4tKby2XKJ3M7gF8JOno6mIIW5ps=; fh=e6k+iwB9P7671PXbmVh4VOQqY+vPRNgSGfFacZvMzeI=; b=kirn6tmVnPiEvcX1kePNrx1xS4jZP+8uf23wtOt8ZtrpcJCmniRLQ31de88rBoN2Iw fSors/V8sFEMmvlIYpdlo/k4hDtzgb7r9hBPIGnQ1ZD0NsSZuavjQebRy24fuMAT54Ag X6nk+lBcv3Eb+s1aivC1ptzOaD0pIfEI5ihjeIT17EUo01awGh0eERTs1I80IPMFPyLj T1st7Lz/zwcjcgbcb3wrIx0M7m/9jmgxEcvLsxEpLCzvgZMm9BL+ZDkiFZr0Xhrw3IFh PVkmToYKsr7q6j8p40kcRq7+tvPH/7a7HSmkIbkZq9d620Aw5QIt3YoZ2vpUp8L/SK07 PXbA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="r/AEeLFd"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-52768-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-52768-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org X-Forwarded-Encrypted: i=1; AJvYcCUz3bULA84QOJfSWntqR7MQp42jhfzrCQhh+ehx/tMw3L5S8FMG1TzNzQ/Dq67EyCMSW4YyEndtiCXv3Fno0Qf3V/ZZFw== Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id m195-20020a1feecc000000b004c01cc8f41fsi414052vkh.186.2024.02.05.06.04.04 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 06:04:04 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-52768-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="r/AEeLFd"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-52768-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-52768-ouuuleilei=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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 6EBF81C24482 for ; Mon, 5 Feb 2024 14:00:25 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C91D82D022; Mon, 5 Feb 2024 13:59:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="r/AEeLFd" 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 F26DC2C6BD; Mon, 5 Feb 2024 13:59:23 +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=1707141564; cv=none; b=H5ATyzKmr5vDhhaI73LkMmZStLXdRd7PAic73fWTZcP5lczJHV/APJO5te+iA+YOCerP0HIJPmxtyWs2ZtxDFpsZ+6hp3bXG+emenYkowJ0Iwe5AzddJtZcUk1l/+6wnRmW5f6HouFqCAqJ7goY/95CnJyztA6nTZO06kkGHRbw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707141564; c=relaxed/simple; bh=JEgggokwb2If7xWTrfi//S5h0c1XCgpyqpnsTwc0H+4=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=ujWKqAyjmXg6kQa2Mi2y10y558DgPmBHW4XFW09K+ushS6P+5z4KleeH+PPjdH9QkK0s8i8+JAgaO826ePSCSm1MKjz4uiOHzKF3Loe76OUa0n+BGuJi+NuZzS8PuAMuaTN3//dsLo1jK2Wi6QclTA19lzV7gjG5ljv3iPVeHaA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=r/AEeLFd; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 48BFCC433A6; Mon, 5 Feb 2024 13:59:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1707141563; bh=JEgggokwb2If7xWTrfi//S5h0c1XCgpyqpnsTwc0H+4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=r/AEeLFdsAOPNQ5S008YB+iLG93daK3+Jel3DGrHt1ans5fmRg3OTzoMXar0S+tOH aQ5rxBAH5dLstze1krk0rVs25dF2l2lAIZve8jQ0Ndcmhr9RT1Vh6cbM7OcybzYqMn ezFGtH++UVwARaoOEE9JNeTvFQA5ArMessvDuH+P8KfxSmNn1YN1VnXFHnwJIdHXrI TyhllWg3KUwJ7JhuPiKi278x705YJv7mU1MCALlAh813l4sRElglceMa1a5rBmBvVc b/XrvdGZSidAX5LcqHz0ShwbMo/oe2xSo2GQN1hVsJR6xpvgbWKvcR0ZvpC77qIXbT zMw3UKPSkURgQ== From: Roger Quadros To: 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, r-gunasekaran@ti.com, b-liu@ti.com, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Roger Quadros Subject: [PATCH v4 2/3] arm64: dts: ti: k3-am62/a: use sub-node for USB_PHY_CTRL registers Date: Mon, 5 Feb 2024 15:59:07 +0200 Message-Id: <20240205135908.54656-3-rogerq@kernel.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240205135908.54656-1-rogerq@kernel.org> References: <20240205135908.54656-1-rogerq@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790067967047001782 X-GMAIL-MSGID: 1790067967047001782 Exposing the entire CTRL_MMR space to syscon is not a good idea. Add sub-nodes for USB0_PHY_CTRL and USB1_PHY_CTRL and use them in the USB0/USB1 nodes. Signed-off-by: Roger Quadros Reviewed-by: Andrew Davis --- Notes: Changelog: v4 - no change. Added Andrew's Reviewed-by v3 - no change https://lore.kernel.org/all/20240201120332.4811-3-rogerq@kernel.org/ v2: - moved am62p changes to next patch - use new compatible for USB PHY CTRL node arch/arm64/boot/dts/ti/k3-am62-main.dtsi | 4 ++-- arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi | 10 ++++++++++ arch/arm64/boot/dts/ti/k3-am62a-main.dtsi | 4 ++-- arch/arm64/boot/dts/ti/k3-am62a-wakeup.dtsi | 10 ++++++++++ 4 files changed, 24 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/ti/k3-am62-main.dtsi b/arch/arm64/boot/dts/ti/k3-am62-main.dtsi index 464b7565d085..9432ed344d52 100644 --- a/arch/arm64/boot/dts/ti/k3-am62-main.dtsi +++ b/arch/arm64/boot/dts/ti/k3-am62-main.dtsi @@ -625,7 +625,7 @@ usbss0: dwc3-usb@f900000 { reg = <0x00 0x0f900000 0x00 0x800>; clocks = <&k3_clks 161 3>; clock-names = "ref"; - ti,syscon-phy-pll-refclk = <&wkup_conf 0x4008>; + ti,syscon-phy-pll-refclk = <&usb0_phy_ctrl 0x0>; #address-cells = <2>; #size-cells = <2>; power-domains = <&k3_pds 178 TI_SCI_PD_EXCLUSIVE>; @@ -648,7 +648,7 @@ usbss1: dwc3-usb@f910000 { reg = <0x00 0x0f910000 0x00 0x800>; clocks = <&k3_clks 162 3>; clock-names = "ref"; - ti,syscon-phy-pll-refclk = <&wkup_conf 0x4018>; + ti,syscon-phy-pll-refclk = <&usb1_phy_ctrl 0x0>; #address-cells = <2>; #size-cells = <2>; power-domains = <&k3_pds 179 TI_SCI_PD_EXCLUSIVE>; diff --git a/arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi b/arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi index fef76f52a52e..817700b2eacf 100644 --- a/arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi +++ b/arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi @@ -19,6 +19,16 @@ chipid: chipid@14 { compatible = "ti,am654-chipid"; reg = <0x14 0x4>; }; + + usb0_phy_ctrl: syscon@4008 { + compatible = "ti,am62-usb-phy-ctrl", "syscon"; + reg = <0x4008 0x4>; + }; + + usb1_phy_ctrl: syscon@4018 { + compatible = "ti,am62-usb-phy-ctrl", "syscon"; + reg = <0x4018 0x4>; + }; }; wkup_uart0: serial@2b300000 { diff --git a/arch/arm64/boot/dts/ti/k3-am62a-main.dtsi b/arch/arm64/boot/dts/ti/k3-am62a-main.dtsi index f0b8c9ab1459..8311c7c44cd3 100644 --- a/arch/arm64/boot/dts/ti/k3-am62a-main.dtsi +++ b/arch/arm64/boot/dts/ti/k3-am62a-main.dtsi @@ -566,7 +566,7 @@ usbss0: dwc3-usb@f900000 { reg = <0x00 0x0f900000 0x00 0x800>; clocks = <&k3_clks 161 3>; clock-names = "ref"; - ti,syscon-phy-pll-refclk = <&wkup_conf 0x4008>; + ti,syscon-phy-pll-refclk = <&usb0_phy_ctrl 0x0>; #address-cells = <2>; #size-cells = <2>; power-domains = <&k3_pds 178 TI_SCI_PD_EXCLUSIVE>; @@ -589,7 +589,7 @@ usbss1: dwc3-usb@f910000 { reg = <0x00 0x0f910000 0x00 0x800>; clocks = <&k3_clks 162 3>; clock-names = "ref"; - ti,syscon-phy-pll-refclk = <&wkup_conf 0x4018>; + ti,syscon-phy-pll-refclk = <&usb1_phy_ctrl 0x0>; #address-cells = <2>; #size-cells = <2>; power-domains = <&k3_pds 179 TI_SCI_PD_EXCLUSIVE>; diff --git a/arch/arm64/boot/dts/ti/k3-am62a-wakeup.dtsi b/arch/arm64/boot/dts/ti/k3-am62a-wakeup.dtsi index 4e8279fa01e1..4a375f5e0c19 100644 --- a/arch/arm64/boot/dts/ti/k3-am62a-wakeup.dtsi +++ b/arch/arm64/boot/dts/ti/k3-am62a-wakeup.dtsi @@ -17,6 +17,16 @@ chipid: chipid@14 { compatible = "ti,am654-chipid"; reg = <0x14 0x4>; }; + + usb0_phy_ctrl: syscon@4008 { + compatible = "ti,am62-usb-phy-ctrl", "syscon"; + reg = <0x4008 0x4>; + }; + + usb1_phy_ctrl: syscon@4018 { + compatible = "ti,am62-usb-phy-ctrl", "syscon"; + reg = <0x4018 0x4>; + }; }; wkup_uart0: serial@2b300000 { From patchwork Mon Feb 5 13:59:08 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Roger Quadros X-Patchwork-Id: 196832 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:168b:b0:106:860b:bbdd with SMTP id ma11csp890721dyb; Mon, 5 Feb 2024 06:01:47 -0800 (PST) X-Google-Smtp-Source: AGHT+IE6VN8SAYSpJHURVSN8D6o2pKoL9ZGQibV2J0gvX78Oko/asoiaO8uXnsVFr6VyThGPCiwR X-Received: by 2002:a05:6a00:c91:b0:6e0:3f77:ddcd with SMTP id a17-20020a056a000c9100b006e03f77ddcdmr3487313pfv.25.1707141707305; Mon, 05 Feb 2024 06:01:47 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707141707; cv=pass; d=google.com; s=arc-20160816; b=DSEWh/7XnTjn6AAk/DIRXWGcxWUWLKH2OocKyUAvXt0gr9acbevV7CViqnrRc7r31O diT8H8MruRH0hvzSVD7fmNDgA1WhWIOnm68813hZ6c7TULbwhZ5KDNqxjxoumCcsVRpv 7j3/z/bTQ1zMLY6LUbQZvaxdu3FLDLknhl9VEpn6SxYOFrHPeSRdxdweCXqmmUJRFNn4 bRgI3GeuoSdziBYea5j3eM0vSIQGK5ownUk+hfNpLDOhKHt2Oyq8eQuBWBVLsuCYmxPK K7cRdMZjDdUFm6y4AVlEhifjmbYtL7KdlZCsoa59m/Q6EkAQoTikq8Rgv9K8gLSe7jBr riwA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=DSqds4eiAjvqX9HYSgI9/BycjNoHJvex9W4O+cNh3S8=; fh=qZMA+RB4uHDPAsx1wdMH9vSaBsrWoUcaTbpi9kkaoGk=; b=AcJjkF67wAB6T88EWhW78ctPM/P4I9D2H/vvpBIX4LdoeULR73Riwb8r+fd5IhfHUl wHJMKn9cKZsM9nzovaMk9DrriMxBT/jjkbZFnrdulFd3ulHxtp9QLHw0eRGma2z0CN3q XDsWMvmBE61ONBe10HFVeR4qm1NRxwmzzUItm53reIFH/dP0yLYRNL1kyHWgzY3484pl lXniquejJby+/ALwO33yRxOGbK7Xfk3SVP6dTTNMXhYHx5klSD1XfuFfa1CmznI1Y/40 xcQFvj3aqL78DBElrczKLxvy9J2wUDZpk0lPlCtR86E3E5si5COUJbTLk2KiVWLO2dxt B0iw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=TXfVyZ8m; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-52769-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-52769-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org X-Forwarded-Encrypted: i=1; AJvYcCWFo/6ornAZueyN3ZGyyHN+6zHO2Mgq9FwzFetUGmuBlwmDw7fmPKYq7cl5HWei0AqliqO0F1/6SVfinaTrSbfk6PFM4w== Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id j23-20020a63e757000000b005d81bd54526si6122162pgk.893.2024.02.05.06.01.47 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 06:01:47 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-52769-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=TXfVyZ8m; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-52769-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-52769-ouuuleilei=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 sv.mirrors.kernel.org (Postfix) with ESMTPS id CD499284FD4 for ; Mon, 5 Feb 2024 14:00:40 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D26752D059; Mon, 5 Feb 2024 13:59:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="TXfVyZ8m" 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 D542724A19; Mon, 5 Feb 2024 13:59:27 +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=1707141567; cv=none; b=Jyx/KdcunSDiCIHrEUBYQ5baUgrWXwpb6VXL31j6X4zhefnwLr7Tk8xh4iXLAjH1SLjy9vyJI28DTiAaM7pAAo0d2y/56sKmwuhkpVrch7y/onz78/BOsAiqpQiSIHN02Il6j2+845Gfe2EvZf4s4i225RYTlrcssihNhBUp8/8= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707141567; c=relaxed/simple; bh=htiMBaVe3qitojJjfcyYAH1AaK0WWDmvAGtnfEOVx6I=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=ZcUKRTidg8VT049zs7m0bmnBHR3aCQRUNGj4nZxIJY860ua+orVj/WpJ6Yd4LL1W8sjroOB9+FcZRHSqcLhRoSXwXw+CgJiIwfMd014MHFr5C+mRtTu/DNpwvIpukYLqlaGHQ3QN/vIdQfRg1rbb1Owsk6UhqT/JIwb2TwPnkkY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=TXfVyZ8m; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0B360C43394; Mon, 5 Feb 2024 13:59:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1707141567; bh=htiMBaVe3qitojJjfcyYAH1AaK0WWDmvAGtnfEOVx6I=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=TXfVyZ8m53wc6ACo3T+ARdpmhFm3839izoeUALSgV87tja9ZlIrohJHA5TIw86QA5 r3FjBB9DX+DKaHMXlhWJjnKShWdlLr4/gdy1ifqVxpaK88FOqpC10F3a8FrrAyv3rn ka7T3HWeC1NSQx1/M7QxwYpVHM5b4l4guV8mwKSHroxh7AkAUGgSlVfDwKuErf+a8V uOYfJSWMeOpOeVfW0gzE512yjkL0EGr1ev1MS8ibw7+vH5fBDcpNVJcf7F1irGsoaR PfMat+Y/CoipsoRXgUKAY4Kqxc+eq5OOf6FHgvHsjhgOtUeh4bWeSfZoT8PrOlbSm4 Do8hdQVCKgGFQ== From: Roger Quadros To: 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, r-gunasekaran@ti.com, b-liu@ti.com, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Roger Quadros Subject: [PATCH v4 3/3] arm64: dts: ti: k3-am62p: add the USB sub-system Date: Mon, 5 Feb 2024 15:59:08 +0200 Message-Id: <20240205135908.54656-4-rogerq@kernel.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240205135908.54656-1-rogerq@kernel.org> References: <20240205135908.54656-1-rogerq@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790067822979421895 X-GMAIL-MSGID: 1790067822979421895 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 Reviewed-by: Andrew Davis --- Notes: Changelog: v4 - no change v3 - no change https://lore.kernel.org/all/20240201120332.4811-4-rogerq@kernel.org/ v2: - added USB PHY CTRL node changes here - changed USB wrapper node names to usb@ - changed Type-C chip node name to usb-power-control@ arch/arm64/boot/dts/ti/k3-am62p-main.dtsi | 46 ++++++++++++++ arch/arm64/boot/dts/ti/k3-am62p-wakeup.dtsi | 10 +++ arch/arm64/boot/dts/ti/k3-am62p5-sk.dts | 67 +++++++++++++++++++++ 3 files changed, 123 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..17d28390d587 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: usb@f900000 { + 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: usb@f910000 { + 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-am62p-wakeup.dtsi b/arch/arm64/boot/dts/ti/k3-am62p-wakeup.dtsi index 19f42b39394e..00dd38b02a52 100644 --- a/arch/arm64/boot/dts/ti/k3-am62p-wakeup.dtsi +++ b/arch/arm64/boot/dts/ti/k3-am62p-wakeup.dtsi @@ -18,6 +18,16 @@ chipid: chipid@14 { reg = <0x14 0x4>; bootph-all; }; + + usb0_phy_ctrl: syscon@4008 { + compatible = "ti,am62-usb-phy-ctrl", "syscon"; + reg = <0x4008 0x4>; + }; + + usb1_phy_ctrl: syscon@4018 { + compatible = "ti,am62-usb-phy-ctrl", "syscon"; + reg = <0x4018 0x4>; + }; }; wkup_uart0: serial@2b300000 { diff --git a/arch/arm64/boot/dts/ti/k3-am62p5-sk.dts b/arch/arm64/boot/dts/ti/k3-am62p5-sk.dts index 1773c05f752c..80be56c0a4e0 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: usb-power-controller@3f { + compatible = "ti,tps6598x"; + reg = <0x3f>; + + connector { + compatible = "usb-c-connector"; + label = "USB-C"; + self-powered; + data-role = "dual"; + power-role = "sink"; + ports { + #address-cells = <1>; + #size-cells = <0>; + port@0 { + reg = <0>; + usb_con_hs: endpoint { + remote-endpoint = <&usb0_hs_ep>; + }; + }; + }; + }; + }; +}; + &main_i2c1 { status = "okay"; pinctrl-names = "default"; @@ -460,6 +498,35 @@ cpsw3g_phy1: ethernet-phy@1 { }; }; +&usbss0 { + status = "okay"; + ti,vbus-divider; +}; + +&usbss1 { + status = "okay"; + ti,vbus-divider; +}; + +&usb0 { + usb-role-switch; + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + usb0_hs_ep: endpoint { + remote-endpoint = <&usb_con_hs>; + }; + }; +}; + +&usb1 { + dr_mode = "host"; + pinctrl-names = "default"; + pinctrl-0 = <&main_usb1_pins_default>; +}; + &mcasp1 { status = "okay"; #sound-dai-cells = <0>;