[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <11603db1-97c7-cfa0-ab1e-dbf5225ea6eb@gmail.com>
Date: Tue, 25 Jul 2023 18:51:44 -0500
From: Russell Haley <yumpusamongus@...il.com>
To: james@...iv.tech
Cc: corbet@....net, jdelvare@...e.com, linux-doc@...r.kernel.org,
linux-hwmon@...r.kernel.org, linux-kernel@...r.kernel.org,
linux@...ck-us.net
Subject: Re: [RFC 03/11] hwmon: (core) Revise kerneldoc comments
> @@ -888,18 +891,25 @@ hwmon_device_register_with_groups(struct device *dev, const char *name,
> EXPORT_SYMBOL_GPL(hwmon_device_register_with_groups);
>
> /**
> - * hwmon_device_register_with_info - register w/ hwmon
> - * @dev: the parent device (mandatory)
> - * @name: hwmon name attribute (mandatory)
> - * @drvdata: driver data to attach to created device (optional)
> - * @chip: pointer to hwmon chip information (mandatory)
> - * @extra_groups: pointer to list of additional non-standard attribute groups
> - * (optional)
> + * hwmon_device_register_with_info - Register a hardware monitoring device.
> + * @dev: A pointer to the parent device (mandatory).
> + * @name: The ``hwmon`` device name (mandatory).
> + * @drvdata: A pointer to the private driver data structure.
> + * @chip: A pointer to the chip descriptor (mandatory).
> + * @extra_groups: A pointer to a ``NULL``-terminated list of additional
> + * non-standard ``sysfs`` attribute groups.
This function has no @groups parameter, only @extra_groups.
> *
> - * hwmon_device_unregister() must be called when the device is no
> - * longer needed.
> + * Creates the standard ``sysfs`` attributes in the hardware monitoring core,
> + * letting the driver focus on reading from and writing to the chip instead of
> + * having to bother with ``sysfs`` attributes.
> *
> - * Returns the pointer to the new device.
> + * The result is a newly allocated ``hwmon`` device with standard ``sysfs``
> + * attributes as specified by @name and @groups and additional attributes as
But here a @groups parameter is mentioned.
> + * specified by @extra_groups.
> + *
> + * Return: On success, a pointer to the new ``hwmon`` device.
> + * hwmon_device_unregister() must be called on it when it is no longer needed.
> + * On failure, a &PTR_ERR.
> */
> struct device *
> hwmon_device_register_with_info(struct device *dev, const char *name,
Powered by blists - more mailing lists