public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
From: Rajendra Nayak <rnayak@ti.com>
To: Paul Walmsley <paul@pwsan.com>,
	linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org
Cc: Kevin Hilman <khilman@ti.com>, Nishanth Menon <nm@ti.com>,
	Benoit Cousson <b-cousson@ti.com>,
	Mike Turquette <mturquette@ti.com>
Subject: RE: [PATCH 0/3] OMAP2+: voltage: first pass at cleanup/reorganization
Date: Thu, 24 Feb 2011 17:27:52 +0530	[thread overview]
Message-ID: <553cd99ec29ee91e4a4b324d0f4a0be7@mail.gmail.com> (raw)
In-Reply-To: <20110221020231.7598.14024.stgit@twilight.localdomain>

[-- Attachment #1: Type: text/plain, Size: 8149 bytes --]

Hi Paul,

> -----Original Message-----
> From: linux-arm-kernel-bounces@lists.infradead.org
[mailto:linux-arm-kernel-bounces@lists.infradead.org] On Behalf
> Of Paul Walmsley
> Sent: Monday, February 21, 2011 7:39 AM
> To: linux-omap@vger.kernel.org; linux-arm-kernel@lists.infradead.org
> Cc: khilman@ti.com; nm@ti.com; b-cousson@ti.com; mturquette@ti.com
> Subject: [PATCH 0/3] OMAP2+: voltage: first pass at
cleanup/reorganization
>
> Hello,
>
> this patch set does an initial round of cleanup on the OMAP "voltage"
code
> in arch/arm/mach-omap2/voltage.c.  As part of this process, the header
files
> for the voltage code and SmartReflex are moved into arch/arm/mach-omap2,
since
> they are currently OMAP2+-specific.
>
> There is still quite a bit of cleanup left to do; hopefully someone else
will
> get to it before I do.  More details are in the last patch.
>
> This series was built-tested for an OSK5912-specific config,
omap1_defconfig,
> a N800-specific config, omap2plus_defconfig, an OMAP3-specific config,
and
> an OMAP4-specific config.  It was boot-tested on an OMAP35xx
Beagleboard.
> Further testing assistance is, of course, appreciated.

I found these abort on my 4430SDP. The below changes I found
are needed for it to bootup..
I tested the 'integration-2.6.39' branch of
git://git.pwsan.com/linux-integration and the patch is
based on this branch.

---
>From e3d5e2bb09ecb7a958c1f79b86d1917f0becb8d2 Mon Sep 17 00:00:00 2001
From: Rajendra Nayak <rnayak@ti.com>
Date: Thu, 24 Feb 2011 16:42:25 +0530
Subject: [PATCH] OMAP4: voltage: Populate missing .vp/.vc_common pointers

The common_data for vp and vc on OMAP4 is defined
but not hooked up with the corresponding
vp/vc_data.
This causes an abort at bootup on OMAP4, as the
framework api's assumes these to be present.

While here, also rename omap4_vp_data to
omap4_vp_common and omap4_vc_data to
omap4_vc_common to maintain consistency in
naming structs across all OMAPs.

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
---
 arch/arm/mach-omap2/vc44xx_data.c |    5 ++++-
 arch/arm/mach-omap2/vp44xx_data.c |    5 ++++-
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/arch/arm/mach-omap2/vc44xx_data.c
b/arch/arm/mach-omap2/vc44xx_data.c
index 548cb06..a98da8d 100644
--- a/arch/arm/mach-omap2/vc44xx_data.c
+++ b/arch/arm/mach-omap2/vc44xx_data.c
@@ -30,7 +30,7 @@
  * VC data common to 44xx chips
  * XXX This stuff presumably belongs in the vc3xxx.c or vc.c file.
  */
-static const struct omap_vc_common_data omap4_vc_data = {
+static const struct omap_vc_common_data omap4_vc_common = {
 	.smps_sa_reg = OMAP4_PRM_VC_SMPS_SA_OFFSET,
 	.smps_volra_reg = OMAP4_PRM_VC_VAL_SMPS_RA_VOL_OFFSET,
 	.bypass_val_reg = OMAP4_PRM_VC_VAL_BYPASS_OFFSET,
@@ -47,6 +47,7 @@ static const struct omap_vc_common_data omap4_vc_data =
{

 /* VC instance data for each controllable voltage line */
 struct omap_vc_instance_data omap4_vc_mpu_data = {
+	.vc_common = &omap4_vc_common,
 	.cmdval_reg = OMAP4_PRM_VC_VAL_CMD_VDD_MPU_L_OFFSET,
 	.smps_sa_shift = OMAP4430_SA_VDD_MPU_L_PRM_VC_SMPS_SA_SHIFT,
 	.smps_sa_mask = OMAP4430_SA_VDD_MPU_L_PRM_VC_SMPS_SA_MASK,
@@ -55,6 +56,7 @@ struct omap_vc_instance_data omap4_vc_mpu_data = {
 };

 struct omap_vc_instance_data omap4_vc_iva_data = {
+	.vc_common = &omap4_vc_common,
 	.cmdval_reg = OMAP4_PRM_VC_VAL_CMD_VDD_IVA_L_OFFSET,
 	.smps_sa_shift = OMAP4430_SA_VDD_IVA_L_PRM_VC_SMPS_SA_SHIFT,
 	.smps_sa_mask = OMAP4430_SA_VDD_IVA_L_PRM_VC_SMPS_SA_MASK,
@@ -63,6 +65,7 @@ struct omap_vc_instance_data omap4_vc_iva_data = {
 };

 struct omap_vc_instance_data omap4_vc_core_data = {
+	.vc_common = &omap4_vc_common,
 	.cmdval_reg = OMAP4_PRM_VC_VAL_CMD_VDD_CORE_L_OFFSET,
 	.smps_sa_shift = OMAP4430_SA_VDD_CORE_L_0_6_SHIFT,
 	.smps_sa_mask = OMAP4430_SA_VDD_CORE_L_0_6_MASK,
diff --git a/arch/arm/mach-omap2/vp44xx_data.c
b/arch/arm/mach-omap2/vp44xx_data.c
index 7b26f75..65d1ad6 100644
--- a/arch/arm/mach-omap2/vp44xx_data.c
+++ b/arch/arm/mach-omap2/vp44xx_data.c
@@ -31,7 +31,7 @@
  * VP data common to 44xx chips
  * XXX This stuff presumably belongs in the vp44xx.c or vp.c file.
  */
-static const struct omap_vp_common_data omap4_vp_data = {
+static const struct omap_vp_common_data omap4_vp_common = {
 	.vpconfig_erroroffset_shift = OMAP4430_ERROROFFSET_SHIFT,
 	.vpconfig_errorgain_mask = OMAP4430_ERRORGAIN_MASK,
 	.vpconfig_errorgain_shift = OMAP4430_ERRORGAIN_SHIFT,
@@ -56,6 +56,7 @@ static const struct omap_vp_prm_irqst_data
omap4_vp_mpu_prm_irqst_data = {
 };

 struct omap_vp_instance_data omap4_vp_mpu_data = {
+	.vp_common = &omap4_vp_common,
 	.vpconfig = OMAP4_PRM_VP_MPU_CONFIG_OFFSET,
 	.vstepmin = OMAP4_PRM_VP_MPU_VSTEPMIN_OFFSET,
 	.vstepmax = OMAP4_PRM_VP_MPU_VSTEPMAX_OFFSET,
@@ -71,6 +72,7 @@ static const struct omap_vp_prm_irqst_data
omap4_vp_iva_prm_irqst_data = {
 };

 struct omap_vp_instance_data omap4_vp_iva_data = {
+	.vp_common = &omap4_vp_common,
 	.vpconfig = OMAP4_PRM_VP_IVA_CONFIG_OFFSET,
 	.vstepmin = OMAP4_PRM_VP_IVA_VSTEPMIN_OFFSET,
 	.vstepmax = OMAP4_PRM_VP_IVA_VSTEPMAX_OFFSET,
@@ -86,6 +88,7 @@ static const struct omap_vp_prm_irqst_data
omap4_vp_core_prm_irqst_data = {
 };

 struct omap_vp_instance_data omap4_vp_core_data = {
+	.vp_common = &omap4_vp_common,
 	.vpconfig = OMAP4_PRM_VP_CORE_CONFIG_OFFSET,
 	.vstepmin = OMAP4_PRM_VP_CORE_VSTEPMIN_OFFSET,
 	.vstepmax = OMAP4_PRM_VP_CORE_VSTEPMAX_OFFSET,
-- 
1.7.0.4

>
> This series is available from git://git.pwsan.com/linux-2.6 in the
> 'voltage_split_2.6.39' branch.
>
>
> - Paul
>
>
> ---
>
> voltage_split_2.6.39
>    text	   data	    bss	    dec	    hex	filename
> 5766071	 488104	5596920	11851095	 b4d557
vmlinux.omap2plus_defconfig.orig
> 5765631	 487848	5596920	11850399	 b4d29f
vmlinux.omap2plus_defconfig
>
>
> Paul Walmsley (3):
>       OMAP: smartreflex: move plat/smartreflex.h to
mach-omap2/smartreflex.h
>       OMAP: voltage: move plat/voltage.h to mach-omap2/voltage.h
>       OMAP2+: voltage: reorganize, split code from data
>
>
>  arch/arm/mach-omap2/Makefile                  |   20
>  arch/arm/mach-omap2/omap_hwmod_3xxx_data.c    |    2
>  arch/arm/mach-omap2/omap_opp_data.h           |   12
>  arch/arm/mach-omap2/omap_twl.c                |    2
>  arch/arm/mach-omap2/opp3xxx_data.c            |   44 +
>  arch/arm/mach-omap2/opp4xxx_data.c            |   30 +
>  arch/arm/mach-omap2/pm.c                      |    2
>  arch/arm/mach-omap2/smartreflex-class3.c      |    2
>  arch/arm/mach-omap2/smartreflex.c             |    2
>  arch/arm/mach-omap2/smartreflex.h             |    3
>  arch/arm/mach-omap2/sr_device.c               |    4
>  arch/arm/mach-omap2/vc.h                      |   83 ++
>  arch/arm/mach-omap2/vc3xxx_data.c             |   63 ++
>  arch/arm/mach-omap2/vc44xx_data.c             |   72 ++
>  arch/arm/mach-omap2/voltage.c                 | 1019
+++++++------------------
>  arch/arm/mach-omap2/voltage.h                 |   66 ++
>  arch/arm/mach-omap2/voltagedomains3xxx_data.c |  104 +++
>  arch/arm/mach-omap2/voltagedomains44xx_data.c |  108 +++
>  arch/arm/mach-omap2/vp.h                      |  143 ++++
>  arch/arm/mach-omap2/vp3xxx_data.c             |   82 ++
>  arch/arm/mach-omap2/vp44xx_data.c             |   97 ++
>  arch/arm/plat-omap/include/plat/omap_hwmod.h  |    1
>  22 files changed, 1203 insertions(+), 758 deletions(-)
>  rename arch/arm/{plat-omap/include/plat/smartreflex.h =>
mach-omap2/smartreflex.h} (99%)
>  create mode 100644 arch/arm/mach-omap2/vc.h
>  create mode 100644 arch/arm/mach-omap2/vc3xxx_data.c
>  create mode 100644 arch/arm/mach-omap2/vc44xx_data.c
>  rename arch/arm/{plat-omap/include/plat/voltage.h =>
mach-omap2/voltage.h} (68%)
>  create mode 100644 arch/arm/mach-omap2/voltagedomains3xxx_data.c
>  create mode 100644 arch/arm/mach-omap2/voltagedomains44xx_data.c
>  create mode 100644 arch/arm/mach-omap2/vp.h
>  create mode 100644 arch/arm/mach-omap2/vp3xxx_data.c
>  create mode 100644 arch/arm/mach-omap2/vp44xx_data.c
>
>
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

[-- Attachment #2: 0001-OMAP4-voltage-Populate-missing-.vp-.vc_common-pointe.patch --]
[-- Type: application/octet-stream, Size: 4026 bytes --]

From e3d5e2bb09ecb7a958c1f79b86d1917f0becb8d2 Mon Sep 17 00:00:00 2001
From: Rajendra Nayak <rnayak@ti.com>
Date: Thu, 24 Feb 2011 16:42:25 +0530
Subject: [PATCH] OMAP4: voltage: Populate missing .vp/.vc_common pointers

The common_data for vp and vc on OMAP4 is defined
but not hooked up with the corresponding
vp/vc_data.
This causes an abort at bootup on OMAP4, as the
framework api's assumes these to be present.

While here, also rename omap4_vp_data to
omap4_vp_common and omap4_vc_data to
omap4_vc_common to maintain consistency in
naming structs across all OMAPs.

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
---
 arch/arm/mach-omap2/vc44xx_data.c |    5 ++++-
 arch/arm/mach-omap2/vp44xx_data.c |    5 ++++-
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/arch/arm/mach-omap2/vc44xx_data.c b/arch/arm/mach-omap2/vc44xx_data.c
index 548cb06..a98da8d 100644
--- a/arch/arm/mach-omap2/vc44xx_data.c
+++ b/arch/arm/mach-omap2/vc44xx_data.c
@@ -30,7 +30,7 @@
  * VC data common to 44xx chips
  * XXX This stuff presumably belongs in the vc3xxx.c or vc.c file.
  */
-static const struct omap_vc_common_data omap4_vc_data = {
+static const struct omap_vc_common_data omap4_vc_common = {
 	.smps_sa_reg = OMAP4_PRM_VC_SMPS_SA_OFFSET,
 	.smps_volra_reg = OMAP4_PRM_VC_VAL_SMPS_RA_VOL_OFFSET,
 	.bypass_val_reg = OMAP4_PRM_VC_VAL_BYPASS_OFFSET,
@@ -47,6 +47,7 @@ static const struct omap_vc_common_data omap4_vc_data = {
 
 /* VC instance data for each controllable voltage line */
 struct omap_vc_instance_data omap4_vc_mpu_data = {
+	.vc_common = &omap4_vc_common,
 	.cmdval_reg = OMAP4_PRM_VC_VAL_CMD_VDD_MPU_L_OFFSET,
 	.smps_sa_shift = OMAP4430_SA_VDD_MPU_L_PRM_VC_SMPS_SA_SHIFT,
 	.smps_sa_mask = OMAP4430_SA_VDD_MPU_L_PRM_VC_SMPS_SA_MASK,
@@ -55,6 +56,7 @@ struct omap_vc_instance_data omap4_vc_mpu_data = {
 };
 
 struct omap_vc_instance_data omap4_vc_iva_data = {
+	.vc_common = &omap4_vc_common,
 	.cmdval_reg = OMAP4_PRM_VC_VAL_CMD_VDD_IVA_L_OFFSET,
 	.smps_sa_shift = OMAP4430_SA_VDD_IVA_L_PRM_VC_SMPS_SA_SHIFT,
 	.smps_sa_mask = OMAP4430_SA_VDD_IVA_L_PRM_VC_SMPS_SA_MASK,
@@ -63,6 +65,7 @@ struct omap_vc_instance_data omap4_vc_iva_data = {
 };
 
 struct omap_vc_instance_data omap4_vc_core_data = {
+	.vc_common = &omap4_vc_common,
 	.cmdval_reg = OMAP4_PRM_VC_VAL_CMD_VDD_CORE_L_OFFSET,
 	.smps_sa_shift = OMAP4430_SA_VDD_CORE_L_0_6_SHIFT,
 	.smps_sa_mask = OMAP4430_SA_VDD_CORE_L_0_6_MASK,
diff --git a/arch/arm/mach-omap2/vp44xx_data.c b/arch/arm/mach-omap2/vp44xx_data.c
index 7b26f75..65d1ad6 100644
--- a/arch/arm/mach-omap2/vp44xx_data.c
+++ b/arch/arm/mach-omap2/vp44xx_data.c
@@ -31,7 +31,7 @@
  * VP data common to 44xx chips
  * XXX This stuff presumably belongs in the vp44xx.c or vp.c file.
  */
-static const struct omap_vp_common_data omap4_vp_data = {
+static const struct omap_vp_common_data omap4_vp_common = {
 	.vpconfig_erroroffset_shift = OMAP4430_ERROROFFSET_SHIFT,
 	.vpconfig_errorgain_mask = OMAP4430_ERRORGAIN_MASK,
 	.vpconfig_errorgain_shift = OMAP4430_ERRORGAIN_SHIFT,
@@ -56,6 +56,7 @@ static const struct omap_vp_prm_irqst_data omap4_vp_mpu_prm_irqst_data = {
 };
 
 struct omap_vp_instance_data omap4_vp_mpu_data = {
+	.vp_common = &omap4_vp_common,
 	.vpconfig = OMAP4_PRM_VP_MPU_CONFIG_OFFSET,
 	.vstepmin = OMAP4_PRM_VP_MPU_VSTEPMIN_OFFSET,
 	.vstepmax = OMAP4_PRM_VP_MPU_VSTEPMAX_OFFSET,
@@ -71,6 +72,7 @@ static const struct omap_vp_prm_irqst_data omap4_vp_iva_prm_irqst_data = {
 };
 
 struct omap_vp_instance_data omap4_vp_iva_data = {
+	.vp_common = &omap4_vp_common,
 	.vpconfig = OMAP4_PRM_VP_IVA_CONFIG_OFFSET,
 	.vstepmin = OMAP4_PRM_VP_IVA_VSTEPMIN_OFFSET,
 	.vstepmax = OMAP4_PRM_VP_IVA_VSTEPMAX_OFFSET,
@@ -86,6 +88,7 @@ static const struct omap_vp_prm_irqst_data omap4_vp_core_prm_irqst_data = {
 };
 
 struct omap_vp_instance_data omap4_vp_core_data = {
+	.vp_common = &omap4_vp_common,
 	.vpconfig = OMAP4_PRM_VP_CORE_CONFIG_OFFSET,
 	.vstepmin = OMAP4_PRM_VP_CORE_VSTEPMIN_OFFSET,
 	.vstepmax = OMAP4_PRM_VP_CORE_VSTEPMAX_OFFSET,
-- 
1.7.0.4


  parent reply	other threads:[~2011-02-24 11:58 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-21  2:08 [PATCH 0/3] OMAP2+: voltage: first pass at cleanup/reorganization Paul Walmsley
2011-02-21  2:08 ` [PATCH 1/3] OMAP: smartreflex: move plat/smartreflex.h to mach-omap2/smartreflex.h Paul Walmsley
2011-02-21  9:55   ` Cousson, Benoit
2011-02-21 18:08     ` Paul Walmsley
2011-02-21  2:08 ` [PATCH 2/3] OMAP: voltage: move plat/voltage.h to mach-omap2/voltage.h Paul Walmsley
2011-02-21  4:51   ` Gulati, Shweta
2011-02-21  2:08 ` [PATCH 3/3] OMAP2+: voltage: reorganize, split code from data Paul Walmsley
2011-02-21  7:59   ` Gulati, Shweta
2011-02-21 18:53     ` Paul Walmsley
2011-02-21 19:00   ` Paul Walmsley
2011-02-24 11:57 ` Rajendra Nayak [this message]
2011-02-25  5:03   ` [PATCH 0/3] OMAP2+: voltage: first pass at cleanup/reorganization Paul Walmsley
2011-02-25  5:32     ` Rajendra Nayak
2011-02-25 21:42       ` Paul Walmsley

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=553cd99ec29ee91e4a4b324d0f4a0be7@mail.gmail.com \
    --to=rnayak@ti.com \
    --cc=b-cousson@ti.com \
    --cc=khilman@ti.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=mturquette@ti.com \
    --cc=nm@ti.com \
    --cc=paul@pwsan.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox