[PATCH 17/45] kstrtox: convert drivers/clocksource/
From: Alexey Dobriyan
Date: Sun Dec 05 2010 - 12:50:58 EST
Signed-off-by: Alexey Dobriyan <adobriyan@xxxxxxxxx>
---
drivers/clocksource/acpi_pm.c | 14 ++++++--------
1 files changed, 6 insertions(+), 8 deletions(-)
diff --git a/drivers/clocksource/acpi_pm.c b/drivers/clocksource/acpi_pm.c
index cfb0f52..2e77b1d 100644
--- a/drivers/clocksource/acpi_pm.c
+++ b/drivers/clocksource/acpi_pm.c
@@ -229,15 +229,13 @@ fs_initcall(init_acpi_pm_clocksource);
*/
static int __init parse_pmtmr(char *arg)
{
- unsigned long base;
+ u32 base;
+ int rv;
- if (strict_strtoul(arg, 16, &base))
- return -EINVAL;
-#ifdef CONFIG_X86_64
- if (base > UINT_MAX)
- return -ERANGE;
-#endif
- printk(KERN_INFO "PMTMR IOPort override: 0x%04x -> 0x%04lx\n",
+ rv = kstrtou32(arg, 16, &base);
+ if (rv < 0)
+ return rv;
+ printk(KERN_INFO "PMTMR IOPort override: 0x%04x -> 0x%04x\n",
pmtmr_ioport, base);
pmtmr_ioport = base;
--
1.7.2.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/