aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hwmon/ads7828.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/hwmon/ads7828.c')
-rw-r--r--drivers/hwmon/ads7828.c13
1 files changed, 5 insertions, 8 deletions
diff --git a/drivers/hwmon/ads7828.c b/drivers/hwmon/ads7828.c
index 451977bca7d6..aac85f3aed50 100644
--- a/drivers/hwmon/ads7828.c
+++ b/drivers/hwmon/ads7828.c
@@ -47,10 +47,7 @@
47static const unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b, 47static const unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b,
48 I2C_CLIENT_END }; 48 I2C_CLIENT_END };
49 49
50/* Insmod parameters */ 50/* Module parameters */
51I2C_CLIENT_INSMOD_1(ads7828);
52
53/* Other module parameters */
54static int se_input = 1; /* Default is SE, 0 == diff */ 51static int se_input = 1; /* Default is SE, 0 == diff */
55static int int_vref = 1; /* Default is internal ref ON */ 52static int int_vref = 1; /* Default is internal ref ON */
56static int vref_mv = ADS7828_INT_VREF_MV; /* set if vref != 2.5V */ 53static int vref_mv = ADS7828_INT_VREF_MV; /* set if vref != 2.5V */
@@ -72,7 +69,7 @@ struct ads7828_data {
72}; 69};
73 70
74/* Function declaration - necessary due to function dependencies */ 71/* Function declaration - necessary due to function dependencies */
75static int ads7828_detect(struct i2c_client *client, int kind, 72static int ads7828_detect(struct i2c_client *client,
76 struct i2c_board_info *info); 73 struct i2c_board_info *info);
77static int ads7828_probe(struct i2c_client *client, 74static int ads7828_probe(struct i2c_client *client,
78 const struct i2c_device_id *id); 75 const struct i2c_device_id *id);
@@ -168,7 +165,7 @@ static int ads7828_remove(struct i2c_client *client)
168} 165}
169 166
170static const struct i2c_device_id ads7828_id[] = { 167static const struct i2c_device_id ads7828_id[] = {
171 { "ads7828", ads7828 }, 168 { "ads7828", 0 },
172 { } 169 { }
173}; 170};
174MODULE_DEVICE_TABLE(i2c, ads7828_id); 171MODULE_DEVICE_TABLE(i2c, ads7828_id);
@@ -183,11 +180,11 @@ static struct i2c_driver ads7828_driver = {
183 .remove = ads7828_remove, 180 .remove = ads7828_remove,
184 .id_table = ads7828_id, 181 .id_table = ads7828_id,
185 .detect = ads7828_detect, 182 .detect = ads7828_detect,
186 .address_data = &addr_data, 183 .address_list = normal_i2c,
187}; 184};
188 185
189/* Return 0 if detection is successful, -ENODEV otherwise */ 186/* Return 0 if detection is successful, -ENODEV otherwise */
190static int ads7828_detect(struct i2c_client *client, int kind, 187static int ads7828_detect(struct i2c_client *client,
191 struct i2c_board_info *info) 188 struct i2c_board_info *info)
192{ 189{
193 struct i2c_adapter *adapter = client->adapter; 190 struct i2c_adapter *adapter = client->adapter;