Re: [PATCH 1/5] OMAP4: PM: Update PRCM register bitshits and masks for ES2

2010-09-22 Thread Paul Walmsley
Hi Rajendra

On Thu, 16 Sep 2010, Rajendra Nayak wrote:

 This patch updates the PRM and CM register bitshifts and masks
 for OMAP4430 ES2.0.
 
 Signed-off-by: Rajendra Nayak rna...@ti.com
 Signed-off-by: Benoît Cousson b-cous...@ti.com
 Cc: Paul Walmsley p...@pwsan.com
 Cc: Kevin Hilman khil...@deeprootsystems.com

Thanks, queued for 2.6.37 (with the UTF-8 fix in the patch description).

One other note:

  #define OMAP4430_IDLEST_MASK BITFIELD(16, 17)

We should really get rid of all these 'BITFIELD' defines, and just replace 
them with simple bitshifts.  Care to spin a patch to do that during the 
2.6.38 timeframe?


- Paul

RE: [PATCH 1/5] OMAP4: PM: Update PRCM register bitshits and masks for ES2

2010-09-22 Thread Nayak, Rajendra


 -Original Message-
 From: Paul Walmsley [mailto:p...@pwsan.com]
 Sent: Wednesday, September 22, 2010 11:47 AM
 To: Nayak, Rajendra
 Cc: linux-omap@vger.kernel.org; Cousson, Benoit; Kevin Hilman
 Subject: Re: [PATCH 1/5] OMAP4: PM: Update PRCM register bitshits and masks 
 for
 ES2
 
 Hi Rajendra
 
 On Thu, 16 Sep 2010, Rajendra Nayak wrote:
 
  This patch updates the PRM and CM register bitshifts and masks
  for OMAP4430 ES2.0.
 
  Signed-off-by: Rajendra Nayak rna...@ti.com
  Signed-off-by: Benoît Cousson b-cous...@ti.com
  Cc: Paul Walmsley p...@pwsan.com
  Cc: Kevin Hilman khil...@deeprootsystems.com
 
 Thanks, queued for 2.6.37 (with the UTF-8 fix in the patch description).
 
 One other note:
 
   #define OMAP4430_IDLEST_MASK   
  BITFIELD(16,
 17)
 
 We should really get rid of all these 'BITFIELD' defines, and just replace
 them with simple bitshifts.  Care to spin a patch to do that during the
 2.6.38 timeframe?

Sure, there's already a patch for this which I guess Benoit should be posting 
pretty soon.

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


Re: [PATCH 1/5] OMAP4: PM: Update PRCM register bitshits and masks for ES2

2010-09-22 Thread Cousson, Benoit

On 9/22/2010 8:43 AM, Nayak, Rajendra wrote:



From: Paul Walmsley [mailto:p...@pwsan.com]
Sent: Wednesday, September 22, 2010 11:47 AM

Hi Rajendra

On Thu, 16 Sep 2010, Rajendra Nayak wrote:


This patch updates the PRM and CM register bitshifts and masks
for OMAP4430 ES2.0.

Signed-off-by: Rajendra Nayakrna...@ti.com
Signed-off-by: Benoît Coussonb-cous...@ti.com
Cc: Paul Walmsleyp...@pwsan.com
Cc: Kevin Hilmankhil...@deeprootsystems.com


Thanks, queued for 2.6.37 (with the UTF-8 fix in the patch description).

One other note:


  #define OMAP4430_IDLEST_MASK  BITFIELD(16,

17)

We should really get rid of all these 'BITFIELD' defines, and just replace
them with simple bitshifts.  Care to spin a patch to do that during the
2.6.38 timeframe?


Sure, there's already a patch for this which I guess Benoit should be posting 
pretty soon.


Yes, I already updated the scripts a couple of weeks ago to fix that on 
top of Rajendra's series.

Since it was not critical, I kind of forgot it :-)

I can sent the fix to you right now if you want?

Benoit
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/5] OMAP4: PM: Update PRCM register bitshits and masks for ES2

2010-09-22 Thread Paul Walmsley
On Wed, 22 Sep 2010, Cousson, Benoit wrote:

 On 9/22/2010 8:43 AM, Nayak, Rajendra wrote:
  
   From: Paul Walmsley [mailto:p...@pwsan.com]
   Sent: Wednesday, September 22, 2010 11:47 AM
   
   We should really get rid of all these 'BITFIELD' defines, and just replace
   them with simple bitshifts.  Care to spin a patch to do that during the
   2.6.38 timeframe?
  
  Sure, there's already a patch for this which I guess Benoit should be
  posting pretty soon.
 
 Yes, I already updated the scripts a couple of weeks ago to fix that on top of
 Rajendra's series.
 Since it was not critical, I kind of forgot it :-)
 
 I can sent the fix to you right now if you want?

Sure, if you have it ready to go, I'll take it.


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


[PATCH 1/5] OMAP4: PM: Update PRCM register bitshits and masks for ES2

2010-09-16 Thread rnayak
From: Rajendra Nayak rna...@ti.com

This patch updates the PRM and CM register bitshifts and masks
for OMAP4430 ES2.0.

Signed-off-by: Rajendra Nayak rna...@ti.com
Signed-off-by: Benoît Cousson b-cous...@ti.com
Cc: Paul Walmsley p...@pwsan.com
Cc: Kevin Hilman khil...@deeprootsystems.com
---
 arch/arm/mach-omap2/cm-regbits-44xx.h  |  327 ++--
 arch/arm/mach-omap2/prm-regbits-44xx.h |  194 +++
 2 files changed, 342 insertions(+), 179 deletions(-)

diff --git a/arch/arm/mach-omap2/cm-regbits-44xx.h 
b/arch/arm/mach-omap2/cm-regbits-44xx.h
index ac8458e..92ebfd4 100644
--- a/arch/arm/mach-omap2/cm-regbits-44xx.h
+++ b/arch/arm/mach-omap2/cm-regbits-44xx.h
@@ -1,8 +1,8 @@
 /*
  * OMAP44xx Clock Management register bits
  *
- * Copyright (C) 2009 Texas Instruments, Inc.
- * Copyright (C) 2009 Nokia Corporation
+ * Copyright (C) 2009-2010 Texas Instruments, Inc.
+ * Copyright (C) 2009-2010 Nokia Corporation
  *
  * Paul Walmsley (p...@pwsan.com)
  * Rajendra Nayak (rna...@ti.com)
@@ -25,19 +25,22 @@
 #include cm.h
 
 
-/* Used by CM_L3_1_DYNAMICDEP, CM_MPU_DYNAMICDEP, CM_TESLA_DYNAMICDEP */
+/*
+ * Used by CM_L3_1_DYNAMICDEP, CM_L3_1_DYNAMICDEP_RESTORE, CM_MPU_DYNAMICDEP,
+ * CM_TESLA_DYNAMICDEP
+ */
 #define OMAP4430_ABE_DYNDEP_SHIFT  3
 #define OMAP4430_ABE_DYNDEP_MASK   BITFIELD(3, 3)
 
 /*
  * Used by CM_D2D_STATICDEP, CM_DUCATI_STATICDEP, CM_SDMA_STATICDEP,
- * CM_L3INIT_STATICDEP, CM_SDMA_STATICDEP_RESTORE, CM_MPU_STATICDEP,
- * CM_TESLA_STATICDEP
+ * CM_L3INIT_STATICDEP, CM_D2D_STATICDEP_RESTORE, CM_SDMA_STATICDEP_RESTORE,
+ * CM_MPU_STATICDEP, CM_TESLA_STATICDEP
  */
 #define OMAP4430_ABE_STATDEP_SHIFT 3
 #define OMAP4430_ABE_STATDEP_MASK  BITFIELD(3, 3)
 
-/* Used by CM_L4CFG_DYNAMICDEP */
+/* Used by CM_L4CFG_DYNAMICDEP, CM_L4CFG_DYNAMICDEP_RESTORE */
 #define OMAP4430_ALWONCORE_DYNDEP_SHIFT16
 #define OMAP4430_ALWONCORE_DYNDEP_MASK BITFIELD(16, 16)
 
@@ -53,7 +56,7 @@
 #define OMAP4430_AUTO_DPLL_MODE_SHIFT  0
 #define OMAP4430_AUTO_DPLL_MODE_MASK   BITFIELD(0, 2)
 
-/* Used by CM_L4CFG_DYNAMICDEP */
+/* Used by CM_L4CFG_DYNAMICDEP, CM_L4CFG_DYNAMICDEP_RESTORE */
 #define OMAP4430_CEFUSE_DYNDEP_SHIFT   17
 #define OMAP4430_CEFUSE_DYNDEP_MASKBITFIELD(17, 17)
 
@@ -97,6 +100,10 @@
 #define OMAP4430_CLKACTIVITY_CAM_PHY_CTRL_GCLK_SHIFT   9
 #define OMAP4430_CLKACTIVITY_CAM_PHY_CTRL_GCLK_MASKBITFIELD(9, 9)
 
+/* Used by CM_ALWON_CLKSTCTRL */
+#define OMAP4430_CLKACTIVITY_CORE_ALWON_32K_GFCLK_SHIFT12
+#define OMAP4430_CLKACTIVITY_CORE_ALWON_32K_GFCLK_MASK BITFIELD(12, 12)
+
 /* Used by CM_EMU_CLKSTCTRL */
 #define OMAP4430_CLKACTIVITY_CORE_DPLL_EMU_CLK_SHIFT   9
 #define OMAP4430_CLKACTIVITY_CORE_DPLL_EMU_CLK_MASKBITFIELD(9, 9)
@@ -145,10 +152,6 @@
 #define OMAP4430_CLKACTIVITY_DUCATI_GCLK_SHIFT 8
 #define OMAP4430_CLKACTIVITY_DUCATI_GCLK_MASK  BITFIELD(8, 8)
 
-/* Used by CM_L3INIT_CLKSTCTRL, CM_L3INIT_CLKSTCTRL_RESTORE */
-#define OMAP4430_CLKACTIVITY_EMAC_50MHZ_CLK_SHIFT  10
-#define OMAP4430_CLKACTIVITY_EMAC_50MHZ_CLK_MASK   BITFIELD(10, 10)
-
 /* Used by CM_EMU_CLKSTCTRL */
 #define OMAP4430_CLKACTIVITY_EMU_SYS_CLK_SHIFT 8
 #define OMAP4430_CLKACTIVITY_EMU_SYS_CLK_MASK  BITFIELD(8, 8)
@@ -185,10 +188,6 @@
 #define OMAP4430_CLKACTIVITY_HSIC_P2_GFCLK_SHIFT   27
 #define OMAP4430_CLKACTIVITY_HSIC_P2_GFCLK_MASK
BITFIELD(27, 27)
 
-/* Used by CM_L3INIT_CLKSTCTRL */
-#define OMAP4430_CLKACTIVITY_INIT_32K_GFCLK_SHIFT  31
-#define OMAP4430_CLKACTIVITY_INIT_32K_GFCLK_MASK   BITFIELD(31, 31)
-
 /* Used by CM_L3INIT_CLKSTCTRL, CM_L3INIT_CLKSTCTRL_RESTORE */
 #define OMAP4430_CLKACTIVITY_INIT_48MC_GFCLK_SHIFT 13
 #define OMAP4430_CLKACTIVITY_INIT_48MC_GFCLK_MASK  BITFIELD(13, 13)
@@ -233,9 +232,9 @@
 #define OMAP4430_CLKACTIVITY_IVAHD_ROOT_CLK_SHIFT  8
 #define OMAP4430_CLKACTIVITY_IVAHD_ROOT_CLK_MASK   BITFIELD(8, 8)
 
-/* Used by CM_L3INIT_CLKSTCTRL, CM_L3INIT_CLKSTCTRL_RESTORE */
-#define OMAP4430_CLKACTIVITY_L3INIT_DPLL_ALWON_CLK_SHIFT   14
-#define OMAP4430_CLKACTIVITY_L3INIT_DPLL_ALWON_CLK_MASK
BITFIELD(14, 14)
+/* Used by CM_D2D_CLKSTCTRL */
+#define OMAP4430_CLKACTIVITY_L3X2_D2D_GICLK_SHIFT  10
+#define OMAP4430_CLKACTIVITY_L3X2_D2D_GICLK_MASK   BITFIELD(10, 10)
 
 /* Used by CM_L3_1_CLKSTCTRL, CM_L3_1_CLKSTCTRL_RESTORE */
 #define OMAP4430_CLKACTIVITY_L3_1_GICLK_SHIFT  8
@@ -337,10 +336,6 @@
 #define OMAP4430_CLKACTIVITY_PER_ABE_24M_GFCLK_SHIFT   25
 #define 

[PATCH 1/5] OMAP4: PM: Update PRCM register bitshits and masks for ES2

2010-09-16 Thread Rajendra Nayak
This patch updates the PRM and CM register bitshifts and masks
for OMAP4430 ES2.0.

Signed-off-by: Rajendra Nayak rna...@ti.com
Signed-off-by: Benoît Cousson b-cous...@ti.com
Cc: Paul Walmsley p...@pwsan.com
Cc: Kevin Hilman khil...@deeprootsystems.com
---
 arch/arm/mach-omap2/cm-regbits-44xx.h  |  327 ++--
 arch/arm/mach-omap2/prm-regbits-44xx.h |  194 +++
 2 files changed, 342 insertions(+), 179 deletions(-)

diff --git a/arch/arm/mach-omap2/cm-regbits-44xx.h 
b/arch/arm/mach-omap2/cm-regbits-44xx.h
index ac8458e..92ebfd4 100644
--- a/arch/arm/mach-omap2/cm-regbits-44xx.h
+++ b/arch/arm/mach-omap2/cm-regbits-44xx.h
@@ -1,8 +1,8 @@
 /*
  * OMAP44xx Clock Management register bits
  *
- * Copyright (C) 2009 Texas Instruments, Inc.
- * Copyright (C) 2009 Nokia Corporation
+ * Copyright (C) 2009-2010 Texas Instruments, Inc.
+ * Copyright (C) 2009-2010 Nokia Corporation
  *
  * Paul Walmsley (p...@pwsan.com)
  * Rajendra Nayak (rna...@ti.com)
@@ -25,19 +25,22 @@
 #include cm.h
 
 
-/* Used by CM_L3_1_DYNAMICDEP, CM_MPU_DYNAMICDEP, CM_TESLA_DYNAMICDEP */
+/*
+ * Used by CM_L3_1_DYNAMICDEP, CM_L3_1_DYNAMICDEP_RESTORE, CM_MPU_DYNAMICDEP,
+ * CM_TESLA_DYNAMICDEP
+ */
 #define OMAP4430_ABE_DYNDEP_SHIFT  3
 #define OMAP4430_ABE_DYNDEP_MASK   BITFIELD(3, 3)
 
 /*
  * Used by CM_D2D_STATICDEP, CM_DUCATI_STATICDEP, CM_SDMA_STATICDEP,
- * CM_L3INIT_STATICDEP, CM_SDMA_STATICDEP_RESTORE, CM_MPU_STATICDEP,
- * CM_TESLA_STATICDEP
+ * CM_L3INIT_STATICDEP, CM_D2D_STATICDEP_RESTORE, CM_SDMA_STATICDEP_RESTORE,
+ * CM_MPU_STATICDEP, CM_TESLA_STATICDEP
  */
 #define OMAP4430_ABE_STATDEP_SHIFT 3
 #define OMAP4430_ABE_STATDEP_MASK  BITFIELD(3, 3)
 
-/* Used by CM_L4CFG_DYNAMICDEP */
+/* Used by CM_L4CFG_DYNAMICDEP, CM_L4CFG_DYNAMICDEP_RESTORE */
 #define OMAP4430_ALWONCORE_DYNDEP_SHIFT16
 #define OMAP4430_ALWONCORE_DYNDEP_MASK BITFIELD(16, 16)
 
@@ -53,7 +56,7 @@
 #define OMAP4430_AUTO_DPLL_MODE_SHIFT  0
 #define OMAP4430_AUTO_DPLL_MODE_MASK   BITFIELD(0, 2)
 
-/* Used by CM_L4CFG_DYNAMICDEP */
+/* Used by CM_L4CFG_DYNAMICDEP, CM_L4CFG_DYNAMICDEP_RESTORE */
 #define OMAP4430_CEFUSE_DYNDEP_SHIFT   17
 #define OMAP4430_CEFUSE_DYNDEP_MASKBITFIELD(17, 17)
 
@@ -97,6 +100,10 @@
 #define OMAP4430_CLKACTIVITY_CAM_PHY_CTRL_GCLK_SHIFT   9
 #define OMAP4430_CLKACTIVITY_CAM_PHY_CTRL_GCLK_MASKBITFIELD(9, 9)
 
+/* Used by CM_ALWON_CLKSTCTRL */
+#define OMAP4430_CLKACTIVITY_CORE_ALWON_32K_GFCLK_SHIFT12
+#define OMAP4430_CLKACTIVITY_CORE_ALWON_32K_GFCLK_MASK BITFIELD(12, 12)
+
 /* Used by CM_EMU_CLKSTCTRL */
 #define OMAP4430_CLKACTIVITY_CORE_DPLL_EMU_CLK_SHIFT   9
 #define OMAP4430_CLKACTIVITY_CORE_DPLL_EMU_CLK_MASKBITFIELD(9, 9)
@@ -145,10 +152,6 @@
 #define OMAP4430_CLKACTIVITY_DUCATI_GCLK_SHIFT 8
 #define OMAP4430_CLKACTIVITY_DUCATI_GCLK_MASK  BITFIELD(8, 8)
 
-/* Used by CM_L3INIT_CLKSTCTRL, CM_L3INIT_CLKSTCTRL_RESTORE */
-#define OMAP4430_CLKACTIVITY_EMAC_50MHZ_CLK_SHIFT  10
-#define OMAP4430_CLKACTIVITY_EMAC_50MHZ_CLK_MASK   BITFIELD(10, 10)
-
 /* Used by CM_EMU_CLKSTCTRL */
 #define OMAP4430_CLKACTIVITY_EMU_SYS_CLK_SHIFT 8
 #define OMAP4430_CLKACTIVITY_EMU_SYS_CLK_MASK  BITFIELD(8, 8)
@@ -185,10 +188,6 @@
 #define OMAP4430_CLKACTIVITY_HSIC_P2_GFCLK_SHIFT   27
 #define OMAP4430_CLKACTIVITY_HSIC_P2_GFCLK_MASK
BITFIELD(27, 27)
 
-/* Used by CM_L3INIT_CLKSTCTRL */
-#define OMAP4430_CLKACTIVITY_INIT_32K_GFCLK_SHIFT  31
-#define OMAP4430_CLKACTIVITY_INIT_32K_GFCLK_MASK   BITFIELD(31, 31)
-
 /* Used by CM_L3INIT_CLKSTCTRL, CM_L3INIT_CLKSTCTRL_RESTORE */
 #define OMAP4430_CLKACTIVITY_INIT_48MC_GFCLK_SHIFT 13
 #define OMAP4430_CLKACTIVITY_INIT_48MC_GFCLK_MASK  BITFIELD(13, 13)
@@ -233,9 +232,9 @@
 #define OMAP4430_CLKACTIVITY_IVAHD_ROOT_CLK_SHIFT  8
 #define OMAP4430_CLKACTIVITY_IVAHD_ROOT_CLK_MASK   BITFIELD(8, 8)
 
-/* Used by CM_L3INIT_CLKSTCTRL, CM_L3INIT_CLKSTCTRL_RESTORE */
-#define OMAP4430_CLKACTIVITY_L3INIT_DPLL_ALWON_CLK_SHIFT   14
-#define OMAP4430_CLKACTIVITY_L3INIT_DPLL_ALWON_CLK_MASK
BITFIELD(14, 14)
+/* Used by CM_D2D_CLKSTCTRL */
+#define OMAP4430_CLKACTIVITY_L3X2_D2D_GICLK_SHIFT  10
+#define OMAP4430_CLKACTIVITY_L3X2_D2D_GICLK_MASK   BITFIELD(10, 10)
 
 /* Used by CM_L3_1_CLKSTCTRL, CM_L3_1_CLKSTCTRL_RESTORE */
 #define OMAP4430_CLKACTIVITY_L3_1_GICLK_SHIFT  8
@@ -337,10 +336,6 @@
 #define OMAP4430_CLKACTIVITY_PER_ABE_24M_GFCLK_SHIFT   25
 #define OMAP4430_CLKACTIVITY_PER_ABE_24M_GFCLK_MASK

Re: [PATCH 1/5] OMAP4: PM: Update PRCM register bitshits and masks for ES2

2010-09-16 Thread Kevin Hilman

 OMAP4: PM: Update PRCM register bitshits and masks for ES2
  

hmm, bit shits...

Looks like ES2 added another special register feature.  Sounds like an
operation to randomly trash register contents?;)

Kevin


--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html