Skip to content

Commit c15d5a6

Browse files
AxelLinbroonie
authored andcommitted
regulator: da9062: Return REGULATOR_MODE_INVALID for invalid mode
-EINVAL is not a valid return value for .of_map_mode, return REGULATOR_MODE_INVALID instead. Fixes: 844e749 ("regulator: da9062: add of_map_mode support for bucks") Signed-off-by: Axel Lin <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
1 parent 76bec25 commit c15d5a6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/regulator/da9062-regulator.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ static unsigned int da9062_map_buck_mode(unsigned int mode)
108108
case DA9063_BUCK_MODE_AUTO:
109109
return REGULATOR_MODE_NORMAL;
110110
default:
111-
return -EINVAL;
111+
return REGULATOR_MODE_INVALID;
112112
}
113113
}
114114

0 commit comments

Comments
 (0)