On 2/10/2010 1:59 AM, Andy Shevchenko wrote:
On Wed, Feb 10, 2010 at 4:02 AM, Omar Ramirez Luna<omar.ramirez@xxxxxx> wrote:
Try to use simple_strtol() kernel native method instead.
strtol or strtoul?
I don't know for sure, see below.
sorry, i meant: here it says simple_strtol but the code says simple_strtoul
However, there are opened questions:
- why type of Atoi() is s32 if the sign is used only to detect base?
This is the question about l vs ul.
agree, IMO this should be ul, I haven't reviewed all the places where
Atoi is used but the ones I have seen use it as ul
about the sign: I haven't seen any value with '+' or '-' prefix so with
this patch the decision to identify as base10 is left to
simple_guess_base inside strtoul
if value strings had '0x' instead of ending 'H' for hex the whole Atoi
could be replaced, i guess this would also allow to use strict_strtoul
and avoid a checkpatch warning :(
- omar
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html