aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/i2c/chips/ds1621.c
diff options
context:
space:
mode:
authorYani Ioannou <yani.ioannou@gmail.com>2005-05-17 06:41:35 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2005-06-20 18:15:33 -0400
commit30f74292e50d6c4ae438dbee5cb45d77bf774351 (patch)
tree4bfa1b6715ecd597e196a9f448c825ef0c12d8e3 /drivers/i2c/chips/ds1621.c
parent74880c063b06efd103c924abfe19d9d8fa4864c4 (diff)
[PATCH] Driver Core: drivers/i2c/chips/adm1031.c - lm75.c: update device attribute callbacks
Signed-off-by: Yani Ioannou <yani.ioannou@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/i2c/chips/ds1621.c')
-rw-r--r--drivers/i2c/chips/ds1621.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/i2c/chips/ds1621.c b/drivers/i2c/chips/ds1621.c
index bb1fefb2162e..4ae15bd5dcfb 100644
--- a/drivers/i2c/chips/ds1621.c
+++ b/drivers/i2c/chips/ds1621.c
@@ -137,7 +137,7 @@ static void ds1621_init_client(struct i2c_client *client)
137} 137}
138 138
139#define show(value) \ 139#define show(value) \
140static ssize_t show_##value(struct device *dev, char *buf) \ 140static ssize_t show_##value(struct device *dev, struct device_attribute *attr, char *buf) \
141{ \ 141{ \
142 struct ds1621_data *data = ds1621_update_client(dev); \ 142 struct ds1621_data *data = ds1621_update_client(dev); \
143 return sprintf(buf, "%d\n", LM75_TEMP_FROM_REG(data->value)); \ 143 return sprintf(buf, "%d\n", LM75_TEMP_FROM_REG(data->value)); \
@@ -148,7 +148,7 @@ show(temp_min);
148show(temp_max); 148show(temp_max);
149 149
150#define set_temp(suffix, value, reg) \ 150#define set_temp(suffix, value, reg) \
151static ssize_t set_temp_##suffix(struct device *dev, const char *buf, \ 151static ssize_t set_temp_##suffix(struct device *dev, struct device_attribute *attr, const char *buf, \
152 size_t count) \ 152 size_t count) \
153{ \ 153{ \
154 struct i2c_client *client = to_i2c_client(dev); \ 154 struct i2c_client *client = to_i2c_client(dev); \
@@ -165,7 +165,7 @@ static ssize_t set_temp_##suffix(struct device *dev, const char *buf, \
165set_temp(min, temp_min, DS1621_REG_TEMP_MIN); 165set_temp(min, temp_min, DS1621_REG_TEMP_MIN);
166set_temp(max, temp_max, DS1621_REG_TEMP_MAX); 166set_temp(max, temp_max, DS1621_REG_TEMP_MAX);
167 167
168static ssize_t show_alarms(struct device *dev, char *buf) 168static ssize_t show_alarms(struct device *dev, struct device_attribute *attr, char *buf)
169{ 169{
170 struct ds1621_data *data = ds1621_update_client(dev); 170 struct ds1621_data *data = ds1621_update_client(dev);
171 return sprintf(buf, "%d\n", ALARMS_FROM_REG(data->conf)); 171 return sprintf(buf, "%d\n", ALARMS_FROM_REG(data->conf));