RE: [PATCH 0/3] OMAP2+: voltage: first pass at cleanup/reorganization

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Paul,

> -----Original Message-----
> From: linux-arm-kernel-bounces@xxxxxxxxxxxxxxxxxxx
[mailto:linux-arm-kernel-bounces@xxxxxxxxxxxxxxxxxxx] On Behalf
> Of Paul Walmsley
> Sent: Monday, February 21, 2011 7:39 AM
> To: linux-omap@xxxxxxxxxxxxxxx; linux-arm-kernel@xxxxxxxxxxxxxxxxxxx
> Cc: khilman@xxxxxx; nm@xxxxxx; b-cousson@xxxxxx; mturquette@xxxxxx
> 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@xxxxxx>
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@xxxxxx>
---
 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@xxxxxxxxxxxxxxxxxxx
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

Attachment: 0001-OMAP4-voltage-Populate-missing-.vp-.vc_common-pointe.patch
Description: Binary data


[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux