[lm-sensors] [patch pc87360 reroll 1/6] sensor-dev-attr rework per Yani

Jim Cromie jcromie at divsol.com
Thu Aug 4 02:15:25 CEST 2005


> Yani  form  change.
> a.    declare  SENSOR_DEVICE_ATTR, not DEVICE_ATTR
> b.    in device_create_file() calls, pass &dev_attr member of the 
> sensor-dev-attr type.
> c.    in sensor-attr [gs]etter callback-functions,
>     use to_sensor_dev-attr() to get sensor_dev_attr *attr
>     use attr->index instead of offset
> d.   include hwmon-sysfs.h, needed for a.
>
> Note that this isnt a global replace.  Only those attrs that would 
> benefit from
> having an index member have been converted; ie those which are 
> macro-repeated.

$ diffstat 01-pc87360-yani-callback-form
 pc87360.c |  432 
+++++++++++++++++++++++++++++++++-----------------------------
 1 files changed, 231 insertions(+), 201 deletions(-)

Signed-off-by:  Jim Cromie <jcromie at divsol.com>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 01-pc87360-yani-callback-form
URL: <http://lists.lm-sensors.org/pipermail/lm-sensors/attachments/20050803/4e427ab3/attachment.ksh>


More information about the lm-sensors mailing list