lkml.org 
[lkml]   [2013]   [Jun]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH] power: replace strict_strtoul() with kstrtoul()
From
On Sat, Jun 1, 2013 at 10:27 AM, Jingoo Han <jg1.han@samsung.com> wrote:
> The usage of strict_strtoul() is not preferred, because
> strict_strtoul() is obsolete. Thus, kstrtoul() should be
> used.

> --- a/drivers/power/ab8500_fg.c
> +++ b/drivers/power/ab8500_fg.c
> @@ -2467,7 +2467,7 @@ static ssize_t charge_full_store(struct ab8500_fg *di, const char *buf,
> unsigned long charge_full;
> ssize_t ret = -EINVAL;

Redundant assignment.

> --- a/drivers/power/pcf50633-charger.c
> +++ b/drivers/power/pcf50633-charger.c
> @@ -191,7 +191,7 @@ static ssize_t set_usblim(struct device *dev,
> unsigned long ma;
> int ret;
>
> - ret = strict_strtoul(buf, 10, &ma);
> + ret = kstrtoul(buf, 10, &ma);
> if (ret)
> return -EINVAL;

return ret;

> @@ -228,7 +228,7 @@ static ssize_t set_chglim(struct device *dev,
> if (!mbc->pcf->pdata->charger_reference_current_ma)
> return -ENODEV;
>
> - ret = strict_strtoul(buf, 10, &ma);
> + ret = kstrtoul(buf, 10, &ma);
> if (ret)
> return -EINVAL;

Ditto.

--
With Best Regards,
Andy Shevchenko


\
 
 \ /
  Last update: 2013-06-02 13:01    [W:0.085 / U:0.188 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site