hwmon-sensor-attr-array-2.patch

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Jean, Hans,

This patch refactors SENSOR_DEVICE_ATTR_2 macro, following pattern set by
SENSOR_ATTR.  First it creates a new macro SENSOR_ATTR_2() which expands 
to an initialization expression, then it uses that in SENSOR_DEVICE_ATTR_2, 
which declares and initializes a struct sensor_device_attribute_2.


This version differs from that in Hans' abituguru driver,
in that it preserves the argument order used in the original 
SENSOR_DEVICE_ATTR_2 macro, Hans' version invites confusion by
transposing _nr and _index between 2 closely related macros.

Happily though, Hans coded with __SENSOR_DEVICE_ATTR2,
so his driver could coexist with the macro defined here,
and he could switch at his discretion.

Signed-off-by:  Jim Cromie <jim.cromie at gmail.com>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: hwmon-sensor-attr-array-2.patch
Type: text/x-patch
Size: 969 bytes
Desc: not available
Url : http://lists.lm-sensors.org/pipermail/lm-sensors/attachments/20051228/ba4081e3/attachment.bin 


[Index of Archives]     [Linux Kernel]     [Linux Hardware Monitoring]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux