aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/i2c/ads1015.h
diff options
context:
space:
mode:
authorDirk Eibach <eibach@gdsys.de>2011-03-21 12:59:37 -0400
committerJean Delvare <khali@endymion.delvare>2011-03-21 12:59:37 -0400
commitc0046867f34bb81ec3f237ebbc5241ae678b8379 (patch)
treea5d9e95c3fcd09a53dac9ce88abb00f4bef4a4fc /include/linux/i2c/ads1015.h
parentfdf241a8ed93236915c70717a4b6dfb856274496 (diff)
hwmon: (ads1015) Make gain and datarate configurable
Configuration for ads1015 gain and datarate is possible via devicetree or platform data. This is a followup patch to previous ads1015 patches on Jean Delvares tree. Signed-off-by: Dirk Eibach <eibach@gdsys.de> Signed-off-by: Jean Delvare <khali@linux-fr.org>
Diffstat (limited to 'include/linux/i2c/ads1015.h')
-rw-r--r--include/linux/i2c/ads1015.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/include/linux/i2c/ads1015.h b/include/linux/i2c/ads1015.h
index 8541c6acfafd..d5aa2a045669 100644
--- a/include/linux/i2c/ads1015.h
+++ b/include/linux/i2c/ads1015.h
@@ -21,8 +21,16 @@
21#ifndef LINUX_ADS1015_H 21#ifndef LINUX_ADS1015_H
22#define LINUX_ADS1015_H 22#define LINUX_ADS1015_H
23 23
24#define ADS1015_CHANNELS 8
25
26struct ads1015_channel_data {
27 bool enabled;
28 unsigned int pga;
29 unsigned int data_rate;
30};
31
24struct ads1015_platform_data { 32struct ads1015_platform_data {
25 unsigned int exported_channels; 33 struct ads1015_channel_data channel_data[ADS1015_CHANNELS];
26}; 34};
27 35
28#endif /* LINUX_ADS1015_H */ 36#endif /* LINUX_ADS1015_H */