summaryrefslogtreecommitdiffstats
path: root/drivers/misc/carma/carma-fpga-program.c
diff options
context:
space:
mode:
authorJingoo Han <jg1.han@samsung.com>2013-06-04 13:15:16 +0900
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-06-06 12:54:08 -0700
commitf7b41276b6b07f47c5f5212fa244385b0e3aaa30 (patch)
treea5c48de78a236e836da7d3b26e999224c975cc11 /drivers/misc/carma/carma-fpga-program.c
parent4cd5773a2ae6facdde3f563087a4cc50f00d9530 (diff)
downloadblackbird-op-linux-f7b41276b6b07f47c5f5212fa244385b0e3aaa30.tar.gz
blackbird-op-linux-f7b41276b6b07f47c5f5212fa244385b0e3aaa30.zip
misc: replace strict_strtoul() with kstrtoul()
The usage of strict_strtoul() is not preferred, because strict_strtoul() is obsolete. Thus, kstrtoul() should be used. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/carma/carma-fpga-program.c')
-rw-r--r--drivers/misc/carma/carma-fpga-program.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/misc/carma/carma-fpga-program.c b/drivers/misc/carma/carma-fpga-program.c
index fa017cf64bd1..c6bd7e84de24 100644
--- a/drivers/misc/carma/carma-fpga-program.c
+++ b/drivers/misc/carma/carma-fpga-program.c
@@ -830,8 +830,9 @@ static ssize_t penable_store(struct device *dev, struct device_attribute *attr,
unsigned long val;
int ret;
- if (strict_strtoul(buf, 0, &val))
- return -EINVAL;
+ ret = kstrtoul(buf, 0, &val);
+ if (ret)
+ return ret;
if (val) {
ret = fpga_enable_power_supplies(priv);
@@ -859,8 +860,9 @@ static ssize_t program_store(struct device *dev, struct device_attribute *attr,
unsigned long val;
int ret;
- if (strict_strtoul(buf, 0, &val))
- return -EINVAL;
+ ret = kstrtoul(buf, 0, &val);
+ if (ret)
+ return ret;
/* We can't have an image writer and be programming simultaneously */
if (mutex_lock_interruptible(&priv->lock))
OpenPOWER on IntegriCloud