lkml.org 
[lkml]   [2017]   [Apr]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 4/4] regulator: Add ROHM BD9571MWV-M PMIC regulator driver
On Sun, Apr 16, 2017 at 08:08:01PM +0200, Marek Vasut wrote:

This looks good, a couple of minor things though:

> +static int bd9571mwv_regulator_is_enabled(struct regulator_dev *reg)
> +{
> + /* Always enabled. */
> + return 1;
> +}

This should be the default implementation, no need to open code it.

> +int bd9571mwv_set_voltage_sel_regmap(struct regulator_dev *rdev,
> + unsigned int sel)
> +{
> + return regmap_write_bits(rdev->regmap, BD9571MWV_DVFS_SETVID,
> + rdev->desc->vsel_mask, sel);
> +}

regulator_set_voltage_sel_regmap().
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2017-04-18 19:58    [W:0.040 / U:0.200 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site