diff options
| author | Emmanuel Vadot <manu@FreeBSD.org> | 2020-06-16 20:41:59 +0000 |
|---|---|---|
| committer | Emmanuel Vadot <manu@FreeBSD.org> | 2020-06-16 20:41:59 +0000 |
| commit | b5863da9094ed1f6a6ffcf010223b584eab42b7e (patch) | |
| tree | a3aef30311f9e99d5b3682a33639d2ed31270f2e /sys/dev/extres | |
| parent | 602810b5f557fecbf38003662f2dc4abe933a59b (diff) | |
Notes
Diffstat (limited to 'sys/dev/extres')
| -rw-r--r-- | sys/dev/extres/regulator/regulator.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/dev/extres/regulator/regulator.c b/sys/dev/extres/regulator/regulator.c index f5ca5d1240dc..7d74df2ada43 100644 --- a/sys/dev/extres/regulator/regulator.c +++ b/sys/dev/extres/regulator/regulator.c @@ -295,8 +295,9 @@ static int regnode_method_get_voltage(struct regnode *regnode, int *uvolt) { - return (regnode->std_param.min_uvolt + - (regnode->std_param.max_uvolt - regnode->std_param.min_uvolt) / 2); + *uvolt = regnode->std_param.min_uvolt + + (regnode->std_param.max_uvolt - regnode->std_param.min_uvolt) / 2; + return (0); } int |
