diff options
author | 2021-01-21 08:18:13 +0100 | |
---|---|---|
committer | 2021-01-26 18:52:54 +0100 | |
commit | 54f1155af6851ef683067827302eaafe8422fe1b (patch) | |
tree | ed164a3d3597998d28377f9715908d5378daf332 /drivers/staging/hikey9xx | |
parent | staging: hikey9xx: hi6421v600-regulator: fix delay logic (diff) | |
download | linux-54f1155af6851ef683067827302eaafe8422fe1b.tar.gz linux-54f1155af6851ef683067827302eaafe8422fe1b.tar.bz2 linux-54f1155af6851ef683067827302eaafe8422fe1b.zip |
staging: hikey9xx: hi6421v600-regulator: cleanup comments
Remove obvious comments and fix the comment for the
HI6421V600_LDO() macro.
While on it, use kernel-doc notation for HI6421V600_LDO(),
as kernel-doc can check if the arguments match its
description.
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Link: https://lore.kernel.org/r/d5e6dbdee5f7e143300249251ddbe09fdf64e669.1611212783.git.mchehab+huawei@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/hikey9xx')
-rw-r--r-- | drivers/staging/hikey9xx/hi6421v600-regulator.c | 27 |
1 files changed, 11 insertions, 16 deletions
diff --git a/drivers/staging/hikey9xx/hi6421v600-regulator.c b/drivers/staging/hikey9xx/hi6421v600-regulator.c index e5a492ee7121..9f096d4e46db 100644 --- a/drivers/staging/hikey9xx/hi6421v600-regulator.c +++ b/drivers/staging/hikey9xx/hi6421v600-regulator.c @@ -57,17 +57,17 @@ static const unsigned int ldo34_voltages[] = { 3000000, 3100000, 3200000, 3300000 }; -/* - * _id - LDO id name string - * _match - of match name string - * v_table - voltage table - * vreg - voltage select register - * vmask - voltage select mask - * ereg - enable register - * emask - enable mask - * odelay - off/on delay time in uS - * ecomask - eco mode mask - * ecoamp - eco mode load uppler limit in uA +/** + * HI6421V600_LDO() - specify a LDO power line + * @_id: LDO id name string + * @vtable: voltage table + * @ereg: enable register + * @emask: enable mask + * @vreg: voltage select register + * @odelay: off/on delay time in uS + * @etime: enable time in uS + * @ecomask: eco mode mask + * @ecoamp: eco mode load uppler limit in uA */ #define HI6421V600_LDO(_id, vtable, ereg, emask, vreg, \ odelay, etime, ecomask, ecoamp) \ @@ -114,7 +114,6 @@ static int hi6421_spmi_regulator_enable(struct regulator_dev *rdev) /* cannot enable more than one regulator at one time */ mutex_lock(&sreg->enable_mutex); - /* set enable register */ ret = hi6421_spmi_pmic_rmw(pmic, rdev->desc->enable_reg, rdev->desc->enable_mask, rdev->desc->enable_mask); @@ -132,7 +131,6 @@ static int hi6421_spmi_regulator_disable(struct regulator_dev *rdev) struct hi6421_spmi_reg_info *sreg = rdev_get_drvdata(rdev); struct hi6421_spmi_pmic *pmic = sreg->pmic; - /* set enable register to 0 */ return hi6421_spmi_pmic_rmw(pmic, rdev->desc->enable_reg, rdev->desc->enable_mask, 0); } @@ -143,7 +141,6 @@ static int hi6421_spmi_regulator_get_voltage_sel(struct regulator_dev *rdev) struct hi6421_spmi_pmic *pmic = sreg->pmic; u32 reg_val; - /* get voltage selector */ reg_val = hi6421_spmi_pmic_read(pmic, rdev->desc->vsel_reg); return (reg_val & rdev->desc->vsel_mask) >> (ffs(rdev->desc->vsel_mask) - 1); @@ -198,7 +195,6 @@ static int hi6421_spmi_regulator_set_mode(struct regulator_dev *rdev, return -EINVAL; } - /* set mode */ return hi6421_spmi_pmic_rmw(pmic, rdev->desc->enable_reg, sreg->eco_mode_mask, val); } @@ -304,7 +300,6 @@ static int hi6421_spmi_regulator_probe(struct platform_device *pdev) mutex_init(&sreg->enable_mutex); for (i = 0; i < ARRAY_SIZE(regulator_info); i++) { - /* assign per-regulator data */ info = ®ulator_info[i]; config.dev = pdev->dev.parent; |