Message ID | 20240216135533.904130-3-vaishnav.a@ti.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel+bounces-68673-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:c619:b0:108:e6aa:91d0 with SMTP id hn25csp534388dyb; Fri, 16 Feb 2024 06:06:54 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWrv644JpKKc82M7OmrBwiDuZV5t3of3gucCGWjLQMooyvQNUodeilFq4pMPKKqg/iDcP/829sJJmhvAsrkGLdAAtu5Aw== X-Google-Smtp-Source: AGHT+IGQJN4m/z8V/T+12ZVpiFI8dMfwrchljOOJvzwfqf3gaZjYeToTt7xFhnFqQOCT65dpGHgB X-Received: by 2002:a17:902:bd84:b0:1d8:cc30:bb18 with SMTP id q4-20020a170902bd8400b001d8cc30bb18mr4756497pls.52.1708092414343; Fri, 16 Feb 2024 06:06:54 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708092414; cv=pass; d=google.com; s=arc-20160816; b=Ye99EfR4Yl4RoY8878smDsLTdILb0qMcykhb/ncTjOtWW8TI0v1UJs4Nb+Mj9bduzE hteptkRudJUd97II7loOtNrPgvGmqVWwgcCBfLfk1Vc+/jtyFRimcN3nMi2dp7fpsjJM rVVa0KQBgxeXkJ9wHJdNpDqW4Lwp1mpuq1EAQgY1FEV0cCrySWi3vlCAoPEOTFBqYPEo OdQ4RGjmXVLkEv6s85EZf7X7AV4KY4jyok6X05Q7B7x6fD3zLjSUTmMX1JSFEPO3+hm3 MkKnqm9kr1qqNXbXoJQsu9DwDl1nmMoi89lbhFTN010zLttQIjkS1gsahia2ktv9v1fO SXnA== 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=uTW/xCM8noa5bGfg4NZmPFvevjj/sJrMm1kJ3d4d4/E=; fh=j03uLb/fUHd4PvvwK6aOXFRssHiOxsq7jQ36+mIKgOU=; b=vXOsOjJrlAmmCcugKxNccD0aWYcrIuB9W+qSlBYKVAGXf10wK1NBMkrxrBafw2dGWp oj25h17KOGhj5Qw5s4nGbhkROXH61LpFQRwd5cPSt8yVQ1ei6OhavRSQN+AZDOGFagWx PmIp6ifSnac+eSaWslZj/d+Vt4u4mSBVVtou18u3jmSEZ3esN0ie3QxF3JOb3Fmez6hz frQvU3A6yqR5bCSrWUNi75cw0LDXK3/m6xHQc6rz3zXQ4krjNXKtndJ9T9EgfcUWpdka K5qNAhiRdCLKtoFn4xKpmaVidWfOE+o5N5OBrJFcMyGUIGMr+LTqWq2HlJ6KU0YbJlcH UDiQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b="qmqBO/9D"; arc=pass (i=1 spf=pass spfdomain=ti.com dkim=pass dkdomain=ti.com dmarc=pass fromdomain=ti.com); spf=pass (google.com: domain of linux-kernel+bounces-68673-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-68673-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id l13-20020a170902f68d00b001db9cab6129si1627956plg.575.2024.02.16.06.06.53 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 16 Feb 2024 06:06:54 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-68673-ouuuleilei=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=@ti.com header.s=ti-com-17Q1 header.b="qmqBO/9D"; arc=pass (i=1 spf=pass spfdomain=ti.com dkim=pass dkdomain=ti.com dmarc=pass fromdomain=ti.com); spf=pass (google.com: domain of linux-kernel+bounces-68673-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-68673-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com 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 54542B259E8 for <ouuuleilei@gmail.com>; Fri, 16 Feb 2024 13:56:20 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B977F12C7E5; Fri, 16 Feb 2024 13:55:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="qmqBO/9D" Received: from fllv0015.ext.ti.com (fllv0015.ext.ti.com [198.47.19.141]) (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 74C8712BF1B; Fri, 16 Feb 2024 13:55:50 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.47.19.141 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708091752; cv=none; b=Rd6sIgVPxTGlDKcvb2tUJpORhZiZbca8EtDX3p12VWR+nT2Yhv8l2Jb0DLdcosMzbbsJCo4rBkF5VNumnz75yCAIPwWezCdGZeecOCxNfoTpkgdj10l7WumNh6juXuEW6kKfn90NO9fnCNIKvunUucOOiArOs1MjQbyinJJZ9fY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708091752; c=relaxed/simple; bh=XYz1rPCO/pl409zYn8/NwIiH1CytMgN61xqsw1SrGmc=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=cp+JE4GTquAcpGaiHMEGklrUJvDeP+IUYP7VsjGduGUJ2ZgD5qdZSQ7fgQbk0lFAHQgeDRUZQyl+76AL8GHHvjJq8cFpDs4VQD4CsRt42LeeQTt5CeCtLmXwh5GW3qF0aUS4XeOS5RqBAn+1JPKqGD7+8YcVgkVEi416+lxLLKM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=qmqBO/9D; arc=none smtp.client-ip=198.47.19.141 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Received: from lelv0266.itg.ti.com ([10.180.67.225]) by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id 41GDtiCo095624; Fri, 16 Feb 2024 07:55:44 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1708091744; bh=uTW/xCM8noa5bGfg4NZmPFvevjj/sJrMm1kJ3d4d4/E=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=qmqBO/9DrTdAMBEuzBcZLozxuzRKb8h9U52eekScjjtvfLR4FZ/sxGlB2yChMJPra XjWBLAUEKlMyRrLk2GbqU9KO2WSmUyXNR/Cl3bQN6ilh6p8tqglMai0Ov4tsI6za7U i/HssslPdXics8GXB4H1SzqzLbMRHNnfrpgyh6sQ= Received: from DFLE108.ent.ti.com (dfle108.ent.ti.com [10.64.6.29]) by lelv0266.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 41GDtiOU015343 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Fri, 16 Feb 2024 07:55:44 -0600 Received: from DFLE108.ent.ti.com (10.64.6.29) by DFLE108.ent.ti.com (10.64.6.29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Fri, 16 Feb 2024 07:55:44 -0600 Received: from lelvsmtp5.itg.ti.com (10.180.75.250) by DFLE108.ent.ti.com (10.64.6.29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Fri, 16 Feb 2024 07:55:44 -0600 Received: from uda0490681.. ([10.24.69.142]) by lelvsmtp5.itg.ti.com (8.15.2/8.15.2) with ESMTP id 41GDtXrU127060; Fri, 16 Feb 2024 07:55:41 -0600 From: Vaishnav Achath <vaishnav.a@ti.com> To: <nm@ti.com>, <vigneshr@ti.com>, <kristo@kernel.org>, <robh@kernel.org>, <krzysztof.kozlowski+dt@linaro.org>, <conor+dt@kernel.org> CC: <linux-arm-kernel@lists.infradead.org>, <devicetree@vger.kernel.org>, <linux-kernel@vger.kernel.org>, <vaishnav.a@ti.com>, <u-kumar1@ti.com>, <s-vadapalli@ti.com> Subject: [PATCH 2/2] arm64: dts: ti: k3-j722s-evm: Enable OSPI NOR support Date: Fri, 16 Feb 2024 19:25:33 +0530 Message-ID: <20240216135533.904130-3-vaishnav.a@ti.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240216135533.904130-1-vaishnav.a@ti.com> References: <20240216135533.904130-1-vaishnav.a@ti.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1791064711199032578 X-GMAIL-MSGID: 1791064711199032578 |
Series |
Add OSPI and Ethernet support on J722S EVM
|
|
Commit Message
Vaishnav Achath
Feb. 16, 2024, 1:55 p.m. UTC
J722S EVM has S28HS512T 64 MiB Octal SPI NOR flash connected
to the OSPI interface, add support for the flash and describe
the partition information as per bootloader.
Signed-off-by: Vaishnav Achath <vaishnav.a@ti.com>
---
arch/arm64/boot/dts/ti/k3-j722s-evm.dts | 79 +++++++++++++++++++++++++
1 file changed, 79 insertions(+)
Comments
Hi Vaishnav On 2/16/2024 7:25 PM, Vaishnav Achath wrote: > J722S EVM has S28HS512T 64 MiB Octal SPI NOR flash connected > to the OSPI interface, add support for the flash and describe > the partition information as per bootloader. > > Signed-off-by: Vaishnav Achath <vaishnav.a@ti.com> > --- > arch/arm64/boot/dts/ti/k3-j722s-evm.dts | 79 +++++++++++++++++++++++++ > 1 file changed, 79 insertions(+) > > diff --git a/arch/arm64/boot/dts/ti/k3-j722s-evm.dts b/arch/arm64/boot/dts/ti/k3-j722s-evm.dts > index 9e12a6e9111f..b1c6499c0c9d 100644 > --- a/arch/arm64/boot/dts/ti/k3-j722s-evm.dts > +++ b/arch/arm64/boot/dts/ti/k3-j722s-evm.dts > @@ -169,6 +169,23 @@ J722S_IOPAD(0x015c, PIN_INPUT, 0) /* (AD25) MDIO0_MDIO */ > >; > }; > > + ospi0_pins_default: ospi0-default-pins { > + pinctrl-single,pins = < > + J722S_IOPAD(0x0000, PIN_OUTPUT, 0) /* (P23) OSPI0_CLK */ > + J722S_IOPAD(0x002c, PIN_OUTPUT, 0) /* (M25) OSPI0_CSn0 */ > + J722S_IOPAD(0x000c, PIN_INPUT, 0) /* (L25) OSPI0_D0 */ > + J722S_IOPAD(0x0010, PIN_INPUT, 0) /* (N24) OSPI0_D1 */ > + J722S_IOPAD(0x0014, PIN_INPUT, 0) /* (N25) OSPI0_D2 */ > + J722S_IOPAD(0x0018, PIN_INPUT, 0) /* (M24) OSPI0_D3 */ > + J722S_IOPAD(0x001c, PIN_INPUT, 0) /* (N21) OSPI0_D4 */ > + J722S_IOPAD(0x0020, PIN_INPUT, 0) /* (N22) OSPI0_D5 */ > + J722S_IOPAD(0x0024, PIN_INPUT, 0) /* (P21) OSPI0_D6 */ > + J722S_IOPAD(0x0028, PIN_INPUT, 0) /* (N20) OSPI0_D7 */ > + J722S_IOPAD(0x0008, PIN_INPUT, 0) /* (P22) OSPI0_DQS */ Could you check, Pin name in comments For example, Schematic says L22 is for OSPI0_DQS , but comments says P22 However offsets are good . > + >; > + bootph-all; > + }; > + > rgmii1_pins_default: rgmii1-default-pins { > pinctrl-single,pins = < > J722S_IOPAD(0x014c, PIN_INPUT, 0) /* (AC25) RGMII1_RD0 */ > @@ -290,6 +307,68 @@ exp1: gpio@23 { > }; > }; > > +&ospi0 { > + pinctrl-names = "default"; > + pinctrl-0 = <&ospi0_pins_default>; > + status = "okay"; > + > + flash@0 { > + compatible = "jedec,spi-nor"; > + reg = <0x0>; > + spi-tx-bus-width = <8>; > + spi-rx-bus-width = <8>; > + spi-max-frequency = <25000000>; > + cdns,tshsl-ns = <60>; > + cdns,tsd2d-ns = <60>; > + cdns,tchsh-ns = <60>; > + cdns,tslch-ns = <60>; > + cdns,read-delay = <4>; > + bootph-all; > + > + partitions { > + compatible = "fixed-partitions"; > + #address-cells = <1>; > + #size-cells = <1>; > + > + partition@0 { > + label = "ospi.tiboot3"; > + reg = <0x00 0x80000>; > + }; I suggest to keep 1MB to accommodate future size increase > + > + partition@80000 { > + label = "ospi.tispl"; > + reg = <0x80000 0x200000>; > + }; > + > + partition@280000 { > + label = "ospi.u-boot"; > + reg = <0x280000 0x400000>; > + }; > + > + partition@680000 { > + label = "ospi.env"; > + reg = <0x680000 0x40000>; > + }; > + > + partition@6c0000 { > + label = "ospi.env.backup"; > + reg = <0x6c0000 0x40000>; > + }; > + > + partition@800000 { > + label = "ospi.rootfs"; > + reg = <0x800000 0x37c0000>; > + }; > + > + partition@3fc0000 { > + label = "ospi.phypattern"; > + reg = <0x3fc0000 0x40000>; > + }; > + }; > + }; > + > +}; > + > &sdhci1 { > /* SD/MMC */ > vmmc-supply = <&vdd_mmc1>;
Hi Udit, On 19/02/24 11:25, Kumar, Udit wrote: > Hi Vaishnav > > On 2/16/2024 7:25 PM, Vaishnav Achath wrote: >> J722S EVM has S28HS512T 64 MiB Octal SPI NOR flash connected >> to the OSPI interface, add support for the flash and describe >> the partition information as per bootloader. >> >> Signed-off-by: Vaishnav Achath <vaishnav.a@ti.com> >> --- >> arch/arm64/boot/dts/ti/k3-j722s-evm.dts | 79 +++++++++++++++++++++++++ >> 1 file changed, 79 insertions(+) >> >> diff --git a/arch/arm64/boot/dts/ti/k3-j722s-evm.dts >> b/arch/arm64/boot/dts/ti/k3-j722s-evm.dts >> index 9e12a6e9111f..b1c6499c0c9d 100644 >> --- a/arch/arm64/boot/dts/ti/k3-j722s-evm.dts >> +++ b/arch/arm64/boot/dts/ti/k3-j722s-evm.dts >> @@ -169,6 +169,23 @@ J722S_IOPAD(0x015c, PIN_INPUT, 0) /* (AD25) >> MDIO0_MDIO */ >> >; >> }; >> + ospi0_pins_default: ospi0-default-pins { >> + pinctrl-single,pins = < >> + J722S_IOPAD(0x0000, PIN_OUTPUT, 0) /* (P23) OSPI0_CLK */ >> + J722S_IOPAD(0x002c, PIN_OUTPUT, 0) /* (M25) OSPI0_CSn0 */ >> + J722S_IOPAD(0x000c, PIN_INPUT, 0) /* (L25) OSPI0_D0 */ >> + J722S_IOPAD(0x0010, PIN_INPUT, 0) /* (N24) OSPI0_D1 */ >> + J722S_IOPAD(0x0014, PIN_INPUT, 0) /* (N25) OSPI0_D2 */ >> + J722S_IOPAD(0x0018, PIN_INPUT, 0) /* (M24) OSPI0_D3 */ >> + J722S_IOPAD(0x001c, PIN_INPUT, 0) /* (N21) OSPI0_D4 */ >> + J722S_IOPAD(0x0020, PIN_INPUT, 0) /* (N22) OSPI0_D5 */ >> + J722S_IOPAD(0x0024, PIN_INPUT, 0) /* (P21) OSPI0_D6 */ >> + J722S_IOPAD(0x0028, PIN_INPUT, 0) /* (N20) OSPI0_D7 */ >> + J722S_IOPAD(0x0008, PIN_INPUT, 0) /* (P22) OSPI0_DQS */ > > > Could you check, Pin name in comments > > For example, Schematic says L22 is for OSPI0_DQS , but comments says P22 > > However offsets are good . Thanks for the review, I will fix this in the next revision. > >> + >; >> + bootph-all; >> + }; >> + >> rgmii1_pins_default: rgmii1-default-pins { >> pinctrl-single,pins = < >> J722S_IOPAD(0x014c, PIN_INPUT, 0) /* (AC25) RGMII1_RD0 */ >> @@ -290,6 +307,68 @@ exp1: gpio@23 { >> }; >> }; >> +&ospi0 { >> + pinctrl-names = "default"; >> + pinctrl-0 = <&ospi0_pins_default>; >> + status = "okay"; >> + >> + flash@0 { >> + compatible = "jedec,spi-nor"; >> + reg = <0x0>; >> + spi-tx-bus-width = <8>; >> + spi-rx-bus-width = <8>; >> + spi-max-frequency = <25000000>; >> + cdns,tshsl-ns = <60>; >> + cdns,tsd2d-ns = <60>; >> + cdns,tchsh-ns = <60>; >> + cdns,tslch-ns = <60>; >> + cdns,read-delay = <4>; >> + bootph-all; >> + >> + partitions { >> + compatible = "fixed-partitions"; >> + #address-cells = <1>; >> + #size-cells = <1>; >> + >> + partition@0 { >> + label = "ospi.tiboot3"; >> + reg = <0x00 0x80000>; >> + }; > > > I suggest to keep 1MB to accommodate future size increase > For J722S, the maximum loadable SPL size is 0x7e000, images larger than these cannot be loaded by ROM, increasing the size here will not give any benefit, planning to keep as-is if there are no objections. Thanks and Regards, Vaishnav >> + >> + partition@80000 { >> + label = "ospi.tispl"; >> + reg = <0x80000 0x200000>; >> + }; >> + >> + partition@280000 { >> + label = "ospi.u-boot"; >> + reg = <0x280000 0x400000>; >> + }; >> + >> + partition@680000 { >> + label = "ospi.env"; >> + reg = <0x680000 0x40000>; >> + }; >> + >> + partition@6c0000 { >> + label = "ospi.env.backup"; >> + reg = <0x6c0000 0x40000>; >> + }; >> + >> + partition@800000 { >> + label = "ospi.rootfs"; >> + reg = <0x800000 0x37c0000>; >> + }; >> + >> + partition@3fc0000 { >> + label = "ospi.phypattern"; >> + reg = <0x3fc0000 0x40000>; >> + }; >> + }; >> + }; >> + >> +}; >> + >> &sdhci1 { >> /* SD/MMC */ >> vmmc-supply = <&vdd_mmc1>;
Hi Vaishnav On 2/19/2024 1:53 PM, Vaishnav Achath wrote: > Hi Udit, > > On 19/02/24 11:25, Kumar, Udit wrote: >> Hi Vaishnav >> >> On 2/16/2024 7:25 PM, Vaishnav Achath wrote: >>> J722S EVM has S28HS512T 64 MiB Octal SPI NOR flash connected >>> to the OSPI interface, add support for the flash and describe >>> the partition information as per bootloader. >>> >>> Signed-off-by: Vaishnav Achath <vaishnav.a@ti.com> >>> --- >>> arch/arm64/boot/dts/ti/k3-j722s-evm.dts | 79 >>> +++++++++++++++++++++++++ >>> 1 file changed, 79 insertions(+) >>> >>> diff --git a/arch/arm64/boot/dts/ti/k3-j722s-evm.dts >>> b/arch/arm64/boot/dts/ti/k3-j722s-evm.dts >>> index 9e12a6e9111f..b1c6499c0c9d 100644 >>> --- a/arch/arm64/boot/dts/ti/k3-j722s-evm.dts >>> +++ b/arch/arm64/boot/dts/ti/k3-j722s-evm.dts >>> @@ -169,6 +169,23 @@ J722S_IOPAD(0x015c, PIN_INPUT, 0) /* (AD25) >>> MDIO0_MDIO */ >>> >; >>> }; >>> + ospi0_pins_default: ospi0-default-pins { >>> + pinctrl-single,pins = < >>> + J722S_IOPAD(0x0000, PIN_OUTPUT, 0) /* (P23) OSPI0_CLK */ >>> + J722S_IOPAD(0x002c, PIN_OUTPUT, 0) /* (M25) OSPI0_CSn0 */ >>> + J722S_IOPAD(0x000c, PIN_INPUT, 0) /* (L25) OSPI0_D0 */ >>> + J722S_IOPAD(0x0010, PIN_INPUT, 0) /* (N24) OSPI0_D1 */ >>> + J722S_IOPAD(0x0014, PIN_INPUT, 0) /* (N25) OSPI0_D2 */ >>> + J722S_IOPAD(0x0018, PIN_INPUT, 0) /* (M24) OSPI0_D3 */ >>> + J722S_IOPAD(0x001c, PIN_INPUT, 0) /* (N21) OSPI0_D4 */ >>> + J722S_IOPAD(0x0020, PIN_INPUT, 0) /* (N22) OSPI0_D5 */ >>> + J722S_IOPAD(0x0024, PIN_INPUT, 0) /* (P21) OSPI0_D6 */ >>> + J722S_IOPAD(0x0028, PIN_INPUT, 0) /* (N20) OSPI0_D7 */ >>> + J722S_IOPAD(0x0008, PIN_INPUT, 0) /* (P22) OSPI0_DQS */ >> >> >> Could you check, Pin name in comments >> >> For example, Schematic says L22 is for OSPI0_DQS , but comments says P22 >> >> However offsets are good . > > Thanks for the review, I will fix this in the next revision. > >> >>> + >; >>> + bootph-all; >>> + }; >>> + >>> rgmii1_pins_default: rgmii1-default-pins { >>> pinctrl-single,pins = < >>> J722S_IOPAD(0x014c, PIN_INPUT, 0) /* (AC25) RGMII1_RD0 */ >>> @@ -290,6 +307,68 @@ exp1: gpio@23 { >>> }; >>> }; >>> +&ospi0 { >>> + pinctrl-names = "default"; >>> + pinctrl-0 = <&ospi0_pins_default>; >>> + status = "okay"; >>> + >>> + flash@0 { >>> + compatible = "jedec,spi-nor"; >>> + reg = <0x0>; >>> + spi-tx-bus-width = <8>; >>> + spi-rx-bus-width = <8>; >>> + spi-max-frequency = <25000000>; >>> + cdns,tshsl-ns = <60>; >>> + cdns,tsd2d-ns = <60>; >>> + cdns,tchsh-ns = <60>; >>> + cdns,tslch-ns = <60>; >>> + cdns,read-delay = <4>; >>> + bootph-all; >>> + >>> + partitions { >>> + compatible = "fixed-partitions"; >>> + #address-cells = <1>; >>> + #size-cells = <1>; >>> + >>> + partition@0 { >>> + label = "ospi.tiboot3"; >>> + reg = <0x00 0x80000>; >>> + }; >> >> >> I suggest to keep 1MB to accommodate future size increase >> > > For J722S, the maximum loadable SPL size is 0x7e000, images larger > than these cannot be loaded by ROM, increasing the size here will not > give any benefit, planning to keep as-is if there are no objections. > If ROM is limiting size here, then no need to increase this > Thanks and Regards, > Vaishnav > >>> + >>> + partition@80000 { >>> + label = "ospi.tispl"; >>> + reg = <0x80000 0x200000>; >>> + }; >>> + >>> + partition@280000 { >>> + label = "ospi.u-boot"; >>> + reg = <0x280000 0x400000>; >>> + }; >>> + >>> + partition@680000 { >>> + label = "ospi.env"; >>> + reg = <0x680000 0x40000>; >>> + }; >>> + >>> + partition@6c0000 { >>> + label = "ospi.env.backup"; >>> + reg = <0x6c0000 0x40000>; >>> + }; >>> + >>> + partition@800000 { >>> + label = "ospi.rootfs"; >>> + reg = <0x800000 0x37c0000>; >>> + }; >>> + >>> + partition@3fc0000 { >>> + label = "ospi.phypattern"; >>> + reg = <0x3fc0000 0x40000>; >>> + }; >>> + }; >>> + }; >>> + >>> +}; >>> + >>> &sdhci1 { >>> /* SD/MMC */ >>> vmmc-supply = <&vdd_mmc1>;
diff --git a/arch/arm64/boot/dts/ti/k3-j722s-evm.dts b/arch/arm64/boot/dts/ti/k3-j722s-evm.dts index 9e12a6e9111f..b1c6499c0c9d 100644 --- a/arch/arm64/boot/dts/ti/k3-j722s-evm.dts +++ b/arch/arm64/boot/dts/ti/k3-j722s-evm.dts @@ -169,6 +169,23 @@ J722S_IOPAD(0x015c, PIN_INPUT, 0) /* (AD25) MDIO0_MDIO */ >; }; + ospi0_pins_default: ospi0-default-pins { + pinctrl-single,pins = < + J722S_IOPAD(0x0000, PIN_OUTPUT, 0) /* (P23) OSPI0_CLK */ + J722S_IOPAD(0x002c, PIN_OUTPUT, 0) /* (M25) OSPI0_CSn0 */ + J722S_IOPAD(0x000c, PIN_INPUT, 0) /* (L25) OSPI0_D0 */ + J722S_IOPAD(0x0010, PIN_INPUT, 0) /* (N24) OSPI0_D1 */ + J722S_IOPAD(0x0014, PIN_INPUT, 0) /* (N25) OSPI0_D2 */ + J722S_IOPAD(0x0018, PIN_INPUT, 0) /* (M24) OSPI0_D3 */ + J722S_IOPAD(0x001c, PIN_INPUT, 0) /* (N21) OSPI0_D4 */ + J722S_IOPAD(0x0020, PIN_INPUT, 0) /* (N22) OSPI0_D5 */ + J722S_IOPAD(0x0024, PIN_INPUT, 0) /* (P21) OSPI0_D6 */ + J722S_IOPAD(0x0028, PIN_INPUT, 0) /* (N20) OSPI0_D7 */ + J722S_IOPAD(0x0008, PIN_INPUT, 0) /* (P22) OSPI0_DQS */ + >; + bootph-all; + }; + rgmii1_pins_default: rgmii1-default-pins { pinctrl-single,pins = < J722S_IOPAD(0x014c, PIN_INPUT, 0) /* (AC25) RGMII1_RD0 */ @@ -290,6 +307,68 @@ exp1: gpio@23 { }; }; +&ospi0 { + pinctrl-names = "default"; + pinctrl-0 = <&ospi0_pins_default>; + status = "okay"; + + flash@0 { + compatible = "jedec,spi-nor"; + reg = <0x0>; + spi-tx-bus-width = <8>; + spi-rx-bus-width = <8>; + spi-max-frequency = <25000000>; + cdns,tshsl-ns = <60>; + cdns,tsd2d-ns = <60>; + cdns,tchsh-ns = <60>; + cdns,tslch-ns = <60>; + cdns,read-delay = <4>; + bootph-all; + + partitions { + compatible = "fixed-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + partition@0 { + label = "ospi.tiboot3"; + reg = <0x00 0x80000>; + }; + + partition@80000 { + label = "ospi.tispl"; + reg = <0x80000 0x200000>; + }; + + partition@280000 { + label = "ospi.u-boot"; + reg = <0x280000 0x400000>; + }; + + partition@680000 { + label = "ospi.env"; + reg = <0x680000 0x40000>; + }; + + partition@6c0000 { + label = "ospi.env.backup"; + reg = <0x6c0000 0x40000>; + }; + + partition@800000 { + label = "ospi.rootfs"; + reg = <0x800000 0x37c0000>; + }; + + partition@3fc0000 { + label = "ospi.phypattern"; + reg = <0x3fc0000 0x40000>; + }; + }; + }; + +}; + &sdhci1 { /* SD/MMC */ vmmc-supply = <&vdd_mmc1>;