linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 2/2] powerpc/fsl-booke: Add initial T1042RDB_PI board support
@ 2014-07-09  4:24 Priyanka Jain
  2014-07-30 20:12 ` [2/2] " Scott Wood
  0 siblings, 1 reply; 4+ messages in thread
From: Priyanka Jain @ 2014-07-09  4:24 UTC (permalink / raw)
  To: scottwood, devicetree, linuxppc-dev
  Cc: Priyanka Jain, Poonam Aggrwal, Prabhakar Kushwaha

T1042RDB_PI is Freescale Reference Design Board supporting the T1042
QorIQ Power Architecture™ processor. T1042 is a reduced personality
of T1040 SoC without Integrated 8-port Gigabit. The board is designed
with low power features targeted for Printing Image Market.

T1042RDB_PI is  similar to T1040RDB board with few differences like
it has video interface, supports T1042 personality only

T1042RDB_PI board Overview
-----------------------
- SERDES Connections, 8 lanes supporting:
    	- PCI
    	- SATA 2.0
- DDR Controller
    	- Supports rates of up to 1600 MHz data-rate
    	- Supports one DDR3LP UDIMM
-IFC/Local Bus
    	- NAND flash: 1GB 8-bit NAND flash
    	- NOR: 128MB 16-bit NOR Flash
- Ethernet
    	- Two on-board RGMII 10/100/1G ethernet ports.
    	- PHY #0 remains powered up during deep-sleep
- CPLD
- Clocks
    	- System and DDR clock (SYSCLK, “DDRCLK”)
    	- SERDES clocks
- Power Supplies
- USB
    	- Supports two USB 2.0 ports with integrated PHYs
    	- Two type A ports with 5V@1.5A per port.
- SDHC
    	- SDHC/SDXC connector
- SPI
    	- On-board 64MB SPI flash
- I2C
    	- Device connected: EEPROM, thermal monitor, VID controller, RTC
- Other IO
    	- Two Serial ports
    	- ProfiBus port

Add support for T1042RDB_PI board:
    -add device tree
    -Add entry in corenet_generic.c, as it is similar to other corenet platforms

Signed-off-by: Poonam Aggrwal <poonam.aggrwal@freescale.com>
Signed-off-by: Prabhakar Kushwaha <prabhakar@freescale.com>
Signed-off-by: Priyanka Jain <Priyanka.Jain@freescale.com>
---
 arch/powerpc/boot/dts/t1042rdb_pi.dts         |   52 +++++++++++++++++++++++++
 arch/powerpc/boot/dts/t104xrdb.dtsi           |    3 +-
 arch/powerpc/platforms/85xx/corenet_generic.c |    1 +
 3 files changed, 55 insertions(+), 1 deletions(-)
 create mode 100644 arch/powerpc/boot/dts/t1042rdb_pi.dts

diff --git a/arch/powerpc/boot/dts/t1042rdb_pi.dts b/arch/powerpc/boot/dts/t1042rdb_pi.dts
new file mode 100644
index 0000000..f5293a9
--- /dev/null
+++ b/arch/powerpc/boot/dts/t1042rdb_pi.dts
@@ -0,0 +1,52 @@
+/*
+ * T1042RDB_PI Device Tree Source
+ *
+ * Copyright 2014 Freescale Semiconductor Inc.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *     * Redistributions of source code must retain the above copyright
+ *	 notice, this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *	 notice, this list of conditions and the following disclaimer in the
+ *	 documentation and/or other materials provided with the distribution.
+ *     * Neither the name of Freescale Semiconductor nor the
+ *	 names of its contributors may be used to endorse or promote products
+ *	 derived from this software without specific prior written permission.
+ *
+ *
+ * ALTERNATIVELY, this software may be distributed under the terms of the
+ * GNU General Public License ("GPL") as published by the Free Software
+ * Foundation, either version 2 of that License or (at your option) any
+ * later version.
+ *
+ * THIS SOFTWARE IS PROVIDED BY Freescale Semiconductor "AS IS" AND ANY
+ * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL Freescale Semiconductor BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/include/ "fsl/t104xsi-pre.dtsi"
+/include/ "t104xrdb.dtsi"
+
+/ {
+	model = "fsl,T1042RDB_PI";
+	compatible = "fsl,T1042RDB_PI";
+	soc: soc@ffe000000 {
+		i2c@118000 {
+			rtc@68 {
+				compatible = "dallas,ds1337";
+				reg = <0x68>;
+				interrupts = <0x2 0x1 0 0>;
+			};
+		};
+	};
+};
+
+/include/ "fsl/t1042si-post.dtsi"
diff --git a/arch/powerpc/boot/dts/t104xrdb.dtsi b/arch/powerpc/boot/dts/t104xrdb.dtsi
index 9aaefa5..e7e765f 100644
--- a/arch/powerpc/boot/dts/t104xrdb.dtsi
+++ b/arch/powerpc/boot/dts/t104xrdb.dtsi
@@ -57,7 +57,8 @@
 		};
 
 		cpld@3,0 {
-			compatible = "fsl,t1040rdb-cpld","fsl,t1042rdb-cpld";
+			compatible = "fsl,t1040rdb-cpld","fsl,t1042rdb-cpld",
+					"fsl,t1042rdb_pi-cpld";
 			reg = <3 0 0x300>;
 		};
 	};
diff --git a/arch/powerpc/platforms/85xx/corenet_generic.c b/arch/powerpc/platforms/85xx/corenet_generic.c
index c268f89..100e80d 100644
--- a/arch/powerpc/platforms/85xx/corenet_generic.c
+++ b/arch/powerpc/platforms/85xx/corenet_generic.c
@@ -130,6 +130,7 @@ static const char * const boards[] __initconst = {
 	"fsl,T1042QDS",
 	"fsl,T1040RDB",
 	"fsl,T1042RDB",
+	"fsl,T1042RDB_PI",
 	"keymile,kmcoge4",
 	NULL
 };
-- 
1.7.4.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [2/2] powerpc/fsl-booke: Add initial T1042RDB_PI board support
  2014-07-09  4:24 [PATCH 2/2] powerpc/fsl-booke: Add initial T1042RDB_PI board support Priyanka Jain
@ 2014-07-30 20:12 ` Scott Wood
  2014-07-31  4:37   ` Priyanka Jain
  0 siblings, 1 reply; 4+ messages in thread
From: Scott Wood @ 2014-07-30 20:12 UTC (permalink / raw)
  To: Priyanka Jain
  Cc: devicetree, linuxppc-dev, Prabhakar Kushwaha, Poonam Aggrwal

On Wed, Jul 09, 2014 at 09:54:11AM +0530, Priyanka Jain wrote:
> diff --git a/arch/powerpc/boot/dts/t104xrdb.dtsi b/arch/powerpc/boot/dts/t104xrdb.dtsi
> index 9aaefa5..e7e765f 100644
> --- a/arch/powerpc/boot/dts/t104xrdb.dtsi
> +++ b/arch/powerpc/boot/dts/t104xrdb.dtsi
> @@ -57,7 +57,8 @@
>  		};
>  
>  		cpld@3,0 {
> -			compatible = "fsl,t1040rdb-cpld","fsl,t1042rdb-cpld";
> +			compatible = "fsl,t1040rdb-cpld","fsl,t1042rdb-cpld",
> +					"fsl,t1042rdb_pi-cpld";
>  			reg = <3 0 0x300>;
>  		};
>  	};

What's going on here?  This file is used by all three boards.  If you
need to distinguish one board's CPLD from another's, you'll have to do it
somewhere else.  If the CPLDs are exactly the same and no distinction
needs to be made, then you don't need three compatible strings.  Even
then, you may wish to specify the exact board as the first compatible
string, but again you'll need to patch that in elsewhere so that it
actually matches the board.

-Scott

^ permalink raw reply	[flat|nested] 4+ messages in thread

* RE: [2/2] powerpc/fsl-booke: Add initial T1042RDB_PI board support
  2014-07-30 20:12 ` [2/2] " Scott Wood
@ 2014-07-31  4:37   ` Priyanka Jain
  2014-07-31  5:07     ` Scott Wood
  0 siblings, 1 reply; 4+ messages in thread
From: Priyanka Jain @ 2014-07-31  4:37 UTC (permalink / raw)
  To: Scott Wood
  Cc: devicetree@vger.kernel.org, linuxppc-dev@lists.ozlabs.org,
	prabhakar@freescale.com, Poonam.Aggrwal@freescale.com



-----Original Message-----
From: Wood Scott-B07421=20
Sent: Thursday, July 31, 2014 1:43 AM
To: Jain Priyanka-B32167
Cc: devicetree@vger.kernel.org; linuxppc-dev@lists.ozlabs.org; Aggrwal Poon=
am-B10812; Kushwaha Prabhakar-B32579
Subject: Re: [2/2] powerpc/fsl-booke: Add initial T1042RDB_PI board support

On Wed, Jul 09, 2014 at 09:54:11AM +0530, Priyanka Jain wrote:
> diff --git a/arch/powerpc/boot/dts/t104xrdb.dtsi=20
> b/arch/powerpc/boot/dts/t104xrdb.dtsi
> index 9aaefa5..e7e765f 100644
> --- a/arch/powerpc/boot/dts/t104xrdb.dtsi
> +++ b/arch/powerpc/boot/dts/t104xrdb.dtsi
> @@ -57,7 +57,8 @@
>  		};
> =20
>  		cpld@3,0 {
> -			compatible =3D "fsl,t1040rdb-cpld","fsl,t1042rdb-cpld";
> +			compatible =3D "fsl,t1040rdb-cpld","fsl,t1042rdb-cpld",
> +					"fsl,t1042rdb_pi-cpld";
>  			reg =3D <3 0 0x300>;
>  		};
>  	};

What's going on here?  This file is used by all three boards.  If you need =
to distinguish one board's CPLD from another's, you'll have to do it somewh=
ere else.  If the CPLDs are exactly the same and no distinction needs to be=
 made, then you don't need three compatible strings.  Even then, you may wi=
sh to specify the exact board as the first compatible string, but again you=
'll need to patch that in elsewhere so that it actually matches the board
.
As the register set of CPLD for all three boards is same, I am thinking of =
replacing this with t104srdb-cpld
compatible =3D "fsl,t104xrdb-cpld","
Is this OK?

-Scott

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [2/2] powerpc/fsl-booke: Add initial T1042RDB_PI board support
  2014-07-31  4:37   ` Priyanka Jain
@ 2014-07-31  5:07     ` Scott Wood
  0 siblings, 0 replies; 4+ messages in thread
From: Scott Wood @ 2014-07-31  5:07 UTC (permalink / raw)
  To: Jain Priyanka-B32167
  Cc: devicetree@vger.kernel.org, linuxppc-dev@lists.ozlabs.org,
	Kushwaha Prabhakar-B32579, Aggrwal Poonam-B10812

On Wed, 2014-07-30 at 23:37 -0500, Jain Priyanka-B32167 wrote:
> 
> -----Original Message-----
> From: Wood Scott-B07421 
> Sent: Thursday, July 31, 2014 1:43 AM
> To: Jain Priyanka-B32167
> Cc: devicetree@vger.kernel.org; linuxppc-dev@lists.ozlabs.org; Aggrwal Poonam-B10812; Kushwaha Prabhakar-B32579
> Subject: Re: [2/2] powerpc/fsl-booke: Add initial T1042RDB_PI board support
> 
> On Wed, Jul 09, 2014 at 09:54:11AM +0530, Priyanka Jain wrote:
> > diff --git a/arch/powerpc/boot/dts/t104xrdb.dtsi 
> > b/arch/powerpc/boot/dts/t104xrdb.dtsi
> > index 9aaefa5..e7e765f 100644
> > --- a/arch/powerpc/boot/dts/t104xrdb.dtsi
> > +++ b/arch/powerpc/boot/dts/t104xrdb.dtsi
> > @@ -57,7 +57,8 @@
> >  		};
> >  
> >  		cpld@3,0 {
> > -			compatible = "fsl,t1040rdb-cpld","fsl,t1042rdb-cpld";
> > +			compatible = "fsl,t1040rdb-cpld","fsl,t1042rdb-cpld",
> > +					"fsl,t1042rdb_pi-cpld";
> >  			reg = <3 0 0x300>;
> >  		};
> >  	};
> 
> What's going on here?  This file is used by all three boards.  If you need to distinguish one board's CPLD from another's, you'll have to do it somewhere else.  If the CPLDs are exactly the same and no distinction needs to be made, then you don't need three compatible strings.  Even then, you may wish to specify the exact board as the first compatible string, but again you'll need to patch that in elsewhere so that it actually matches the board
> .
> As the register set of CPLD for all three boards is same, I am thinking of replacing this with t104srdb-cpld
> compatible = "fsl,t104xrdb-cpld","
> Is this OK?

No.  Wildcards aren't allowed in compatible strings, because you never
know what other devices might exist in the future that match the
wildcard.

If the CPLD logic is truly 100% identical, just pick one of the three to
be the canonical name.

-Scott

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-07-31  5:07 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-09  4:24 [PATCH 2/2] powerpc/fsl-booke: Add initial T1042RDB_PI board support Priyanka Jain
2014-07-30 20:12 ` [2/2] " Scott Wood
2014-07-31  4:37   ` Priyanka Jain
2014-07-31  5:07     ` Scott Wood

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).