aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGrant Coady <grant_lkml@dodo.com.au>2005-05-17 03:16:02 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2005-06-22 00:51:58 -0400
commit6afe15595031bb9801af6207feed0bafc25b6e6b (patch)
tree144126d9d5e1808e91e46007e5b990bf9b1f1bbc
parentbe8992c249e42398ee905450688c135ab761674c (diff)
[PATCH] I2C: driver adm1021: remove die_code
This patch removes die_code from adm1021 as nothing within the driver uses it. Signed-off-by: Grant Coady <gcoady@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--drivers/i2c/chips/adm1021.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/drivers/i2c/chips/adm1021.c b/drivers/i2c/chips/adm1021.c
index f450c0bdc524..d2c774c32f45 100644
--- a/drivers/i2c/chips/adm1021.c
+++ b/drivers/i2c/chips/adm1021.c
@@ -102,8 +102,6 @@ struct adm1021_data {
102 u8 remote_temp_hyst; 102 u8 remote_temp_hyst;
103 u8 remote_temp_input; 103 u8 remote_temp_input;
104 u8 alarms; 104 u8 alarms;
105 /* special values for ADM1021 only */
106 u8 die_code;
107 /* Special values for ADM1023 only */ 105 /* Special values for ADM1023 only */
108 u8 remote_temp_prec; 106 u8 remote_temp_prec;
109 u8 remote_temp_os_prec; 107 u8 remote_temp_os_prec;
@@ -155,7 +153,6 @@ static ssize_t show_##value(struct device *dev, struct device_attribute *attr, c
155 return sprintf(buf, "%d\n", data->value); \ 153 return sprintf(buf, "%d\n", data->value); \
156} 154}
157show2(alarms); 155show2(alarms);
158show2(die_code);
159 156
160#define set(value, reg) \ 157#define set(value, reg) \
161static ssize_t set_##value(struct device *dev, struct device_attribute *attr, const char *buf, size_t count) \ 158static ssize_t set_##value(struct device *dev, struct device_attribute *attr, const char *buf, size_t count) \
@@ -182,7 +179,6 @@ static DEVICE_ATTR(temp2_max, S_IWUSR | S_IRUGO, show_remote_temp_max, set_remot
182static DEVICE_ATTR(temp2_min, S_IWUSR | S_IRUGO, show_remote_temp_hyst, set_remote_temp_hyst); 179static DEVICE_ATTR(temp2_min, S_IWUSR | S_IRUGO, show_remote_temp_hyst, set_remote_temp_hyst);
183static DEVICE_ATTR(temp2_input, S_IRUGO, show_remote_temp_input, NULL); 180static DEVICE_ATTR(temp2_input, S_IRUGO, show_remote_temp_input, NULL);
184static DEVICE_ATTR(alarms, S_IRUGO, show_alarms, NULL); 181static DEVICE_ATTR(alarms, S_IRUGO, show_alarms, NULL);
185static DEVICE_ATTR(die_code, S_IRUGO, show_die_code, NULL);
186 182
187 183
188static int adm1021_attach_adapter(struct i2c_adapter *adapter) 184static int adm1021_attach_adapter(struct i2c_adapter *adapter)
@@ -306,8 +302,6 @@ static int adm1021_detect(struct i2c_adapter *adapter, int address, int kind)
306 device_create_file(&new_client->dev, &dev_attr_temp2_min); 302 device_create_file(&new_client->dev, &dev_attr_temp2_min);
307 device_create_file(&new_client->dev, &dev_attr_temp2_input); 303 device_create_file(&new_client->dev, &dev_attr_temp2_input);
308 device_create_file(&new_client->dev, &dev_attr_alarms); 304 device_create_file(&new_client->dev, &dev_attr_alarms);
309 if (data->type == adm1021)
310 device_create_file(&new_client->dev, &dev_attr_die_code);
311 305
312 return 0; 306 return 0;
313 307
@@ -370,8 +364,6 @@ static struct adm1021_data *adm1021_update_device(struct device *dev)
370 data->remote_temp_max = adm1021_read_value(client, ADM1021_REG_REMOTE_TOS_R); 364 data->remote_temp_max = adm1021_read_value(client, ADM1021_REG_REMOTE_TOS_R);
371 data->remote_temp_hyst = adm1021_read_value(client, ADM1021_REG_REMOTE_THYST_R); 365 data->remote_temp_hyst = adm1021_read_value(client, ADM1021_REG_REMOTE_THYST_R);
372 data->alarms = adm1021_read_value(client, ADM1021_REG_STATUS) & 0x7c; 366 data->alarms = adm1021_read_value(client, ADM1021_REG_STATUS) & 0x7c;
373 if (data->type == adm1021)
374 data->die_code = adm1021_read_value(client, ADM1021_REG_DIE_CODE);
375 if (data->type == adm1023) { 367 if (data->type == adm1023) {
376 data->remote_temp_prec = adm1021_read_value(client, ADM1021_REG_REM_TEMP_PREC); 368 data->remote_temp_prec = adm1021_read_value(client, ADM1021_REG_REM_TEMP_PREC);
377 data->remote_temp_os_prec = adm1021_read_value(client, ADM1021_REG_REM_TOS_PREC); 369 data->remote_temp_os_prec = adm1021_read_value(client, ADM1021_REG_REM_TOS_PREC);