summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2011-08-30 15:02:18 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2011-08-30 15:02:18 -0700
commit82488756573f5089955d605d3b1eb76d75a6f61b (patch)
tree30ac3ece43aa2499b99ee81bc012fbf4699791f5
parentaa860198da73375bbdfa0be997b5d77352e098b6 (diff)
downloadstable-queue-82488756573f5089955d605d3b1eb76d75a6f61b.tar.gz
3.0 patches
-rw-r--r--queue-3.0/regulator-tps65910-add-missing-breaks-in-switch-case.patch50
-rw-r--r--queue-3.0/series1
2 files changed, 51 insertions, 0 deletions
diff --git a/queue-3.0/regulator-tps65910-add-missing-breaks-in-switch-case.patch b/queue-3.0/regulator-tps65910-add-missing-breaks-in-switch-case.patch
new file mode 100644
index 0000000000..68f44d7fd0
--- /dev/null
+++ b/queue-3.0/regulator-tps65910-add-missing-breaks-in-switch-case.patch
@@ -0,0 +1,50 @@
+From d04156bca629740a661fd0738cd69ba1f08b2b20 Mon Sep 17 00:00:00 2001
+From: Axel Lin <axel.lin@gmail.com>
+Date: Sun, 10 Jul 2011 21:44:09 +0800
+Subject: regulator: tps65910: Add missing breaks in switch/case
+
+From: Axel Lin <axel.lin@gmail.com>
+
+commit d04156bca629740a661fd0738cd69ba1f08b2b20 upstream.
+
+Also add a default case in tps65910_list_voltage_dcdc to silence
+'volt' may be used uninitialized in this function warning.
+
+Signed-off-by: Axel Lin <axel.lin@gmail.com>
+Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
+Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
+Cc: Johan Hovold <jhovold@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/regulator/tps65910-regulator.c | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+--- a/drivers/regulator/tps65910-regulator.c
++++ b/drivers/regulator/tps65910-regulator.c
+@@ -759,8 +759,13 @@ static int tps65910_list_voltage_dcdc(st
+ mult = (selector / VDD1_2_NUM_VOLTS) + 1;
+ volt = VDD1_2_MIN_VOLT +
+ (selector % VDD1_2_NUM_VOLTS) * VDD1_2_OFFSET;
++ break;
+ case TPS65911_REG_VDDCTRL:
+ volt = VDDCTRL_MIN_VOLT + (selector * VDDCTRL_OFFSET);
++ break;
++ default:
++ BUG();
++ return -EINVAL;
+ }
+
+ return volt * 100 * mult;
+@@ -898,9 +903,11 @@ static __devinit int tps65910_probe(stru
+ case TPS65910:
+ pmic->get_ctrl_reg = &tps65910_get_ctrl_register;
+ info = tps65910_regs;
++ break;
+ case TPS65911:
+ pmic->get_ctrl_reg = &tps65911_get_ctrl_register;
+ info = tps65911_regs;
++ break;
+ default:
+ pr_err("Invalid tps chip version\n");
+ return -ENODEV;
diff --git a/queue-3.0/series b/queue-3.0/series
index 4ce67dc173..1c0a3610e8 100644
--- a/queue-3.0/series
+++ b/queue-3.0/series
@@ -43,3 +43,4 @@ sparc-allow-handling-signals-when-stack-is-corrupted.patch
sparc64-set-have_c_recordmcount.patch
sparc-fix-array-bounds-error-setting-up-pcic-nmi-trap.patch
sparc32-sun4d-change-ipi-irq-level-to-prevent-collision.patch
+regulator-tps65910-add-missing-breaks-in-switch-case.patch