Merge remote-tracking branch 'regulator/topic/change' into regulator-next
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Tue, 11 Dec 2012 12:44:53 +0000 (21:44 +0900)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Tue, 11 Dec 2012 12:44:53 +0000 (21:44 +0900)
drivers/regulator/core.c

index cd1b201c91e2e8faacff620a5686f9efd9dc9ddf..0f65b246cc0c8d24c559cdeafd340232d1c55e0c 100644 (file)
@@ -1886,7 +1886,7 @@ int regulator_can_change_voltage(struct regulator *regulator)
 
        if (rdev->constraints &&
            rdev->constraints->valid_ops_mask & REGULATOR_CHANGE_VOLTAGE &&
-           rdev->desc->n_voltages > 1)
+           (rdev->desc->n_voltages - rdev->desc->linear_min_sel) > 1)
                return 1;
 
        return 0;