diff options
Diffstat (limited to 'drivers/hwmon/vt1211.c')
-rw-r--r-- | drivers/hwmon/vt1211.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/hwmon/vt1211.c b/drivers/hwmon/vt1211.c index 73f77a9b8b18..ae33bbb577c7 100644 --- a/drivers/hwmon/vt1211.c +++ b/drivers/hwmon/vt1211.c | |||
@@ -33,7 +33,7 @@ | |||
33 | #include <linux/mutex.h> | 33 | #include <linux/mutex.h> |
34 | #include <linux/ioport.h> | 34 | #include <linux/ioport.h> |
35 | #include <linux/acpi.h> | 35 | #include <linux/acpi.h> |
36 | #include <asm/io.h> | 36 | #include <linux/io.h> |
37 | 37 | ||
38 | static int uch_config = -1; | 38 | static int uch_config = -1; |
39 | module_param(uch_config, int, 0); | 39 | module_param(uch_config, int, 0); |
@@ -1136,7 +1136,7 @@ static int __devinit vt1211_probe(struct platform_device *pdev) | |||
1136 | } | 1136 | } |
1137 | 1137 | ||
1138 | res = platform_get_resource(pdev, IORESOURCE_IO, 0); | 1138 | res = platform_get_resource(pdev, IORESOURCE_IO, 0); |
1139 | if (!request_region(res->start, res->end - res->start + 1, DRVNAME)) { | 1139 | if (!request_region(res->start, resource_size(res), DRVNAME)) { |
1140 | err = -EBUSY; | 1140 | err = -EBUSY; |
1141 | dev_err(dev, "Failed to request region 0x%lx-0x%lx\n", | 1141 | dev_err(dev, "Failed to request region 0x%lx-0x%lx\n", |
1142 | (unsigned long)res->start, (unsigned long)res->end); | 1142 | (unsigned long)res->start, (unsigned long)res->end); |
@@ -1209,7 +1209,7 @@ EXIT_DEV_REMOVE: | |||
1209 | dev_err(dev, "Sysfs interface creation failed (%d)\n", err); | 1209 | dev_err(dev, "Sysfs interface creation failed (%d)\n", err); |
1210 | EXIT_DEV_REMOVE_SILENT: | 1210 | EXIT_DEV_REMOVE_SILENT: |
1211 | vt1211_remove_sysfs(pdev); | 1211 | vt1211_remove_sysfs(pdev); |
1212 | release_region(res->start, res->end - res->start + 1); | 1212 | release_region(res->start, resource_size(res)); |
1213 | EXIT_KFREE: | 1213 | EXIT_KFREE: |
1214 | platform_set_drvdata(pdev, NULL); | 1214 | platform_set_drvdata(pdev, NULL); |
1215 | kfree(data); | 1215 | kfree(data); |
@@ -1228,7 +1228,7 @@ static int __devexit vt1211_remove(struct platform_device *pdev) | |||
1228 | kfree(data); | 1228 | kfree(data); |
1229 | 1229 | ||
1230 | res = platform_get_resource(pdev, IORESOURCE_IO, 0); | 1230 | res = platform_get_resource(pdev, IORESOURCE_IO, 0); |
1231 | release_region(res->start, res->end - res->start + 1); | 1231 | release_region(res->start, resource_size(res)); |
1232 | 1232 | ||
1233 | return 0; | 1233 | return 0; |
1234 | } | 1234 | } |