[PATCH v2 3/7] regulator: rk808: Migrate to regulator core's simplified DT parsing code

Mark Brown broonie at kernel.org
Thu Apr 21 09:01:20 PDT 2016


On Thu, Apr 21, 2016 at 03:12:37PM +0200, Wadim Egorov wrote:

> +static int rk808_set_suspend_voltage(struct regulator_dev *rdev, int uv)
> +{
> +	unsigned int reg;
> +	int sel = regulator_map_voltage_linear(rdev, uv, uv);
> +
> +	if (sel < 0)
> +		return -EINVAL;
> +
> +	reg = rdev->desc->vsel_reg + RK808_SLP_REG_OFFSET;
> +
> +	return regmap_update_bits(rdev->regmap, reg,
> +				  rdev->desc->vsel_mask,
> +				  sel);
> +}

This is fine but is adding a new feature and not part of the refactoring
that the changelog talked about so should be in a separate commit.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-rockchip/attachments/20160421/a645cde7/attachment.sig>


More information about the Linux-rockchip mailing list