Skip to contentSkip to conversation

usb: musb: HWMOD database structures fixes OMAP4

PATCH Superseded Hema HK 2 participants 3 messages Aug 6, 2010 – Aug 10, 2010 1 message not in the archive

Subsystems (4)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Hema HK

author
#0 lore raw

PATCH 4/8 usb: musb: HWMOD database structures fixes OMAP4

From: Hema HK <[email protected]>

Fixed the missing sysc settings for OMAP4 and enabled the OMAP4 hwmod data structure.

Cc Felipe Balbi <[email protected]>
Cc Tony Lindgren <[email protected]>
Cc Kevin Hilman <[email protected]>

---

arch/arm/mach-omap2/omap_hwmod_44xx_data.c +10 -3
Index: linux-omap-pm/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
===================================================================
@@ -4516,8 +4516,15 @@
  */
 
 static struct omap_hwmod_class_sysconfig omap44xx_usb_otg_hs_sysc = {
-	.sysc_flags	= SYSS_MISSING,
-	.idlemodes	= (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
+
+	.rev_offs	= 0x0400,
+	.sysc_offs	= 0x0404,
+	.syss_offs	= 0x0408,
+	.sysc_flags	= SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE|
+			  SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
+			  SYSC_HAS_AUTOIDLE,
+	.idlemodes	= SIDLE_FORCE | SIDLE_NO | SIDLE_SMART,
+	.sysc_fields	= &omap_hwmod_sysc_type1,
 };
 
 static struct omap_hwmod_class omap44xx_usb_otg_hs_hwmod_class = {
@@ -4884,7 +4891,7 @@
 	/* usb_host_hs class */
 /*	&omap44xx_usb_host_hs_hwmod, */
 	/* usb_otg_hs class */
-/*	&omap44xx_usb_otg_hs_hwmod, */
+	&omap44xx_usb_otg_hs_hwmod,
 	/* usb_tll_hs class */
 /*	&omap44xx_usb_tll_hs_hwmod, */
 	/* wd_timer class */

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

#1 lore raw

Hi Hema,

Quoted 9 lines · Hema

From: Hema HK<[email protected]>

Fixed the missing sysc settings for OMAP4 and enabled the OMAP4 hwmod data structure.

Cc Felipe Balbi<[email protected]>
Cc Tony Lindgren<[email protected]>
Cc Kevin Hilman<[email protected]>

It is a good practice, if not mandatory, to CC the authors of the file you are modifying with your patch. Neither Paul, nor myself are in CC of this patch. Could you please add us to this one and the other ones when applicable?

Quoted 12 lines

---

Index: linux-omap-pm/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
===================================================================

arch/arm/mach-omap2/omap_hwmod_44xx_data.c +0 -2
@@ -4516,8 +4516,15 @@
   */
 
  static struct omap_hwmod_class_sysconfig omap44xx_usb_otg_hs_sysc = {
-	.sysc_flags	= SYSS_MISSING,
-	.idlemodes	= (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),

arch/arm/mach-omap2/omap_hwmod_44xx_data.c line 4528

Quoted 10 lines
arch/arm/mach-omap2/omap_hwmod_44xx_data.c +9 -0
+
+	.rev_offs	= 0x0400,
+	.sysc_offs	= 0x0404,
+	.syss_offs	= 0x0408,
+	.sysc_flags	= SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE|
+			  SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
+			  SYSC_HAS_AUTOIDLE,
+	.idlemodes	= SIDLE_FORCE | SIDLE_NO | SIDLE_SMART,
+	.sysc_fields	=&omap_hwmod_sysc_type1,
  };

This part if fine except the missing MIDLE_XXX modes. Here is the modified version using the same convention as other modules:

arch/arm/mach-omap2/omap_hwmod_44xx_data.c line 4528

Quoted 13 lines
arch/arm/mach-omap2/omap_hwmod_44xx_data.c +9 -2
 static struct omap_hwmod_class_sysconfig omap44xx_usb_otg_hs_sysc = {
-       .sysc_flags     = SYSS_MISSING,
-       .idlemodes      = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
+       .rev_offs       = 0x0400,
+       .sysc_offs      = 0x0404,
+       .syss_offs      = 0x0408,
+       .sysc_flags     = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
+                          SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
+                          SYSC_HAS_SOFTRESET),
+       .idlemodes      = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
+                          MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
+       .sysc_fields    = &omap_hwmod_sysc_type1,
 };

I don't have any preference for the parens, but in order to be consistent with the already existing hwmods, let's keep them.

Regards,
Benoit

A message that is not in the archive (sent off-list or not yet received): [email protected]

#3 lore raw

Hi,

Quoted 22 lines

-----Original Message-----
From: Cousson, Benoit
Sent: Monday, August 09, 2010 5:22 PM
To: Kalliguddi, Hema
Cc: [email protected]; [email protected]; Felipe Balbi; Tony Lindgren; Kevin Hilman
Subject: Re: [PATCH 4/8]usb: musb: HWMOD database structures
fixes OMAP4

Hi Hema,

Quoted 9 lines · Hema

From: Hema HK<[email protected]>

Fixed the missing sysc settings for OMAP4 and enabled the OMAP4 hwmod data structure.

Cc Felipe Balbi<[email protected]>
Cc Tony Lindgren<[email protected]>
Cc Kevin Hilman<[email protected]>
Quoted 4 lines

It is a good practice, if not mandatory, to CC the authors of the file you are modifying with your patch.
Neither Paul, nor myself are in CC of this patch. Could you please add us to this one and the other ones when applicable?

It is mistake of not CCing the owner. I will take care of it.

Quoted 15 lines
Quoted 6 lines

---

Index: linux-omap-pm/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
===================================================================
---

linux-omap-pm.orig/arch/arm/mach-omap2/omap_hwmod_44xx_data.c

2010-08-06 08:31:45.885868560 -0400
Quoted 1 line

+++ linux-omap-pm/arch/arm/mach-omap2/omap_hwmod_44xx_data.c

2010-08-06 08:35:41.250112281 -0400

Review line 4518

Quoted 4 lines
(quoted diff) +0 -0
@@ -4516,8 +4516,15 @@
   */
 
  static struct omap_hwmod_class_sysconfig 

omap44xx_usb_otg_hs_sysc = {

Quoted 15 lines

arch/arm/mach-omap2/omap_hwmod_44xx_data.c line 4528

Quoted 12 lines
arch/arm/mach-omap2/omap_hwmod_44xx_data.c +9 -2
-	.sysc_flags	= SYSS_MISSING,
-	.idlemodes	= (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
+
+	.rev_offs	= 0x0400,
+	.sysc_offs	= 0x0404,
+	.syss_offs	= 0x0408,
+	.sysc_flags	= SYSC_HAS_SIDLEMODE | SYSC_HAS_MIDLEMODE|
+			  SYSC_HAS_ENAWAKEUP | SYSC_HAS_SOFTRESET |
+			  SYSC_HAS_AUTOIDLE,
+	.idlemodes	= SIDLE_FORCE | SIDLE_NO | SIDLE_SMART,
+	.sysc_fields	=&omap_hwmod_sysc_type1,
  };

This part if fine except the missing MIDLE_XXX modes. Here is the modified version using the same convention as other modules:

OK. I will add it.

Quoted 13 lines

Review line 4529

Quoted 2 lines
(quoted diff) +0 -0
 static struct omap_hwmod_class_sysconfig 

omap44xx_usb_otg_hs_sysc = {

arch/arm/mach-omap2/omap_hwmod_44xx_data.c

Quoted 10 lines
arch/arm/mach-omap2/omap_hwmod_44xx_data.c +8 -2
-       .sysc_flags     = SYSS_MISSING,
-       .idlemodes      = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART),
+       .rev_offs       = 0x0400,
+       .sysc_offs      = 0x0404,
+       .syss_offs      = 0x0408,
+       .sysc_flags     = (SYSC_HAS_AUTOIDLE | SYSC_HAS_ENAWAKEUP |
+                          SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
+                          SYSC_HAS_SOFTRESET),
+       .idlemodes      = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
+                          MSTANDBY_FORCE | MSTANDBY_NO | 
Quoted 6 lines

MSTANDBY_SMART),

Quoted 2 lines

+ .sysc_fields = &omap_hwmod_sysc_type1,
};

I don't have any preference for the parens, but in order to be consistent with the already existing hwmods, let's keep them.

There was comment from Sergie to remove the parens for omap3 database. So I have removed.

Quoted 4 lines

Regards,
Benoit
--

To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html