aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
diff options
context:
space:
mode:
authorShweta Gulati <shweta.gulati@ti.com>2012-02-29 17:33:37 -0500
committerKevin Hilman <khilman@ti.com>2012-03-05 14:29:25 -0500
commitcea6b942124683305280962969599fed36f0ea7e (patch)
tree75cee3814d28131230343d2990335bcff4d515cd /arch/arm/mach-omap2/omap_hwmod_44xx_data.c
parent149f1d5c8d2fd6879cdf93ca70f1cb745e698a1e (diff)
ARM: OMAP3+: SmartReflex: use voltage domain name in device attributes
To set sr ntarget values for all volt_domain, volt_table is retrieved by doing a look_up of 'vdd_name' field from omap_hwmod but voltage domain pointer does not belong to omap_hwmod and is not used anywhere else. As a part of voltage layer and SR Layer clean up volt pointer is removed from omap_hwmod and added in dev attributes of SR. The value of the field must match the voltage domain names for the binding to be effective. Tested on OMAP3630 SDP, OMAP3530 Beagleboard and OMAP4430 SDP Board. Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Shweta Gulati <shweta.gulati@ti.com> Acked by: Nishanth Menon <nm@ti.com> Cc: Benoit Cousson <b-cousson@ti.com> Cc: Paul Walmsley <paul@pwsan.com> Signed-off-by: Jean Pihet <j-pihet@ti.com> Reviewed-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Kevin Hilman <khilman@ti.com>
Diffstat (limited to 'arch/arm/mach-omap2/omap_hwmod_44xx_data.c')
-rw-r--r--arch/arm/mach-omap2/omap_hwmod_44xx_data.c19
1 files changed, 16 insertions, 3 deletions
diff --git a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
index ef0524c10a84..ee3624bd1996 100644
--- a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
@@ -34,6 +34,7 @@
34 34
35#include "omap_hwmod_common_data.h" 35#include "omap_hwmod_common_data.h"
36 36
37#include "smartreflex.h"
37#include "cm1_44xx.h" 38#include "cm1_44xx.h"
38#include "cm2_44xx.h" 39#include "cm2_44xx.h"
39#include "prm44xx.h" 40#include "prm44xx.h"
@@ -3963,6 +3964,10 @@ static struct omap_hwmod_class omap44xx_smartreflex_hwmod_class = {
3963}; 3964};
3964 3965
3965/* smartreflex_core */ 3966/* smartreflex_core */
3967static struct omap_smartreflex_dev_attr smartreflex_core_dev_attr = {
3968 .sensor_voltdm_name = "core",
3969};
3970
3966static struct omap_hwmod omap44xx_smartreflex_core_hwmod; 3971static struct omap_hwmod omap44xx_smartreflex_core_hwmod;
3967static struct omap_hwmod_irq_info omap44xx_smartreflex_core_irqs[] = { 3972static struct omap_hwmod_irq_info omap44xx_smartreflex_core_irqs[] = {
3968 { .irq = 19 + OMAP44XX_IRQ_GIC_START }, 3973 { .irq = 19 + OMAP44XX_IRQ_GIC_START },
@@ -3999,7 +4004,6 @@ static struct omap_hwmod omap44xx_smartreflex_core_hwmod = {
3999 .mpu_irqs = omap44xx_smartreflex_core_irqs, 4004 .mpu_irqs = omap44xx_smartreflex_core_irqs,
4000 4005
4001 .main_clk = "smartreflex_core_fck", 4006 .main_clk = "smartreflex_core_fck",
4002 .vdd_name = "core",
4003 .prcm = { 4007 .prcm = {
4004 .omap4 = { 4008 .omap4 = {
4005 .clkctrl_offs = OMAP4_CM_ALWON_SR_CORE_CLKCTRL_OFFSET, 4009 .clkctrl_offs = OMAP4_CM_ALWON_SR_CORE_CLKCTRL_OFFSET,
@@ -4009,9 +4013,14 @@ static struct omap_hwmod omap44xx_smartreflex_core_hwmod = {
4009 }, 4013 },
4010 .slaves = omap44xx_smartreflex_core_slaves, 4014 .slaves = omap44xx_smartreflex_core_slaves,
4011 .slaves_cnt = ARRAY_SIZE(omap44xx_smartreflex_core_slaves), 4015 .slaves_cnt = ARRAY_SIZE(omap44xx_smartreflex_core_slaves),
4016 .dev_attr = &smartreflex_core_dev_attr,
4012}; 4017};
4013 4018
4014/* smartreflex_iva */ 4019/* smartreflex_iva */
4020static struct omap_smartreflex_dev_attr smartreflex_iva_dev_attr = {
4021 .sensor_voltdm_name = "iva",
4022};
4023
4015static struct omap_hwmod omap44xx_smartreflex_iva_hwmod; 4024static struct omap_hwmod omap44xx_smartreflex_iva_hwmod;
4016static struct omap_hwmod_irq_info omap44xx_smartreflex_iva_irqs[] = { 4025static struct omap_hwmod_irq_info omap44xx_smartreflex_iva_irqs[] = {
4017 { .irq = 102 + OMAP44XX_IRQ_GIC_START }, 4026 { .irq = 102 + OMAP44XX_IRQ_GIC_START },
@@ -4047,7 +4056,6 @@ static struct omap_hwmod omap44xx_smartreflex_iva_hwmod = {
4047 .clkdm_name = "l4_ao_clkdm", 4056 .clkdm_name = "l4_ao_clkdm",
4048 .mpu_irqs = omap44xx_smartreflex_iva_irqs, 4057 .mpu_irqs = omap44xx_smartreflex_iva_irqs,
4049 .main_clk = "smartreflex_iva_fck", 4058 .main_clk = "smartreflex_iva_fck",
4050 .vdd_name = "iva",
4051 .prcm = { 4059 .prcm = {
4052 .omap4 = { 4060 .omap4 = {
4053 .clkctrl_offs = OMAP4_CM_ALWON_SR_IVA_CLKCTRL_OFFSET, 4061 .clkctrl_offs = OMAP4_CM_ALWON_SR_IVA_CLKCTRL_OFFSET,
@@ -4057,9 +4065,14 @@ static struct omap_hwmod omap44xx_smartreflex_iva_hwmod = {
4057 }, 4065 },
4058 .slaves = omap44xx_smartreflex_iva_slaves, 4066 .slaves = omap44xx_smartreflex_iva_slaves,
4059 .slaves_cnt = ARRAY_SIZE(omap44xx_smartreflex_iva_slaves), 4067 .slaves_cnt = ARRAY_SIZE(omap44xx_smartreflex_iva_slaves),
4068 .dev_attr = &smartreflex_iva_dev_attr,
4060}; 4069};
4061 4070
4062/* smartreflex_mpu */ 4071/* smartreflex_mpu */
4072static struct omap_smartreflex_dev_attr smartreflex_mpu_dev_attr = {
4073 .sensor_voltdm_name = "mpu",
4074};
4075
4063static struct omap_hwmod omap44xx_smartreflex_mpu_hwmod; 4076static struct omap_hwmod omap44xx_smartreflex_mpu_hwmod;
4064static struct omap_hwmod_irq_info omap44xx_smartreflex_mpu_irqs[] = { 4077static struct omap_hwmod_irq_info omap44xx_smartreflex_mpu_irqs[] = {
4065 { .irq = 18 + OMAP44XX_IRQ_GIC_START }, 4078 { .irq = 18 + OMAP44XX_IRQ_GIC_START },
@@ -4095,7 +4108,6 @@ static struct omap_hwmod omap44xx_smartreflex_mpu_hwmod = {
4095 .clkdm_name = "l4_ao_clkdm", 4108 .clkdm_name = "l4_ao_clkdm",
4096 .mpu_irqs = omap44xx_smartreflex_mpu_irqs, 4109 .mpu_irqs = omap44xx_smartreflex_mpu_irqs,
4097 .main_clk = "smartreflex_mpu_fck", 4110 .main_clk = "smartreflex_mpu_fck",
4098 .vdd_name = "mpu",
4099 .prcm = { 4111 .prcm = {
4100 .omap4 = { 4112 .omap4 = {
4101 .clkctrl_offs = OMAP4_CM_ALWON_SR_MPU_CLKCTRL_OFFSET, 4113 .clkctrl_offs = OMAP4_CM_ALWON_SR_MPU_CLKCTRL_OFFSET,
@@ -4105,6 +4117,7 @@ static struct omap_hwmod omap44xx_smartreflex_mpu_hwmod = {
4105 }, 4117 },
4106 .slaves = omap44xx_smartreflex_mpu_slaves, 4118 .slaves = omap44xx_smartreflex_mpu_slaves,
4107 .slaves_cnt = ARRAY_SIZE(omap44xx_smartreflex_mpu_slaves), 4119 .slaves_cnt = ARRAY_SIZE(omap44xx_smartreflex_mpu_slaves),
4120 .dev_attr = &smartreflex_mpu_dev_attr,
4108}; 4121};
4109 4122
4110/* 4123/*