From e343d3ea73e97b339ecb1d39f1cdd306da24a175 Mon Sep 17 00:00:00 2001 From: Arend van Spriel Date: Wed, 2 Mar 2011 17:01:37 +0100 Subject: [PATCH] staging: brcm80211: replace simple_strtoul with strict_strtoul By checkpatch recommendation using strict_strtoul now. Reviewed-by: Roland Vossen Reviewed-by: Brett Rudley Signed-off-by: Arend van Spriel Reviewed-by: Dan Carpenter Signed-off-by: Greg Kroah-Hartman --- .../staging/brcm80211/brcmsmac/wl_mac80211.c | 28 +++++++++++-------- 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/drivers/staging/brcm80211/brcmsmac/wl_mac80211.c b/drivers/staging/brcm80211/brcmsmac/wl_mac80211.c index 6059e4cc3aa1..6ce5172557f6 100644 --- a/drivers/staging/brcm80211/brcmsmac/wl_mac80211.c +++ b/drivers/staging/brcm80211/brcmsmac/wl_mac80211.c @@ -1293,18 +1293,22 @@ static int __init wl_module_init(void) wl_msg_level = msglevel; else { char *var = getvar(NULL, "wl_msglevel"); - if (var) - wl_msg_level = simple_strtoul(var, NULL, 0); - } - { - extern u32 phyhal_msg_level; - - if (phymsglevel != 0xdeadbeef) - phyhal_msg_level = phymsglevel; - else { - char *var = getvar(NULL, "phy_msglevel"); - if (var) - phyhal_msg_level = simple_strtoul(var, NULL, 0); + if (var) { + unsigned long value; + + (void)strict_strtoul(var, 0, &value); + wl_msg_level = value; + } + } + if (phymsglevel != 0xdeadbeef) + phyhal_msg_level = phymsglevel; + else { + char *var = getvar(NULL, "phy_msglevel"); + if (var) { + unsigned long value; + + (void)strict_strtoul(var, 0, &value); + phyhal_msg_level = value; } } #endif /* BCMDBG */ -- 2.39.5