diff --git a/[refs] b/[refs] index 2f2bad588adf..1283d90a012c 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 39aa9b6e3cb1b2a564d3422eedb7f725179162d3 +refs/heads/master: 89f425ed5bf3d4fd97e840296dccd75b8e0fe4c9 diff --git a/trunk/drivers/regulator/core.c b/trunk/drivers/regulator/core.c index f59821f10fdc..3700d0953d73 100644 --- a/trunk/drivers/regulator/core.c +++ b/trunk/drivers/regulator/core.c @@ -151,8 +151,11 @@ static int regulator_check_voltage(struct regulator_dev *rdev, if (*min_uV < rdev->constraints->min_uV) *min_uV = rdev->constraints->min_uV; - if (*min_uV > *max_uV) + if (*min_uV > *max_uV) { + rdev_err(rdev, "unsupportable voltage range: %d-%duV\n", + min_uV, max_uV); return -EINVAL; + } return 0; } @@ -205,8 +208,11 @@ static int regulator_check_current_limit(struct regulator_dev *rdev, if (*min_uA < rdev->constraints->min_uA) *min_uA = rdev->constraints->min_uA; - if (*min_uA > *max_uA) + if (*min_uA > *max_uA) { + rdev_err(rdev, "unsupportable current range: %d-%duA\n", + min_uA, max_uA); return -EINVAL; + } return 0; } @@ -221,6 +227,7 @@ static int regulator_mode_constrain(struct regulator_dev *rdev, int *mode) case REGULATOR_MODE_STANDBY: break; default: + rdev_err(rdev, "invalid mode %x specified\n", *mode); return -EINVAL; }