Re: [patch 2.6.20-rc1 3/6] input: ads7846 more compatible with hwmon

From: Dmitry Torokhov
Date: Fri Dec 22 2006 - 15:26:57 EST


On 12/22/06, David Brownell <david-b@xxxxxxxxxxx> wrote:
Be more compatible with the hwmon framework:

- Hook up to hwmon
* show sensor attrubites only if hwmon is present
* otherwise be just a touchscreen
- Report voltages per hwmon convention
* measure in millivolts
* voltages are named in[0-8]_input (ugh)
* for 7846 chips, properly range-adjust vBATT/in1_input

There are too many #ifdefs. Please consider creating
ads7846_[un]register_hwmon() and use them in
ads7846_probe()/ads7846_remove(). Split hwmon related attributes into
a separate attribute group and move everything in #ifdef CONFIG_HWMON
block.

+ *
+ * FIXME make external vREF_mV be a module option, and use that as needed...
*/
+static const unsigned vREF_mV = 2500;


Why don't you make it mdule option right away?

--
Dmitry
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/