mirror of
https://git.codelinaro.org/clo/qsdk/oss/boot/u-boot-2016.git
synced 2025-12-10 07:44:53 +01:00
dm: pmic: Display the regulator limits on error
When a regulator command cannot honour the requested voltage, display the limits to try to be helpful. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Przemyslaw Marczak <p.marczak@samsung.com>
This commit is contained in:
parent
d08504d18a
commit
224d1ddcc5
1 changed files with 2 additions and 1 deletions
|
|
@ -241,7 +241,8 @@ static int do_value(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
|
||||||
|
|
||||||
value = simple_strtoul(argv[1], NULL, 0);
|
value = simple_strtoul(argv[1], NULL, 0);
|
||||||
if ((value < uc_pdata->min_uV || value > uc_pdata->max_uV) && !force) {
|
if ((value < uc_pdata->min_uV || value > uc_pdata->max_uV) && !force) {
|
||||||
printf("Value exceeds regulator constraint limits\n");
|
printf("Value exceeds regulator constraint limits %d..%d uV\n",
|
||||||
|
uc_pdata->min_uV, uc_pdata->max_uV);
|
||||||
return CMD_RET_FAILURE;
|
return CMD_RET_FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue