[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <BANLkTikKRVP4PW48YtR+mMMNsaxTDxoGtw@mail.gmail.com>
Date: Mon, 20 Jun 2011 16:45:46 +0300
From: Alexey Dobriyan <adobriyan@...il.com>
To: Peter Huewe <peterhuewe@....de>
Cc: Samuel Ortiz <sameo@...ux.intel.com>,
Srinidhi Kasagar <srinidhi.kasagar@...ricsson.com>,
Linus Walleij <linus.walleij@...ricsson.com>,
Mark Brown <broonie@...nsource.wolfsonmicro.com>,
Ian Lartey <ian@...nsource.wolfsonmicro.com>,
Dimitris Papastamos <dp@...nsource.wolfsonmicro.com>,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
kernel-janitors@...r.kernel.org
Subject: Re: [PATCH 2/2] mfd/ab8500: Use kstrtoul_from_user
NAK
You should use kstrtou8_from_user() and drop 0xff check as well.
Do NOT blindly replace strict_strtoul with kstrtoul.
On Mon, Jun 6, 2011 at 11:43 PM, Peter Huewe <peterhuewe@....de> wrote:
> - err = strict_strtoul(buf, 0, &user_val);
> + err = kstrtoul_from_user(user_buf, count, 0, &user_val);
> if (err)
> - return -EINVAL;
> + return err;
> +
> if (user_val > 0xff) {
> dev_err(dev, "debugfs error input > 0xff\n");
> return -EINVAL;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists