devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/8] ARM: OMAP: SATA support for OMAP5 & DRA7
@ 2014-03-07 10:15 Roger Quadros
  2014-03-07 10:15 ` [PATCH v3 1/8] phy: omap-control: update dra7 and am437 usb2 Documentation bindings Roger Quadros
                   ` (7 more replies)
  0 siblings, 8 replies; 12+ messages in thread
From: Roger Quadros @ 2014-03-07 10:15 UTC (permalink / raw)
  To: balbi-l0cyMroinI0, tony-4v6yS6AI5VpBDgjK7y7TUQ
  Cc: kishon-l0cyMroinI0, george.cherian-l0cyMroinI0,
	balajitk-l0cyMroinI0, hdegoede-H+wXaHxf7aLQT0dZR+AlfA,
	linux-omap-u79uwXL29TY76Z2rM5mHXA,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-usb-u79uwXL29TY76Z2rM5mHXA, rogerq-l0cyMroinI0

Hi Tony & Felipe,

Kishon has pulled in the relevant PHY patches into his tree.
These are the remaining patches from the series.

Patches 1 to 3 need to go through Felipe's USB tree.
Patches 4 to 8 need to go through Tony's OMAP tree.

Thanks.

Patches are based on 3.14-rc4 with balbi/next, linux-phy/next and
omap-for-v3.15/dt merged on top.

To test SATA you will also need [1].

[1] - http://article.gmane.org/gmane.comp.hardware.netbook.arm.sunxi/7285

Changelog:
v3
- Removed PHY patches and rebased.

v2
- use 'depends on' instead of 'select' OCP2SCP bus driver.
- Changed DT bindings for dra7-usb2 and am437-usb2 phy.

cheers,
-roger

---
Balaji T K (2):
  ARM: dts: omap5: add sata node
  ARM: dts: dra7: add OCP2SCP3 and SATA nodes

Keshava Munegowda (1):
  ARM: OMAP5: hwmod: Add ocp2scp3 and sata hwmods

Nikhil Devshatwar (1):
  ARM: DRA7: hwmod: Add ocp2scp3 and sata hwmods

Roger Quadros (4):
  phy: omap-control: update dra7 and am437 usb2 Documentation bindings
  phy: ti-pipe3: Add clocks to PIPE3 PHY Documentation binding
  phy: ti-pipe3: Add SATA compatible to Documentation binding
  ARM: dts: omap5: Add clocks to USB3 PHY node

 Documentation/devicetree/bindings/phy/ti-phy.txt | 19 +++++-
 arch/arm/boot/dts/dra7.dtsi                      | 39 +++++++++++++
 arch/arm/boot/dts/omap5.dtsi                     | 46 +++++++++++++++
 arch/arm/mach-omap2/omap_hwmod_54xx_data.c       | 73 ++++++++++++++++++++++++
 arch/arm/mach-omap2/omap_hwmod_7xx_data.c        | 31 ++++++++--
 5 files changed, 200 insertions(+), 8 deletions(-)

-- 
1.8.3.2

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* [PATCH v3 1/8] phy: omap-control: update dra7 and am437 usb2 Documentation bindings
  2014-03-07 10:15 [PATCH v3 0/8] ARM: OMAP: SATA support for OMAP5 & DRA7 Roger Quadros
@ 2014-03-07 10:15 ` Roger Quadros
  2014-03-07 10:15 ` [PATCH v3 2/8] phy: ti-pipe3: Add clocks to PIPE3 PHY Documentation binding Roger Quadros
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Roger Quadros @ 2014-03-07 10:15 UTC (permalink / raw)
  To: balbi, tony
  Cc: devicetree, george.cherian, balajitk, linux-usb, linux-kernel,
	kishon, hdegoede, linux-omap, linux-arm-kernel, rogerq

The dra7-usb2 and am437-usb2 bindings have not yet been used.
Change them to be more elegant.

Acked-by: Kishon Vijay Abraham I <kishon@ti.com>
Signed-off-by: Roger Quadros <rogerq@ti.com>
---
 Documentation/devicetree/bindings/phy/ti-phy.txt | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/phy/ti-phy.txt b/Documentation/devicetree/bindings/phy/ti-phy.txt
index 5c5b1b0..073a623 100644
--- a/Documentation/devicetree/bindings/phy/ti-phy.txt
+++ b/Documentation/devicetree/bindings/phy/ti-phy.txt
@@ -9,9 +9,9 @@ Required properties:
                         e.g. USB2_PHY on OMAP5.
  "ti,control-phy-pipe3" - if it has DPLL and individual Rx & Tx power control
                         e.g. USB3 PHY and SATA PHY on OMAP5.
- "ti,control-phy-dra7usb2" - if it has power down register like USB2 PHY on
+ "ti,control-phy-usb2-dra7" - if it has power down register like USB2 PHY on
                         DRA7 platform.
- "ti,control-phy-am437usb2" - if it has power down register like USB2 PHY on
+ "ti,control-phy-usb2-am437" - if it has power down register like USB2 PHY on
                         AM437 platform.
  - reg : Address and length of the register set for the device. It contains
    the address of "otghs_control" for control-phy-otghs or "power" register
-- 
1.8.3.2

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

* [PATCH v3 2/8] phy: ti-pipe3: Add clocks to PIPE3 PHY Documentation binding
  2014-03-07 10:15 [PATCH v3 0/8] ARM: OMAP: SATA support for OMAP5 & DRA7 Roger Quadros
  2014-03-07 10:15 ` [PATCH v3 1/8] phy: omap-control: update dra7 and am437 usb2 Documentation bindings Roger Quadros
@ 2014-03-07 10:15 ` Roger Quadros
  2014-03-07 10:15 ` [PATCH v3 3/8] phy: ti-pipe3: Add SATA compatible to " Roger Quadros
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Roger Quadros @ 2014-03-07 10:15 UTC (permalink / raw)
  To: balbi, tony
  Cc: devicetree, george.cherian, balajitk, linux-usb, linux-kernel,
	kishon, hdegoede, linux-omap, linux-arm-kernel, rogerq

Add wakeup, system and reference clocks to DT binding documentation.

Acked-by: Kishon Vijay Abraham I <kishon@ti.com>
Signed-off-by: Roger Quadros <rogerq@ti.com>
---
 Documentation/devicetree/bindings/phy/ti-phy.txt | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/Documentation/devicetree/bindings/phy/ti-phy.txt b/Documentation/devicetree/bindings/phy/ti-phy.txt
index 073a623..96ba29e 100644
--- a/Documentation/devicetree/bindings/phy/ti-phy.txt
+++ b/Documentation/devicetree/bindings/phy/ti-phy.txt
@@ -59,6 +59,12 @@ Required properties:
    filled in "reg".
  - #phy-cells: determine the number of cells that should be given in the
    phandle while referencing this phy.
+ - clocks: a list of phandles and clock-specifier pairs, one for each entry in
+   clock-names.
+ - clock-names: should include:
+   * "wkupclk" - wakeup clock.
+   * "sysclk" - system clock.
+   * "refclk" - reference clock.
 
 Optional properties:
  - ctrl-module : phandle of the control module used by PHY driver to power on
@@ -74,4 +80,10 @@ usb3phy@4a084400 {
 	reg-names = "phy_rx", "phy_tx", "pll_ctrl";
 	ctrl-module = <&omap_control_usb>;
 	#phy-cells = <0>;
+	clocks = <&usb_phy_cm_clk32k>,
+		 <&sys_clkin>,
+		 <&usb_otg_ss_refclk960m>;
+	clock-names =	"wkupclk",
+			"sysclk",
+			"refclk";
 };
-- 
1.8.3.2

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

* [PATCH v3 3/8] phy: ti-pipe3: Add SATA compatible to Documentation binding
  2014-03-07 10:15 [PATCH v3 0/8] ARM: OMAP: SATA support for OMAP5 & DRA7 Roger Quadros
  2014-03-07 10:15 ` [PATCH v3 1/8] phy: omap-control: update dra7 and am437 usb2 Documentation bindings Roger Quadros
  2014-03-07 10:15 ` [PATCH v3 2/8] phy: ti-pipe3: Add clocks to PIPE3 PHY Documentation binding Roger Quadros
@ 2014-03-07 10:15 ` Roger Quadros
  2014-03-07 10:15 ` [PATCH v3 4/8] ARM: dts: omap5: Add clocks to USB3 PHY node Roger Quadros
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Roger Quadros @ 2014-03-07 10:15 UTC (permalink / raw)
  To: balbi, tony
  Cc: kishon, george.cherian, balajitk, hdegoede, linux-omap,
	linux-arm-kernel, linux-kernel, devicetree, linux-usb, rogerq

SATA PHY needs a new compatible ID. Add it to the DT binding documentation.

Acked-by: Kishon Vijay Abraham I <kishon@ti.com>
Signed-off-by: Roger Quadros <rogerq@ti.com>
---
 Documentation/devicetree/bindings/phy/ti-phy.txt | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/phy/ti-phy.txt b/Documentation/devicetree/bindings/phy/ti-phy.txt
index 96ba29e..4ab9cb1 100644
--- a/Documentation/devicetree/bindings/phy/ti-phy.txt
+++ b/Documentation/devicetree/bindings/phy/ti-phy.txt
@@ -53,7 +53,8 @@ usb2phy@4a0ad080 {
 TI PIPE3 PHY
 
 Required properties:
- - compatible: Should be "ti,phy-usb3". "ti,omap-usb3" is deprecated.
+ - compatible: Should be "ti,phy-usb3" or "ti,phy-pipe3-sata".
+   "ti,omap-usb3" is deprecated.
  - reg : Address and length of the register set for the device.
  - reg-names: The names of the register addresses corresponding to the registers
    filled in "reg".
-- 
1.8.3.2

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

* [PATCH v3 4/8] ARM: dts: omap5: Add clocks to USB3 PHY node
  2014-03-07 10:15 [PATCH v3 0/8] ARM: OMAP: SATA support for OMAP5 & DRA7 Roger Quadros
                   ` (2 preceding siblings ...)
  2014-03-07 10:15 ` [PATCH v3 3/8] phy: ti-pipe3: Add SATA compatible to " Roger Quadros
@ 2014-03-07 10:15 ` Roger Quadros
  2014-03-07 10:15 ` [PATCH v3 5/8] ARM: OMAP5: hwmod: Add ocp2scp3 and sata hwmods Roger Quadros
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Roger Quadros @ 2014-03-07 10:15 UTC (permalink / raw)
  To: balbi, tony
  Cc: devicetree, george.cherian, balajitk, linux-usb, linux-kernel,
	kishon, hdegoede, linux-omap, linux-arm-kernel, rogerq

The USB3 PHY driver now expects named clocks. Add the
relevant clocks to the USB3 PHY node.

Signed-off-by: Roger Quadros <rogerq@ti.com>
---
 arch/arm/boot/dts/omap5.dtsi | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/arch/arm/boot/dts/omap5.dtsi b/arch/arm/boot/dts/omap5.dtsi
index 859a800..88bd327 100644
--- a/arch/arm/boot/dts/omap5.dtsi
+++ b/arch/arm/boot/dts/omap5.dtsi
@@ -779,6 +779,12 @@
 				      <0x4a084c00 0x40>;
 				reg-names = "phy_rx", "phy_tx", "pll_ctrl";
 				ctrl-module = <&omap_control_usb3phy>;
+				clocks = <&usb_phy_cm_clk32k>,
+					 <&sys_clkin>,
+					 <&usb_otg_ss_refclk960m>;
+				clock-names =	"wkupclk",
+						"sysclk",
+						"refclk";
 				#phy-cells = <0>;
 			};
 		};
-- 
1.8.3.2

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

* [PATCH v3 5/8] ARM: OMAP5: hwmod: Add ocp2scp3 and sata hwmods
  2014-03-07 10:15 [PATCH v3 0/8] ARM: OMAP: SATA support for OMAP5 & DRA7 Roger Quadros
                   ` (3 preceding siblings ...)
  2014-03-07 10:15 ` [PATCH v3 4/8] ARM: dts: omap5: Add clocks to USB3 PHY node Roger Quadros
@ 2014-03-07 10:15 ` Roger Quadros
       [not found]   ` <1394187308-19622-6-git-send-email-rogerq-l0cyMroinI0@public.gmane.org>
  2014-03-07 10:15 ` [PATCH v3 6/8] ARM: dts: omap5: add sata node Roger Quadros
                   ` (2 subsequent siblings)
  7 siblings, 1 reply; 12+ messages in thread
From: Roger Quadros @ 2014-03-07 10:15 UTC (permalink / raw)
  To: balbi, tony
  Cc: kishon, george.cherian, balajitk, hdegoede, linux-omap,
	linux-arm-kernel, linux-kernel, devicetree, linux-usb, rogerq,
	Benoit Cousson, Paul Walmsley

From: Keshava Munegowda <keshava_mgowda@ti.com>

Create hwmods for ocp2scp3 and sata modules.

[Roger Q] Clean up.

CC: Benoit Cousson <bcousson@baylibre.com>
CC: Paul Walmsley <paul@pwsan.com>
CC: Tony Lindgren <tony@atomide.com>
Signed-off-by: Balaji T K <balajitk@ti.com>
Signed-off-by: Roger Quadros <rogerq@ti.com>
---
 arch/arm/mach-omap2/omap_hwmod_54xx_data.c | 73 ++++++++++++++++++++++++++++++
 1 file changed, 73 insertions(+)

diff --git a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
index e297d62..227a69f 100644
--- a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
@@ -1726,6 +1726,77 @@ static struct omap_hwmod omap54xx_wd_timer2_hwmod = {
 	},
 };
 
+/*
+ * 'ocp2scp' class
+ * bridge to transform ocp interface protocol to scp (serial control port)
+ * protocol
+ */
+/* ocp2scp3 */
+static struct omap_hwmod omap54xx_ocp2scp3_hwmod;
+/* l4_cfg -> ocp2scp3 */
+static struct omap_hwmod_ocp_if omap54xx_l4_cfg__ocp2scp3 = {
+	.master		= &omap54xx_l4_cfg_hwmod,
+	.slave		= &omap54xx_ocp2scp3_hwmod,
+	.clk		= "l4_root_clk_div",
+	.user		= OCP_USER_MPU | OCP_USER_SDMA,
+};
+
+static struct omap_hwmod omap54xx_ocp2scp3_hwmod = {
+	.name		= "ocp2scp3",
+	.class		= &omap54xx_ocp2scp_hwmod_class,
+	.clkdm_name	= "l3init_clkdm",
+	.prcm = {
+		.omap4 = {
+			.clkctrl_offs = OMAP54XX_CM_L3INIT_OCP2SCP3_CLKCTRL_OFFSET,
+			.context_offs = OMAP54XX_RM_L3INIT_OCP2SCP3_CONTEXT_OFFSET,
+			.modulemode   = MODULEMODE_HWCTRL,
+		},
+	},
+};
+
+/*
+ * 'sata' class
+ * sata:  serial ata interface  gen2 compliant   ( 1 rx/ 1 tx)
+ */
+
+static struct omap_hwmod_class_sysconfig omap54xx_sata_sysc = {
+	.sysc_offs	= 0x0000,
+	.sysc_flags	= (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
+	.idlemodes	= (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
+			   SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
+			   MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
+	.sysc_fields	= &omap_hwmod_sysc_type2,
+};
+
+static struct omap_hwmod_class omap54xx_sata_hwmod_class = {
+	.name	= "sata",
+	.sysc	= &omap54xx_sata_sysc,
+};
+
+/* sata */
+static struct omap_hwmod omap54xx_sata_hwmod = {
+	.name		= "sata",
+	.class		= &omap54xx_sata_hwmod_class,
+	.clkdm_name	= "l3init_clkdm",
+	.flags		= HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
+	.main_clk	= "func_48m_fclk",
+	.mpu_rt_idx	= 1,
+	.prcm = {
+		.omap4 = {
+			.clkctrl_offs = OMAP54XX_CM_L3INIT_SATA_CLKCTRL_OFFSET,
+			.context_offs = OMAP54XX_RM_L3INIT_SATA_CONTEXT_OFFSET,
+			.modulemode   = MODULEMODE_SWCTRL,
+		},
+	},
+};
+
+/* l4_cfg -> sata */
+static struct omap_hwmod_ocp_if omap54xx_l4_cfg__sata = {
+	.master		= &omap54xx_l4_cfg_hwmod,
+	.slave		= &omap54xx_sata_hwmod,
+	.clk		= "l3_iclk_div",
+	.user		= OCP_USER_MPU | OCP_USER_SDMA,
+};
 
 /*
  * Interfaces
@@ -2399,6 +2470,8 @@ static struct omap_hwmod_ocp_if *omap54xx_hwmod_ocp_ifs[] __initdata = {
 	&omap54xx_l4_cfg__usb_tll_hs,
 	&omap54xx_l4_cfg__usb_otg_ss,
 	&omap54xx_l4_wkup__wd_timer2,
+	&omap54xx_l4_cfg__ocp2scp3,
+	&omap54xx_l4_cfg__sata,
 	NULL,
 };
 
-- 
1.8.3.2

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

* [PATCH v3 6/8] ARM: dts: omap5: add sata node
  2014-03-07 10:15 [PATCH v3 0/8] ARM: OMAP: SATA support for OMAP5 & DRA7 Roger Quadros
                   ` (4 preceding siblings ...)
  2014-03-07 10:15 ` [PATCH v3 5/8] ARM: OMAP5: hwmod: Add ocp2scp3 and sata hwmods Roger Quadros
@ 2014-03-07 10:15 ` Roger Quadros
  2014-03-07 10:15 ` [PATCH v3 7/8] ARM: DRA7: hwmod: Add ocp2scp3 and sata hwmods Roger Quadros
  2014-03-07 10:15 ` [PATCH v3 8/8] ARM: dts: dra7: add OCP2SCP3 and SATA nodes Roger Quadros
  7 siblings, 0 replies; 12+ messages in thread
From: Roger Quadros @ 2014-03-07 10:15 UTC (permalink / raw)
  To: balbi, tony
  Cc: kishon, george.cherian, balajitk, hdegoede, linux-omap,
	linux-arm-kernel, linux-kernel, devicetree, linux-usb, rogerq,
	Benoit Cousson

From: Balaji T K <balajitk@ti.com>

Add support for sata.

[Roger Q] Clean up.

CC: Benoit Cousson <bcousson@baylibre.com>
CC: Tony Lindgren <tony@atomide.com>
Signed-off-by: Balaji T K <balajitk@ti.com>
Signed-off-by: Roger Quadros <rogerq@ti.com>
---
 arch/arm/boot/dts/omap5.dtsi | 40 ++++++++++++++++++++++++++++++++++++++++
 1 file changed, 40 insertions(+)

diff --git a/arch/arm/boot/dts/omap5.dtsi b/arch/arm/boot/dts/omap5.dtsi
index 88bd327..521caab 100644
--- a/arch/arm/boot/dts/omap5.dtsi
+++ b/arch/arm/boot/dts/omap5.dtsi
@@ -829,6 +829,46 @@
 
 			#thermal-sensor-cells = <1>;
 		};
+
+		omap_control_sata: control-phy@4a002374 {
+			compatible = "ti,control-phy-pipe3";
+			reg = <0x4a002374 0x4>;
+			reg-names = "power";
+			clocks = <&sys_clkin>;
+			clock-names = "sysclk";
+		};
+
+		/* OCP2SCP3 */
+		ocp2scp@4a090000 {
+			compatible = "ti,omap-ocp2scp";
+			#address-cells = <1>;
+			#size-cells = <1>;
+			reg = <0x4a090000 0x20>;
+			ranges;
+			ti,hwmods = "ocp2scp3";
+			sata_phy: phy@4a096000 {
+				compatible = "ti,phy-pipe3-sata";
+				reg = <0x4A096000 0x80>, /* phy_rx */
+				      <0x4A096400 0x64>, /* phy_tx */
+				      <0x4A096800 0x40>; /* pll_ctrl */
+				reg-names = "phy_rx", "phy_tx", "pll_ctrl";
+				ctrl-module = <&omap_control_sata>;
+				clocks = <&sys_clkin>;
+				clock-names = "sysclk";
+				#phy-cells = <0>;
+			};
+		};
+
+		sata: sata@4a141100 {
+			compatible = "snps,dwc-ahci";
+			reg = <0x4a140000 0x1100>, <0x4a141100 0x7>;
+			interrupts = <GIC_SPI 54 IRQ_TYPE_LEVEL_HIGH>;
+			phys = <&sata_phy>;
+			phy-names = "sata-phy";
+			clocks = <&sata_ref_clk>;
+			ti,hwmods = "sata";
+		};
+
 	};
 };
 
-- 
1.8.3.2

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

* [PATCH v3 7/8] ARM: DRA7: hwmod: Add ocp2scp3 and sata hwmods
  2014-03-07 10:15 [PATCH v3 0/8] ARM: OMAP: SATA support for OMAP5 & DRA7 Roger Quadros
                   ` (5 preceding siblings ...)
  2014-03-07 10:15 ` [PATCH v3 6/8] ARM: dts: omap5: add sata node Roger Quadros
@ 2014-03-07 10:15 ` Roger Quadros
  2014-03-07 10:15 ` [PATCH v3 8/8] ARM: dts: dra7: add OCP2SCP3 and SATA nodes Roger Quadros
  7 siblings, 0 replies; 12+ messages in thread
From: Roger Quadros @ 2014-03-07 10:15 UTC (permalink / raw)
  To: balbi, tony
  Cc: kishon, george.cherian, balajitk, hdegoede, linux-omap,
	linux-arm-kernel, linux-kernel, devicetree, linux-usb, rogerq,
	Benoit Cousson, Paul Walmsley, Nikhil Devshatwar

From: Nikhil Devshatwar <nikhil.nd@ti.com>

Add hwmods for ocp2scp3 and sata modules.

[Roger Q] Clean up.

CC: Benoit Cousson <bcousson@baylibre.com>
CC: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Balaji T K <balajitk@ti.com>
Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
Signed-off-by: Roger Quadros <rogerq@ti.com>
---
 arch/arm/mach-omap2/omap_hwmod_7xx_data.c | 31 ++++++++++++++++++++++++++-----
 1 file changed, 26 insertions(+), 5 deletions(-)

diff --git a/arch/arm/mach-omap2/omap_hwmod_7xx_data.c b/arch/arm/mach-omap2/omap_hwmod_7xx_data.c
index 18f333c..3c9a430 100644
--- a/arch/arm/mach-omap2/omap_hwmod_7xx_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_7xx_data.c
@@ -1215,6 +1215,30 @@ static struct omap_hwmod dra7xx_ocp2scp1_hwmod = {
 	},
 };
 
+/* ocp2scp3 */
+static struct omap_hwmod dra7xx_ocp2scp3_hwmod;
+
+/* l4_cfg -> ocp2scp3 */
+static struct omap_hwmod_ocp_if dra7xx_l4_cfg__ocp2scp3 = {
+	.master		= &dra7xx_l4_cfg_hwmod,
+	.slave		= &dra7xx_ocp2scp3_hwmod,
+	.clk		= "l4_root_clk_div",
+	.user		= OCP_USER_MPU | OCP_USER_SDMA,
+};
+
+static struct omap_hwmod dra7xx_ocp2scp3_hwmod = {
+	.name		= "ocp2scp3",
+	.class		= &dra7xx_ocp2scp_hwmod_class,
+	.clkdm_name	= "l3init_clkdm",
+	.prcm = {
+		.omap4 = {
+			.clkctrl_offs = DRA7XX_CM_L3INIT_OCP2SCP3_CLKCTRL_OFFSET,
+			.context_offs = DRA7XX_RM_L3INIT_OCP2SCP3_CONTEXT_OFFSET,
+			.modulemode   = MODULEMODE_HWCTRL,
+		},
+	},
+};
+
 /*
  * 'qspi' class
  *
@@ -1268,9 +1292,6 @@ static struct omap_hwmod_class dra7xx_sata_hwmod_class = {
 };
 
 /* sata */
-static struct omap_hwmod_opt_clk sata_opt_clks[] = {
-	{ .role = "ref_clk", .clk = "sata_ref_clk" },
-};
 
 static struct omap_hwmod dra7xx_sata_hwmod = {
 	.name		= "sata",
@@ -1278,6 +1299,7 @@ static struct omap_hwmod dra7xx_sata_hwmod = {
 	.clkdm_name	= "l3init_clkdm",
 	.flags		= HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
 	.main_clk	= "func_48m_fclk",
+	.mpu_rt_idx	= 1,
 	.prcm = {
 		.omap4 = {
 			.clkctrl_offs = DRA7XX_CM_L3INIT_SATA_CLKCTRL_OFFSET,
@@ -1285,8 +1307,6 @@ static struct omap_hwmod dra7xx_sata_hwmod = {
 			.modulemode   = MODULEMODE_SWCTRL,
 		},
 	},
-	.opt_clks	= sata_opt_clks,
-	.opt_clks_cnt	= ARRAY_SIZE(sata_opt_clks),
 };
 
 /*
@@ -2683,6 +2703,7 @@ static struct omap_hwmod_ocp_if *dra7xx_hwmod_ocp_ifs[] __initdata = {
 	&dra7xx_l4_per1__mmc4,
 	&dra7xx_l4_cfg__mpu,
 	&dra7xx_l4_cfg__ocp2scp1,
+	&dra7xx_l4_cfg__ocp2scp3,
 	&dra7xx_l3_main_1__qspi,
 	&dra7xx_l4_cfg__sata,
 	&dra7xx_l4_cfg__smartreflex_core,
-- 
1.8.3.2

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

* [PATCH v3 8/8] ARM: dts: dra7: add OCP2SCP3 and SATA nodes
  2014-03-07 10:15 [PATCH v3 0/8] ARM: OMAP: SATA support for OMAP5 & DRA7 Roger Quadros
                   ` (6 preceding siblings ...)
  2014-03-07 10:15 ` [PATCH v3 7/8] ARM: DRA7: hwmod: Add ocp2scp3 and sata hwmods Roger Quadros
@ 2014-03-07 10:15 ` Roger Quadros
  7 siblings, 0 replies; 12+ messages in thread
From: Roger Quadros @ 2014-03-07 10:15 UTC (permalink / raw)
  To: balbi, tony
  Cc: kishon, george.cherian, balajitk, hdegoede, linux-omap,
	linux-arm-kernel, linux-kernel, devicetree, linux-usb, rogerq,
	Benoit Cousson

From: Balaji T K <balajitk@ti.com>

Add nodes for OCP2SCP3 bus, SATA controller and SATA PHY.

[Roger Q] Clean up.

CC: Benoit Cousson <bcousson@baylibre.com>
Signed-off-by: Balaji T K <balajitk@ti.com>
Signed-off-by: Roger Quadros <rogerq@ti.com>
---
 arch/arm/boot/dts/dra7.dtsi | 39 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 39 insertions(+)

diff --git a/arch/arm/boot/dts/dra7.dtsi b/arch/arm/boot/dts/dra7.dtsi
index 9e3caf3..597979b 100644
--- a/arch/arm/boot/dts/dra7.dtsi
+++ b/arch/arm/boot/dts/dra7.dtsi
@@ -772,6 +772,45 @@
 			dma-names = "tx0", "rx0";
 			status = "disabled";
 		};
+
+		omap_control_sata: control-phy@4a002374 {
+			compatible = "ti,control-phy-pipe3";
+			reg = <0x4a002374 0x4>;
+			reg-names = "power";
+			clocks = <&sys_clkin1>;
+			clock-names = "sysclk";
+		};
+
+		/* OCP2SCP3 */
+		ocp2scp@4a090000 {
+			compatible = "ti,omap-ocp2scp";
+			#address-cells = <1>;
+			#size-cells = <1>;
+			ranges;
+			reg = <0x4a090000 0x20>;
+			ti,hwmods = "ocp2scp3";
+			sata_phy: phy@4A096000 {
+				compatible = "ti,phy-pipe3-sata";
+				reg = <0x4A096000 0x80>, /* phy_rx */
+				      <0x4A096400 0x64>, /* phy_tx */
+				      <0x4A096800 0x40>; /* pll_ctrl */
+				reg-names = "phy_rx", "phy_tx", "pll_ctrl";
+				ctrl-module = <&omap_control_sata>;
+				clocks = <&sys_clkin1>;
+				clock-names = "sysclk";
+				#phy-cells = <0>;
+			};
+		};
+
+		sata: sata@4a141100 {
+			compatible = "snps,dwc-ahci";
+			reg = <0x4a140000 0x1100>, <0x4a141100 0x7>;
+			interrupts = <GIC_SPI 54 IRQ_TYPE_LEVEL_HIGH>;
+			phys = <&sata_phy>;
+			phy-names = "sata-phy";
+			clocks = <&sata_ref_clk>;
+			ti,hwmods = "sata";
+		};
 	};
 };
 
-- 
1.8.3.2

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

* Re: [PATCH v3 5/8] ARM: OMAP5: hwmod: Add ocp2scp3 and sata hwmods
       [not found]   ` <1394187308-19622-6-git-send-email-rogerq-l0cyMroinI0@public.gmane.org>
@ 2014-03-12 17:47     ` Tony Lindgren
       [not found]       ` <20140312174703.GD1996-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>
  0 siblings, 1 reply; 12+ messages in thread
From: Tony Lindgren @ 2014-03-12 17:47 UTC (permalink / raw)
  To: Roger Quadros
  Cc: balbi-l0cyMroinI0, kishon-l0cyMroinI0, george.cherian-l0cyMroinI0,
	balajitk-l0cyMroinI0, hdegoede-H+wXaHxf7aLQT0dZR+AlfA,
	linux-omap-u79uwXL29TY76Z2rM5mHXA,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-usb-u79uwXL29TY76Z2rM5mHXA, Benoit Cousson, Paul Walmsley

* Roger Quadros <rogerq-l0cyMroinI0@public.gmane.org> [140307 02:18]:
> From: Keshava Munegowda <keshava_mgowda-l0cyMroinI0@public.gmane.org>
> 
> Create hwmods for ocp2scp3 and sata modules.

Paul, does this look OK to you?

Regards,

Tony
 
> [Roger Q] Clean up.
> 
> CC: Benoit Cousson <bcousson-rdvid1DuHRBWk0Htik3J/w@public.gmane.org>
> CC: Paul Walmsley <paul-DWxLp4Yu+b8AvxtiuMwx3w@public.gmane.org>
> CC: Tony Lindgren <tony-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>
> Signed-off-by: Balaji T K <balajitk-l0cyMroinI0@public.gmane.org>
> Signed-off-by: Roger Quadros <rogerq-l0cyMroinI0@public.gmane.org>
> ---
>  arch/arm/mach-omap2/omap_hwmod_54xx_data.c | 73 ++++++++++++++++++++++++++++++
>  1 file changed, 73 insertions(+)
> 
> diff --git a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
> index e297d62..227a69f 100644
> --- a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
> +++ b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
> @@ -1726,6 +1726,77 @@ static struct omap_hwmod omap54xx_wd_timer2_hwmod = {
>  	},
>  };
>  
> +/*
> + * 'ocp2scp' class
> + * bridge to transform ocp interface protocol to scp (serial control port)
> + * protocol
> + */
> +/* ocp2scp3 */
> +static struct omap_hwmod omap54xx_ocp2scp3_hwmod;
> +/* l4_cfg -> ocp2scp3 */
> +static struct omap_hwmod_ocp_if omap54xx_l4_cfg__ocp2scp3 = {
> +	.master		= &omap54xx_l4_cfg_hwmod,
> +	.slave		= &omap54xx_ocp2scp3_hwmod,
> +	.clk		= "l4_root_clk_div",
> +	.user		= OCP_USER_MPU | OCP_USER_SDMA,
> +};
> +
> +static struct omap_hwmod omap54xx_ocp2scp3_hwmod = {
> +	.name		= "ocp2scp3",
> +	.class		= &omap54xx_ocp2scp_hwmod_class,
> +	.clkdm_name	= "l3init_clkdm",
> +	.prcm = {
> +		.omap4 = {
> +			.clkctrl_offs = OMAP54XX_CM_L3INIT_OCP2SCP3_CLKCTRL_OFFSET,
> +			.context_offs = OMAP54XX_RM_L3INIT_OCP2SCP3_CONTEXT_OFFSET,
> +			.modulemode   = MODULEMODE_HWCTRL,
> +		},
> +	},
> +};
> +
> +/*
> + * 'sata' class
> + * sata:  serial ata interface  gen2 compliant   ( 1 rx/ 1 tx)
> + */
> +
> +static struct omap_hwmod_class_sysconfig omap54xx_sata_sysc = {
> +	.sysc_offs	= 0x0000,
> +	.sysc_flags	= (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
> +	.idlemodes	= (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
> +			   SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
> +			   MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
> +	.sysc_fields	= &omap_hwmod_sysc_type2,
> +};
> +
> +static struct omap_hwmod_class omap54xx_sata_hwmod_class = {
> +	.name	= "sata",
> +	.sysc	= &omap54xx_sata_sysc,
> +};
> +
> +/* sata */
> +static struct omap_hwmod omap54xx_sata_hwmod = {
> +	.name		= "sata",
> +	.class		= &omap54xx_sata_hwmod_class,
> +	.clkdm_name	= "l3init_clkdm",
> +	.flags		= HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
> +	.main_clk	= "func_48m_fclk",
> +	.mpu_rt_idx	= 1,
> +	.prcm = {
> +		.omap4 = {
> +			.clkctrl_offs = OMAP54XX_CM_L3INIT_SATA_CLKCTRL_OFFSET,
> +			.context_offs = OMAP54XX_RM_L3INIT_SATA_CONTEXT_OFFSET,
> +			.modulemode   = MODULEMODE_SWCTRL,
> +		},
> +	},
> +};
> +
> +/* l4_cfg -> sata */
> +static struct omap_hwmod_ocp_if omap54xx_l4_cfg__sata = {
> +	.master		= &omap54xx_l4_cfg_hwmod,
> +	.slave		= &omap54xx_sata_hwmod,
> +	.clk		= "l3_iclk_div",
> +	.user		= OCP_USER_MPU | OCP_USER_SDMA,
> +};
>  
>  /*
>   * Interfaces
> @@ -2399,6 +2470,8 @@ static struct omap_hwmod_ocp_if *omap54xx_hwmod_ocp_ifs[] __initdata = {
>  	&omap54xx_l4_cfg__usb_tll_hs,
>  	&omap54xx_l4_cfg__usb_otg_ss,
>  	&omap54xx_l4_wkup__wd_timer2,
> +	&omap54xx_l4_cfg__ocp2scp3,
> +	&omap54xx_l4_cfg__sata,
>  	NULL,
>  };
>  
> -- 
> 1.8.3.2
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH v3 5/8] ARM: OMAP5: hwmod: Add ocp2scp3 and sata hwmods
       [not found]       ` <20140312174703.GD1996-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>
@ 2014-03-13 21:44         ` Paul Walmsley
  2014-03-18 14:48           ` Roger Quadros
  0 siblings, 1 reply; 12+ messages in thread
From: Paul Walmsley @ 2014-03-13 21:44 UTC (permalink / raw)
  To: Tony Lindgren
  Cc: balbi-l0cyMroinI0, keshava_mgowda-l0cyMroinI0, rogerq-l0cyMroinI0,
	kishon-l0cyMroinI0, george.cherian-l0cyMroinI0,
	balajitk-l0cyMroinI0, hdegoede-H+wXaHxf7aLQT0dZR+AlfA,
	linux-omap-u79uwXL29TY76Z2rM5mHXA,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-usb-u79uwXL29TY76Z2rM5mHXA, Benoit Cousson

On Wed, 12 Mar 2014, Tony Lindgren wrote:

> * Roger Quadros <rogerq-l0cyMroinI0@public.gmane.org> [140307 02:18]:
> > From: Keshava Munegowda <keshava_mgowda-l0cyMroinI0@public.gmane.org>
> > 
> > Create hwmods for ocp2scp3 and sata modules.
> 
> Paul, does this look OK to you?

I didn't go over every entry with a magnifying glass, but did take a 
quick look at the sysc_offs and the clkdms - the basics look OK.

Acked-by: Paul Walmsley <paul-DWxLp4Yu+b8AvxtiuMwx3w@public.gmane.org>


- Paul

> 
> Regards,
> 
> Tony
>  
> > [Roger Q] Clean up.
> > 
> > CC: Benoit Cousson <bcousson-rdvid1DuHRBWk0Htik3J/w@public.gmane.org>
> > CC: Paul Walmsley <paul-DWxLp4Yu+b8AvxtiuMwx3w@public.gmane.org>
> > CC: Tony Lindgren <tony-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>
> > Signed-off-by: Balaji T K <balajitk-l0cyMroinI0@public.gmane.org>
> > Signed-off-by: Roger Quadros <rogerq-l0cyMroinI0@public.gmane.org>
> > ---
> >  arch/arm/mach-omap2/omap_hwmod_54xx_data.c | 73 ++++++++++++++++++++++++++++++
> >  1 file changed, 73 insertions(+)
> > 
> > diff --git a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
> > index e297d62..227a69f 100644
> > --- a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
> > +++ b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
> > @@ -1726,6 +1726,77 @@ static struct omap_hwmod omap54xx_wd_timer2_hwmod = {
> >  	},
> >  };
> >  
> > +/*
> > + * 'ocp2scp' class
> > + * bridge to transform ocp interface protocol to scp (serial control port)
> > + * protocol
> > + */
> > +/* ocp2scp3 */
> > +static struct omap_hwmod omap54xx_ocp2scp3_hwmod;
> > +/* l4_cfg -> ocp2scp3 */
> > +static struct omap_hwmod_ocp_if omap54xx_l4_cfg__ocp2scp3 = {
> > +	.master		= &omap54xx_l4_cfg_hwmod,
> > +	.slave		= &omap54xx_ocp2scp3_hwmod,
> > +	.clk		= "l4_root_clk_div",
> > +	.user		= OCP_USER_MPU | OCP_USER_SDMA,
> > +};
> > +
> > +static struct omap_hwmod omap54xx_ocp2scp3_hwmod = {
> > +	.name		= "ocp2scp3",
> > +	.class		= &omap54xx_ocp2scp_hwmod_class,
> > +	.clkdm_name	= "l3init_clkdm",
> > +	.prcm = {
> > +		.omap4 = {
> > +			.clkctrl_offs = OMAP54XX_CM_L3INIT_OCP2SCP3_CLKCTRL_OFFSET,
> > +			.context_offs = OMAP54XX_RM_L3INIT_OCP2SCP3_CONTEXT_OFFSET,
> > +			.modulemode   = MODULEMODE_HWCTRL,
> > +		},
> > +	},
> > +};
> > +
> > +/*
> > + * 'sata' class
> > + * sata:  serial ata interface  gen2 compliant   ( 1 rx/ 1 tx)
> > + */
> > +
> > +static struct omap_hwmod_class_sysconfig omap54xx_sata_sysc = {
> > +	.sysc_offs	= 0x0000,
> > +	.sysc_flags	= (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
> > +	.idlemodes	= (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
> > +			   SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
> > +			   MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
> > +	.sysc_fields	= &omap_hwmod_sysc_type2,
> > +};
> > +
> > +static struct omap_hwmod_class omap54xx_sata_hwmod_class = {
> > +	.name	= "sata",
> > +	.sysc	= &omap54xx_sata_sysc,
> > +};
> > +
> > +/* sata */
> > +static struct omap_hwmod omap54xx_sata_hwmod = {
> > +	.name		= "sata",
> > +	.class		= &omap54xx_sata_hwmod_class,
> > +	.clkdm_name	= "l3init_clkdm",
> > +	.flags		= HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
> > +	.main_clk	= "func_48m_fclk",
> > +	.mpu_rt_idx	= 1,
> > +	.prcm = {
> > +		.omap4 = {
> > +			.clkctrl_offs = OMAP54XX_CM_L3INIT_SATA_CLKCTRL_OFFSET,
> > +			.context_offs = OMAP54XX_RM_L3INIT_SATA_CONTEXT_OFFSET,
> > +			.modulemode   = MODULEMODE_SWCTRL,
> > +		},
> > +	},
> > +};
> > +
> > +/* l4_cfg -> sata */
> > +static struct omap_hwmod_ocp_if omap54xx_l4_cfg__sata = {
> > +	.master		= &omap54xx_l4_cfg_hwmod,
> > +	.slave		= &omap54xx_sata_hwmod,
> > +	.clk		= "l3_iclk_div",
> > +	.user		= OCP_USER_MPU | OCP_USER_SDMA,
> > +};
> >  
> >  /*
> >   * Interfaces
> > @@ -2399,6 +2470,8 @@ static struct omap_hwmod_ocp_if *omap54xx_hwmod_ocp_ifs[] __initdata = {
> >  	&omap54xx_l4_cfg__usb_tll_hs,
> >  	&omap54xx_l4_cfg__usb_otg_ss,
> >  	&omap54xx_l4_wkup__wd_timer2,
> > +	&omap54xx_l4_cfg__ocp2scp3,
> > +	&omap54xx_l4_cfg__sata,
> >  	NULL,
> >  };
> >  
> > -- 
> > 1.8.3.2
> > 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 


- Paul
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH v3 5/8] ARM: OMAP5: hwmod: Add ocp2scp3 and sata hwmods
  2014-03-13 21:44         ` Paul Walmsley
@ 2014-03-18 14:48           ` Roger Quadros
  0 siblings, 0 replies; 12+ messages in thread
From: Roger Quadros @ 2014-03-18 14:48 UTC (permalink / raw)
  To: Paul Walmsley, Tony Lindgren
  Cc: devicetree, george.cherian, balajitk, linux-usb, linux-kernel,
	balbi, kishon, hdegoede, Benoit Cousson, linux-omap,
	linux-arm-kernel

Hi Tony,

On 03/13/2014 11:44 PM, Paul Walmsley wrote:
> On Wed, 12 Mar 2014, Tony Lindgren wrote:
> 
>> * Roger Quadros <rogerq@ti.com> [140307 02:18]:
>>> From: Keshava Munegowda <keshava_mgowda@ti.com>
>>>
>>> Create hwmods for ocp2scp3 and sata modules.
>>
>> Paul, does this look OK to you?
> 
> I didn't go over every entry with a magnifying glass, but did take a 
> quick look at the sysc_offs and the clkdms - the basics look OK.
> 
> Acked-by: Paul Walmsley <paul@pwsan.com>
> 

Is there any chance this can still make it into 3.15? Would be nice to have SATA
working out of the box.

cheers,
-roger

> 
> - Paul
> 
>>
>> Regards,
>>
>> Tony
>>  
>>> [Roger Q] Clean up.
>>>
>>> CC: Benoit Cousson <bcousson@baylibre.com>
>>> CC: Paul Walmsley <paul@pwsan.com>
>>> CC: Tony Lindgren <tony@atomide.com>
>>> Signed-off-by: Balaji T K <balajitk@ti.com>
>>> Signed-off-by: Roger Quadros <rogerq@ti.com>
>>> ---
>>>  arch/arm/mach-omap2/omap_hwmod_54xx_data.c | 73 ++++++++++++++++++++++++++++++
>>>  1 file changed, 73 insertions(+)
>>>
>>> diff --git a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
>>> index e297d62..227a69f 100644
>>> --- a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
>>> +++ b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
>>> @@ -1726,6 +1726,77 @@ static struct omap_hwmod omap54xx_wd_timer2_hwmod = {
>>>  	},
>>>  };
>>>  
>>> +/*
>>> + * 'ocp2scp' class
>>> + * bridge to transform ocp interface protocol to scp (serial control port)
>>> + * protocol
>>> + */
>>> +/* ocp2scp3 */
>>> +static struct omap_hwmod omap54xx_ocp2scp3_hwmod;
>>> +/* l4_cfg -> ocp2scp3 */
>>> +static struct omap_hwmod_ocp_if omap54xx_l4_cfg__ocp2scp3 = {
>>> +	.master		= &omap54xx_l4_cfg_hwmod,
>>> +	.slave		= &omap54xx_ocp2scp3_hwmod,
>>> +	.clk		= "l4_root_clk_div",
>>> +	.user		= OCP_USER_MPU | OCP_USER_SDMA,
>>> +};
>>> +
>>> +static struct omap_hwmod omap54xx_ocp2scp3_hwmod = {
>>> +	.name		= "ocp2scp3",
>>> +	.class		= &omap54xx_ocp2scp_hwmod_class,
>>> +	.clkdm_name	= "l3init_clkdm",
>>> +	.prcm = {
>>> +		.omap4 = {
>>> +			.clkctrl_offs = OMAP54XX_CM_L3INIT_OCP2SCP3_CLKCTRL_OFFSET,
>>> +			.context_offs = OMAP54XX_RM_L3INIT_OCP2SCP3_CONTEXT_OFFSET,
>>> +			.modulemode   = MODULEMODE_HWCTRL,
>>> +		},
>>> +	},
>>> +};
>>> +
>>> +/*
>>> + * 'sata' class
>>> + * sata:  serial ata interface  gen2 compliant   ( 1 rx/ 1 tx)
>>> + */
>>> +
>>> +static struct omap_hwmod_class_sysconfig omap54xx_sata_sysc = {
>>> +	.sysc_offs	= 0x0000,
>>> +	.sysc_flags	= (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE),
>>> +	.idlemodes	= (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
>>> +			   SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
>>> +			   MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
>>> +	.sysc_fields	= &omap_hwmod_sysc_type2,
>>> +};
>>> +
>>> +static struct omap_hwmod_class omap54xx_sata_hwmod_class = {
>>> +	.name	= "sata",
>>> +	.sysc	= &omap54xx_sata_sysc,
>>> +};
>>> +
>>> +/* sata */
>>> +static struct omap_hwmod omap54xx_sata_hwmod = {
>>> +	.name		= "sata",
>>> +	.class		= &omap54xx_sata_hwmod_class,
>>> +	.clkdm_name	= "l3init_clkdm",
>>> +	.flags		= HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
>>> +	.main_clk	= "func_48m_fclk",
>>> +	.mpu_rt_idx	= 1,
>>> +	.prcm = {
>>> +		.omap4 = {
>>> +			.clkctrl_offs = OMAP54XX_CM_L3INIT_SATA_CLKCTRL_OFFSET,
>>> +			.context_offs = OMAP54XX_RM_L3INIT_SATA_CONTEXT_OFFSET,
>>> +			.modulemode   = MODULEMODE_SWCTRL,
>>> +		},
>>> +	},
>>> +};
>>> +
>>> +/* l4_cfg -> sata */
>>> +static struct omap_hwmod_ocp_if omap54xx_l4_cfg__sata = {
>>> +	.master		= &omap54xx_l4_cfg_hwmod,
>>> +	.slave		= &omap54xx_sata_hwmod,
>>> +	.clk		= "l3_iclk_div",
>>> +	.user		= OCP_USER_MPU | OCP_USER_SDMA,
>>> +};
>>>  
>>>  /*
>>>   * Interfaces
>>> @@ -2399,6 +2470,8 @@ static struct omap_hwmod_ocp_if *omap54xx_hwmod_ocp_ifs[] __initdata = {
>>>  	&omap54xx_l4_cfg__usb_tll_hs,
>>>  	&omap54xx_l4_cfg__usb_otg_ss,
>>>  	&omap54xx_l4_wkup__wd_timer2,
>>> +	&omap54xx_l4_cfg__ocp2scp3,
>>> +	&omap54xx_l4_cfg__sata,
>>>  	NULL,
>>>  };
>>>  
>>> -- 
>>> 1.8.3.2
>>>
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>
> 
> 
> - Paul
> 

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

end of thread, other threads:[~2014-03-18 14:48 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-07 10:15 [PATCH v3 0/8] ARM: OMAP: SATA support for OMAP5 & DRA7 Roger Quadros
2014-03-07 10:15 ` [PATCH v3 1/8] phy: omap-control: update dra7 and am437 usb2 Documentation bindings Roger Quadros
2014-03-07 10:15 ` [PATCH v3 2/8] phy: ti-pipe3: Add clocks to PIPE3 PHY Documentation binding Roger Quadros
2014-03-07 10:15 ` [PATCH v3 3/8] phy: ti-pipe3: Add SATA compatible to " Roger Quadros
2014-03-07 10:15 ` [PATCH v3 4/8] ARM: dts: omap5: Add clocks to USB3 PHY node Roger Quadros
2014-03-07 10:15 ` [PATCH v3 5/8] ARM: OMAP5: hwmod: Add ocp2scp3 and sata hwmods Roger Quadros
     [not found]   ` <1394187308-19622-6-git-send-email-rogerq-l0cyMroinI0@public.gmane.org>
2014-03-12 17:47     ` Tony Lindgren
     [not found]       ` <20140312174703.GD1996-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>
2014-03-13 21:44         ` Paul Walmsley
2014-03-18 14:48           ` Roger Quadros
2014-03-07 10:15 ` [PATCH v3 6/8] ARM: dts: omap5: add sata node Roger Quadros
2014-03-07 10:15 ` [PATCH v3 7/8] ARM: DRA7: hwmod: Add ocp2scp3 and sata hwmods Roger Quadros
2014-03-07 10:15 ` [PATCH v3 8/8] ARM: dts: dra7: add OCP2SCP3 and SATA nodes Roger Quadros

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).