OMAP4: Fix -EINVAL for vana, vcxio, vdac
authorBalaji T K <balajitk@ti.com>
Mon, 7 Feb 2011 15:29:59 +0000 (20:59 +0530)
committerTony Lindgren <tony@atomide.com>
Tue, 22 Feb 2011 16:37:03 +0000 (08:37 -0800)
Fixed regulators in twl6030 do not have set_voltage hook.
Regulator core returns -22 if set_voltage is NULL and apply_uV is set
while applying the constraint to set voltage resulting in failure during probe
of these regulators.
Do not set apply_uV for fixed regulators which don't have set_voltage.

machine_constraints_voltage: VANA: failed to apply 2100000uV constraint
twl_reg twl_reg.43: can't register VANA, -22
twl_reg: probe of twl_reg.43 failed with error -22
machine_constraints_voltage: VCXIO: failed to apply 1800000uV constraint
twl_reg twl_reg.44: can't register VCXIO, -22
twl_reg: probe of twl_reg.44 failed with error -22
machine_constraints_voltage: VDAC: failed to apply 1800000uV constraint
twl_reg twl_reg.45: can't register VDAC, -22
twl_reg: probe of twl_reg.45 failed with error -22

Signed-off-by: Balaji T K <balajitk@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
arch/arm/mach-omap2/board-4430sdp.c
arch/arm/mach-omap2/board-omap4panda.c

index 12d99e582cd651864b289ed70df1131191f5a488..27d9583811c225d36ccf362fb9874d246ebda874 100644 (file)
@@ -433,7 +433,6 @@ static struct regulator_init_data sdp4430_vana = {
        .constraints = {
                .min_uV                 = 2100000,
                .max_uV                 = 2100000,
-               .apply_uV               = true,
                .valid_modes_mask       = REGULATOR_MODE_NORMAL
                                        | REGULATOR_MODE_STANDBY,
                .valid_ops_mask  = REGULATOR_CHANGE_MODE
@@ -445,7 +444,6 @@ static struct regulator_init_data sdp4430_vcxio = {
        .constraints = {
                .min_uV                 = 1800000,
                .max_uV                 = 1800000,
-               .apply_uV               = true,
                .valid_modes_mask       = REGULATOR_MODE_NORMAL
                                        | REGULATOR_MODE_STANDBY,
                .valid_ops_mask  = REGULATOR_CHANGE_MODE
@@ -457,7 +455,6 @@ static struct regulator_init_data sdp4430_vdac = {
        .constraints = {
                .min_uV                 = 1800000,
                .max_uV                 = 1800000,
-               .apply_uV               = true,
                .valid_modes_mask       = REGULATOR_MODE_NORMAL
                                        | REGULATOR_MODE_STANDBY,
                .valid_ops_mask  = REGULATOR_CHANGE_MODE
index fca5b9e80c18e701bbd11546a9f111b53c1af0cf..220d3b85431beb02a406a088938b411a46050ecd 100644 (file)
@@ -304,7 +304,6 @@ static struct regulator_init_data omap4_panda_vana = {
        .constraints = {
                .min_uV                 = 2100000,
                .max_uV                 = 2100000,
-               .apply_uV               = true,
                .valid_modes_mask       = REGULATOR_MODE_NORMAL
                                        | REGULATOR_MODE_STANDBY,
                .valid_ops_mask  = REGULATOR_CHANGE_MODE
@@ -316,7 +315,6 @@ static struct regulator_init_data omap4_panda_vcxio = {
        .constraints = {
                .min_uV                 = 1800000,
                .max_uV                 = 1800000,
-               .apply_uV               = true,
                .valid_modes_mask       = REGULATOR_MODE_NORMAL
                                        | REGULATOR_MODE_STANDBY,
                .valid_ops_mask  = REGULATOR_CHANGE_MODE
@@ -328,7 +326,6 @@ static struct regulator_init_data omap4_panda_vdac = {
        .constraints = {
                .min_uV                 = 1800000,
                .max_uV                 = 1800000,
-               .apply_uV               = true,
                .valid_modes_mask       = REGULATOR_MODE_NORMAL
                                        | REGULATOR_MODE_STANDBY,
                .valid_ops_mask  = REGULATOR_CHANGE_MODE