diff mbox

[v2,2/2] ARM: dts: imx6q-sabrelite: add usbmisc device

Message ID 1342607348-8587-3-git-send-email-richard.zhao@freescale.com (mailing list archive)
State New, archived
Headers show

Commit Message

Richard Zhao July 18, 2012, 10:29 a.m. UTC
Signed-off-by: Richard Zhao <richard.zhao@freescale.com>
---
 arch/arm/boot/dts/imx6q-sabrelite.dts |    4 ++++
 arch/arm/boot/dts/imx6q.dtsi          |   19 +++++++++++++++----
 arch/arm/mach-imx/clk-imx6q.c         |    1 +
 3 files changed, 20 insertions(+), 4 deletions(-)

Comments

Sascha Hauer July 18, 2012, 10:54 a.m. UTC | #1
On Wed, Jul 18, 2012 at 06:29:07PM +0800, Richard Zhao wrote:
> Signed-off-by: Richard Zhao <richard.zhao@freescale.com>
> ---
>  arch/arm/boot/dts/imx6q-sabrelite.dts |    4 ++++
>  arch/arm/boot/dts/imx6q.dtsi          |   19 +++++++++++++++----
>  arch/arm/mach-imx/clk-imx6q.c         |    1 +
>  3 files changed, 20 insertions(+), 4 deletions(-)
> 
> diff --git a/arch/arm/boot/dts/imx6q-sabrelite.dts b/arch/arm/boot/dts/imx6q-sabrelite.dts
> index d42e851..c66ff9d 100644
> --- a/arch/arm/boot/dts/imx6q-sabrelite.dts
> +++ b/arch/arm/boot/dts/imx6q-sabrelite.dts
> @@ -62,12 +62,16 @@
>  		aips-bus@02100000 { /* AIPS2 */
>  			usb@02184000 { /* USB OTG */
>  				vbus-supply = <&reg_usb_otg_vbus>;
> +				disable-over-current;
>  				status = "okay";
>  			};
>  
>  			usb@02184200 { /* USB1 */
>  				status = "okay";
>  			};
> +			usbmisc@02184800 {
> +				status = "okay";
> +			};

Do we need to have this disabled initially in the SoC dtsi?

Also, common style in this file is to add a blank line between nodes.
Please keep it.

Sascha
Richard Zhao July 18, 2012, 11:22 a.m. UTC | #2
On Wed, Jul 18, 2012 at 12:54:31PM +0200, Sascha Hauer wrote:
> On Wed, Jul 18, 2012 at 06:29:07PM +0800, Richard Zhao wrote:
> > Signed-off-by: Richard Zhao <richard.zhao@freescale.com>
> > ---
> >  arch/arm/boot/dts/imx6q-sabrelite.dts |    4 ++++
> >  arch/arm/boot/dts/imx6q.dtsi          |   19 +++++++++++++++----
> >  arch/arm/mach-imx/clk-imx6q.c         |    1 +
> >  3 files changed, 20 insertions(+), 4 deletions(-)
> > 
> > diff --git a/arch/arm/boot/dts/imx6q-sabrelite.dts b/arch/arm/boot/dts/imx6q-sabrelite.dts
> > index d42e851..c66ff9d 100644
> > --- a/arch/arm/boot/dts/imx6q-sabrelite.dts
> > +++ b/arch/arm/boot/dts/imx6q-sabrelite.dts
> > @@ -62,12 +62,16 @@
> >  		aips-bus@02100000 { /* AIPS2 */
> >  			usb@02184000 { /* USB OTG */
> >  				vbus-supply = <&reg_usb_otg_vbus>;
> > +				disable-over-current;
> >  				status = "okay";
> >  			};
> >  
> >  			usb@02184200 { /* USB1 */
> >  				status = "okay";
> >  			};
> > +			usbmisc@02184800 {
> > +				status = "okay";
> > +			};
> 
> Do we need to have this disabled initially in the SoC dtsi?
It's in SoC, and don't affect anything outside of Soc. So I think
it can be enabled by default.
> 
> Also, common style in this file is to add a blank line between nodes.
> Please keep it.
yes.

Thanks
Richard
> 
> Sascha
> 
> 
> -- 
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 | http://www.pengutronix.de/  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |
>
Shawn Guo July 18, 2012, 3 p.m. UTC | #3
On Wed, Jul 18, 2012 at 06:29:07PM +0800, Richard Zhao wrote:
> Signed-off-by: Richard Zhao <richard.zhao@freescale.com>
> ---
>  arch/arm/boot/dts/imx6q-sabrelite.dts |    4 ++++
>  arch/arm/boot/dts/imx6q.dtsi          |   19 +++++++++++++++----
>  arch/arm/mach-imx/clk-imx6q.c         |    1 +

It seems that the patch is meant to have dts changes only by reading
the subject.  So it might be good to get clk-imx6q.c out of here.

Shawn
Richard Zhao July 19, 2012, 2:02 a.m. UTC | #4
On Wed, Jul 18, 2012 at 11:00:38PM +0800, Shawn Guo wrote:
> On Wed, Jul 18, 2012 at 06:29:07PM +0800, Richard Zhao wrote:
> > Signed-off-by: Richard Zhao <richard.zhao@freescale.com>
> > ---
> >  arch/arm/boot/dts/imx6q-sabrelite.dts |    4 ++++
> >  arch/arm/boot/dts/imx6q.dtsi          |   19 +++++++++++++++----
> >  arch/arm/mach-imx/clk-imx6q.c         |    1 +
> 
> It seems that the patch is meant to have dts changes only by reading
> the subject.  So it might be good to get clk-imx6q.c out of here.
Thanks. It'll be divided into two.

Richard
> 
> Shawn
diff mbox

Patch

diff --git a/arch/arm/boot/dts/imx6q-sabrelite.dts b/arch/arm/boot/dts/imx6q-sabrelite.dts
index d42e851..c66ff9d 100644
--- a/arch/arm/boot/dts/imx6q-sabrelite.dts
+++ b/arch/arm/boot/dts/imx6q-sabrelite.dts
@@ -62,12 +62,16 @@ 
 		aips-bus@02100000 { /* AIPS2 */
 			usb@02184000 { /* USB OTG */
 				vbus-supply = <&reg_usb_otg_vbus>;
+				disable-over-current;
 				status = "okay";
 			};
 
 			usb@02184200 { /* USB1 */
 				status = "okay";
 			};
+			usbmisc@02184800 {
+				status = "okay";
+			};
 
 			ethernet@02188000 {
 				phy-mode = "rgmii";
diff --git a/arch/arm/boot/dts/imx6q.dtsi b/arch/arm/boot/dts/imx6q.dtsi
index c25d495..42b0c39 100644
--- a/arch/arm/boot/dts/imx6q.dtsi
+++ b/arch/arm/boot/dts/imx6q.dtsi
@@ -19,6 +19,11 @@ 
 		serial2 = &uart3;
 		serial3 = &uart4;
 		serial4 = &uart5;
+
+		usb0 = &usbotg;
+		usb1 = &usbhost1;
+		usb2 = &usbhost2;
+		usb3 = &usbhost3;
 	};
 
 	cpus {
@@ -624,7 +629,7 @@ 
 				reg = <0x0217c000 0x4000>;
 			};
 
-			usb@02184000 { /* USB OTG */
+			usbotg: usb@02184000 {
 				compatible = "fsl,imx6q-usb", "fsl,imx27-usb";
 				reg = <0x02184000 0x200>;
 				interrupts = <0 43 0x04>;
@@ -632,7 +637,7 @@ 
 				status = "disabled";
 			};
 
-			usb@02184200 { /* USB1 */
+			usbhost1: usb@02184200 {
 				compatible = "fsl,imx6q-usb", "fsl,imx27-usb";
 				reg = <0x02184200 0x200>;
 				interrupts = <0 40 0x04>;
@@ -640,20 +645,26 @@ 
 				status = "disabled";
 			};
 
-			usb@02184400 { /* USB2 */
+			usbhost2: usb@02184400 {
 				compatible = "fsl,imx6q-usb", "fsl,imx27-usb";
 				reg = <0x02184400 0x200>;
 				interrupts = <0 41 0x04>;
 				status = "disabled";
 			};
 
-			usb@02184600 { /* USB3 */
+			usbhost3: usb@02184600 {
 				compatible = "fsl,imx6q-usb", "fsl,imx27-usb";
 				reg = <0x02184600 0x200>;
 				interrupts = <0 42 0x04>;
 				status = "disabled";
 			};
 
+			usbmisc@02184800 {
+				compatible = "fsl,imx6q-usbmisc";
+				reg = <0x02184800 0x200>;
+				status = "disabled";
+			};
+
 			ethernet@02188000 {
 				compatible = "fsl,imx6q-fec";
 				reg = <0x02188000 0x4000>;
diff --git a/arch/arm/mach-imx/clk-imx6q.c b/arch/arm/mach-imx/clk-imx6q.c
index ea89520..660fcbb 100644
--- a/arch/arm/mach-imx/clk-imx6q.c
+++ b/arch/arm/mach-imx/clk-imx6q.c
@@ -405,6 +405,7 @@  int __init mx6q_clocks_init(void)
 	clk_register_clkdev(clk[usboh3], NULL, "2184200.usb");
 	clk_register_clkdev(clk[usboh3], NULL, "2184400.usb");
 	clk_register_clkdev(clk[usboh3], NULL, "2184600.usb");
+	clk_register_clkdev(clk[usboh3], NULL, "2184800.usbmisc");
 	clk_register_clkdev(clk[usbphy1], NULL, "20c9000.usbphy");
 	clk_register_clkdev(clk[usbphy2], NULL, "20ca000.usbphy");
 	clk_register_clkdev(clk[uart_serial], "per", "2020000.serial");