diff mbox series

[02/10] regulator: devres: Fix issues with kerneldoc headers

Message ID 20200625163614.4001403-3-lee.jones@linaro.org (mailing list archive)
State New, archived
Headers show
Series Fix a bunch of W=1 warnings in Regulator | expand

Commit Message

Lee Jones June 25, 2020, 4:36 p.m. UTC
Provide descriptions for some missing function args and
rename others to match the names used.

Fixes the following W=1 warning(s):

 drivers/regulator/devres.c:187: warning: Function parameter or member 'dev' not described in 'devm_regulator_register'
 drivers/regulator/devres.c:226: warning: Function parameter or member 'dev' not described in 'devm_regulator_unregister'
 drivers/regulator/devres.c:226: warning: Function parameter or member 'rdev' not described in 'devm_regulator_unregister'
 drivers/regulator/devres.c:226: warning: Excess function parameter 'regulator' description in 'devm_regulator_unregister'

Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/regulator/devres.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Comments

Mark Brown June 25, 2020, 5:28 p.m. UTC | #1
On Thu, Jun 25, 2020 at 05:36:06PM +0100, Lee Jones wrote:

>  /**
>   * devm_regulator_register - Resource managed regulator_register()
> + * @dev: device for regulator "consumer"
>   * @regulator_desc: regulator to register
>   * @config: runtime configuration for regulator
>   *

That's an odd style you're using in your "change" here - why the quotes?
Lee Jones June 25, 2020, 6:42 p.m. UTC | #2
On Thu, 25 Jun 2020, Mark Brown wrote:

> On Thu, Jun 25, 2020 at 05:36:06PM +0100, Lee Jones wrote:
> 
> >  /**
> >   * devm_regulator_register - Resource managed regulator_register()
> > + * @dev: device for regulator "consumer"
> >   * @regulator_desc: regulator to register
> >   * @config: runtime configuration for regulator
> >   *
> 
> That's an odd style you're using in your "change" here - why the quotes?

It's taken from other instances in the same file.
Mark Brown June 25, 2020, 6:45 p.m. UTC | #3
On Thu, Jun 25, 2020 at 07:42:18PM +0100, Lee Jones wrote:
> On Thu, 25 Jun 2020, Mark Brown wrote:
> > On Thu, Jun 25, 2020 at 05:36:06PM +0100, Lee Jones wrote:

> > > + * @dev: device for regulator "consumer"

> > That's an odd style you're using in your "change" here - why the quotes?

> It's taken from other instances in the same file.

Should probably fix the others then - I suspect it's bitrot and
cut'n'paste from when there was a parameter called consumer.
diff mbox series

Patch

diff --git a/drivers/regulator/devres.c b/drivers/regulator/devres.c
index 3ea1c170f8402..d59009d07a57e 100644
--- a/drivers/regulator/devres.c
+++ b/drivers/regulator/devres.c
@@ -173,6 +173,7 @@  static void devm_rdev_release(struct device *dev, void *res)
 
 /**
  * devm_regulator_register - Resource managed regulator_register()
+ * @dev: device for regulator "consumer"
  * @regulator_desc: regulator to register
  * @config: runtime configuration for regulator
  *
@@ -216,7 +217,8 @@  static int devm_rdev_match(struct device *dev, void *res, void *data)
 
 /**
  * devm_regulator_unregister - Resource managed regulator_unregister()
- * @regulator: regulator to free
+ * @dev: device for regulator "consumer"
+ * @rdev: regulator to free
  *
  * Unregister a regulator registered with devm_regulator_register().
  * Normally this function will not need to be called and the resource