mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-27 09:02:06 +00:00
hwmon: (core) Clarify when read and write callbacks are mandatory
The callback descrption in hwmon.h was misleading and stated that read and write callbacks would be optional. More accurate is is that the callbacks are mandatory if readable / writeable attributes are present. Signed-off-by: Guenter Roeck <linux@roeck-us.net>
This commit is contained in:
parent
a2a0c3c57a
commit
f680b28456
1 changed files with 2 additions and 4 deletions
|
@ -298,8 +298,7 @@ enum hwmon_pwm_attributes {
|
||||||
* Channel number
|
* Channel number
|
||||||
* The function returns the file permissions.
|
* The function returns the file permissions.
|
||||||
* If the return value is 0, no attribute will be created.
|
* If the return value is 0, no attribute will be created.
|
||||||
* @read: Read callback. Optional. If not provided, attributes
|
* @read: Read callback. Mandatory if readable attributes are present.
|
||||||
* will not be readable.
|
|
||||||
* Parameters are:
|
* Parameters are:
|
||||||
* @dev: Pointer to hardware monitoring device
|
* @dev: Pointer to hardware monitoring device
|
||||||
* @type: Sensor type
|
* @type: Sensor type
|
||||||
|
@ -308,8 +307,7 @@ enum hwmon_pwm_attributes {
|
||||||
* Channel number
|
* Channel number
|
||||||
* @val: Pointer to returned value
|
* @val: Pointer to returned value
|
||||||
* The function returns 0 on success or a negative error number.
|
* The function returns 0 on success or a negative error number.
|
||||||
* @write: Write callback. Optional. If not provided, attributes
|
* @write: Write callback. Mandatory if writeable attributes are present.
|
||||||
* will not be writable.
|
|
||||||
* Parameters are:
|
* Parameters are:
|
||||||
* @dev: Pointer to hardware monitoring device
|
* @dev: Pointer to hardware monitoring device
|
||||||
* @type: Sensor type
|
* @type: Sensor type
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue