diff options
Diffstat (limited to 'drivers/hwmon/it87.c')
-rw-r--r-- | drivers/hwmon/it87.c | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/drivers/hwmon/it87.c b/drivers/hwmon/it87.c index a61f5d00f10a..0da7c9c508c3 100644 --- a/drivers/hwmon/it87.c +++ b/drivers/hwmon/it87.c | |||
@@ -213,7 +213,7 @@ struct it87_data { | |||
213 | u8 sensor; /* Register value */ | 213 | u8 sensor; /* Register value */ |
214 | u8 fan_div[3]; /* Register encoding, shifted right */ | 214 | u8 fan_div[3]; /* Register encoding, shifted right */ |
215 | u8 vid; /* Register encoding, combined */ | 215 | u8 vid; /* Register encoding, combined */ |
216 | int vrm; | 216 | u8 vrm; |
217 | u32 alarms; /* Register encoding, combined */ | 217 | u32 alarms; /* Register encoding, combined */ |
218 | u8 fan_main_ctrl; /* Register value */ | 218 | u8 fan_main_ctrl; /* Register value */ |
219 | u8 manual_pwm_ctl[3]; /* manual PWM value set by user */ | 219 | u8 manual_pwm_ctl[3]; /* manual PWM value set by user */ |
@@ -234,17 +234,18 @@ static void it87_init_client(struct i2c_client *client, struct it87_data *data); | |||
234 | 234 | ||
235 | 235 | ||
236 | static struct i2c_driver it87_driver = { | 236 | static struct i2c_driver it87_driver = { |
237 | .owner = THIS_MODULE, | 237 | .driver = { |
238 | .name = "it87", | 238 | .name = "it87", |
239 | }, | ||
239 | .id = I2C_DRIVERID_IT87, | 240 | .id = I2C_DRIVERID_IT87, |
240 | .flags = I2C_DF_NOTIFY, | ||
241 | .attach_adapter = it87_attach_adapter, | 241 | .attach_adapter = it87_attach_adapter, |
242 | .detach_client = it87_detach_client, | 242 | .detach_client = it87_detach_client, |
243 | }; | 243 | }; |
244 | 244 | ||
245 | static struct i2c_driver it87_isa_driver = { | 245 | static struct i2c_driver it87_isa_driver = { |
246 | .owner = THIS_MODULE, | 246 | .driver = { |
247 | .name = "it87-isa", | 247 | .name = "it87-isa", |
248 | }, | ||
248 | .attach_adapter = it87_isa_attach_adapter, | 249 | .attach_adapter = it87_isa_attach_adapter, |
249 | .detach_client = it87_detach_client, | 250 | .detach_client = it87_detach_client, |
250 | }; | 251 | }; |
@@ -668,7 +669,7 @@ static ssize_t | |||
668 | show_vrm_reg(struct device *dev, struct device_attribute *attr, char *buf) | 669 | show_vrm_reg(struct device *dev, struct device_attribute *attr, char *buf) |
669 | { | 670 | { |
670 | struct it87_data *data = it87_update_device(dev); | 671 | struct it87_data *data = it87_update_device(dev); |
671 | return sprintf(buf, "%ld\n", (long) data->vrm); | 672 | return sprintf(buf, "%u\n", data->vrm); |
672 | } | 673 | } |
673 | static ssize_t | 674 | static ssize_t |
674 | store_vrm_reg(struct device *dev, struct device_attribute *attr, const char *buf, size_t count) | 675 | store_vrm_reg(struct device *dev, struct device_attribute *attr, const char *buf, size_t count) |
@@ -761,7 +762,8 @@ static int it87_detect(struct i2c_adapter *adapter, int address, int kind) | |||
761 | 762 | ||
762 | /* Reserve the ISA region */ | 763 | /* Reserve the ISA region */ |
763 | if (is_isa) | 764 | if (is_isa) |
764 | if (!request_region(address, IT87_EXTENT, it87_isa_driver.name)) | 765 | if (!request_region(address, IT87_EXTENT, |
766 | it87_isa_driver.driver.name)) | ||
765 | goto ERROR0; | 767 | goto ERROR0; |
766 | 768 | ||
767 | /* For now, we presume we have a valid client. We create the | 769 | /* For now, we presume we have a valid client. We create the |