mirror of
https://xff.cz/git/u-boot/
synced 2025-09-01 00:32:04 +02:00
power: regulator: Introduce regulator_set_value_force function
In case we want to force a particular value on a regulator irrespective of the min/max constraints for testing purposes one can call regulator_set_value_force function. Signed-off-by: Keerthy <j-keerthy@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -292,7 +292,10 @@ static int do_value(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
|
||||
return CMD_RET_FAILURE;
|
||||
}
|
||||
|
||||
ret = regulator_set_value(dev, value);
|
||||
if (!force)
|
||||
ret = regulator_set_value(dev, value);
|
||||
else
|
||||
ret = regulator_set_value_force(dev, value);
|
||||
if (ret) {
|
||||
printf("Regulator: %s - can't set the Voltage!\n",
|
||||
uc_pdata->name);
|
||||
|
Reference in New Issue
Block a user