Message ID | 1404314924-23564-11-git-send-email-lee.jones@linaro.org |
---|---|
State | Accepted |
Commit | 0ebc1c25ca2921f6e9becb9b3e6ea3ee2ffc8aaf |
Headers | show
Return-Path: <patchwork-forward+bncBDA7X7F2WUEBBZ6K2COQKGQE5PE3QKY@linaro.org> X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-yk0-f200.google.com (mail-yk0-f200.google.com [209.85.160.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id CA7E620560 for <linaro@patches.linaro.org>; Wed, 2 Jul 2014 15:29:43 +0000 (UTC) Received: by mail-yk0-f200.google.com with SMTP id 20sf19486389yks.11 for <linaro@patches.linaro.org>; Wed, 02 Jul 2014 08:29:43 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=IZxaK4RGEdOgkrNKNnywE/UaQ1I7y/RUkdl9r7oS4s8=; b=b8SNlpDhruHcArdcmVzJ5Z1CLNv78mubJCvYZYI0KzEQG/7KPNHOYf25hel41QMsOV 5JSbZCN2TK6l96YNZAl+jukGyM9gEgajJJCdAt3unZ04RmNgXWtAJ5gFTrmwDWrc+9Gd jixaRlcT/E96crOvqUcNJLJyhfwne6AAj9aZL6i1PhIA5w1/egQct1qT7eXrs1xQowWO mev+EqCO00+LFlUiPAP8P8ZYi3Yhw4FuvWG8q/WpCpGp/qjzgli7PbOwoNWl046YfHV+ jz5zBdwrvsrvIxaOEuQCVGm0kyH+A8E/quCLYLgsYg2ux/zEWp32B9rjQO/TheoZXrSc R2Ig== X-Gm-Message-State: ALoCoQma/mML+5H4UvSIap3fIuozJf/9/+19NaakY9KYYiKEdzR76xl1N6UxvQXXnud0Fvt0EVpu X-Received: by 10.236.165.230 with SMTP id e66mr6483607yhl.6.1404314983640; Wed, 02 Jul 2014 08:29:43 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.21.165 with SMTP id 34ls105330qgl.1.gmail; Wed, 02 Jul 2014 08:29:43 -0700 (PDT) X-Received: by 10.220.196.82 with SMTP id ef18mr116007vcb.78.1404314983485; Wed, 02 Jul 2014 08:29:43 -0700 (PDT) Received: from mail-vc0-f177.google.com (mail-vc0-f177.google.com [209.85.220.177]) by mx.google.com with ESMTPS id pz7si13062296vcb.5.2014.07.02.08.29.43 for <patchwork-forward@linaro.org> (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 02 Jul 2014 08:29:43 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.177 as permitted sender) client-ip=209.85.220.177; Received: by mail-vc0-f177.google.com with SMTP id ij19so10440219vcb.22 for <patchwork-forward@linaro.org>; Wed, 02 Jul 2014 08:29:43 -0700 (PDT) X-Received: by 10.220.203.134 with SMTP id fi6mr40095178vcb.18.1404314983406; Wed, 02 Jul 2014 08:29:43 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.221.37.5 with SMTP id tc5csp301920vcb; Wed, 2 Jul 2014 08:29:43 -0700 (PDT) X-Received: by 10.50.122.97 with SMTP id lr1mr50202453igb.18.1404314982958; Wed, 02 Jul 2014 08:29:42 -0700 (PDT) Received: from mail-ie0-f179.google.com (mail-ie0-f179.google.com [209.85.223.179]) by mx.google.com with ESMTPS id m12si39499622icb.53.2014.07.02.08.29.42 for <patches@linaro.org> (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 02 Jul 2014 08:29:42 -0700 (PDT) Received-SPF: pass (google.com: domain of lee.jones@linaro.org designates 209.85.223.179 as permitted sender) client-ip=209.85.223.179; Received: by mail-ie0-f179.google.com with SMTP id tr6so9696473ieb.10 for <patches@linaro.org>; Wed, 02 Jul 2014 08:29:42 -0700 (PDT) X-Received: by 10.42.32.136 with SMTP id e8mr4672115icd.44.1404314982716; Wed, 02 Jul 2014 08:29:42 -0700 (PDT) Received: from localhost.localdomain (host109-148-235-194.range109-148.btcentralplus.com. [109.148.235.194]) by mx.google.com with ESMTPSA id d4sm23997781igc.5.2014.07.02.08.29.40 for <multiple recipients> (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 02 Jul 2014 08:29:42 -0700 (PDT) From: Lee Jones <lee.jones@linaro.org> To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: sameo@linux.intel.com, linus.walleij@linaro.org, Lee Jones <lee.jones@linaro.org> Subject: [PATCH 10/12] mfd: aat2870-core: Stop using obsolte simple_strtoul() Date: Wed, 2 Jul 2014 16:28:42 +0100 Message-Id: <1404314924-23564-11-git-send-email-lee.jones@linaro.org> X-Mailer: git-send-email 1.8.3.2 In-Reply-To: <1404314924-23564-1-git-send-email-lee.jones@linaro.org> References: <1404314924-23564-1-git-send-email-lee.jones@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: lee.jones@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.177 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: <patchwork-forward.linaro.org> X-Google-Group-Id: 836684582541 List-Post: <http://groups.google.com/a/linaro.org/group/patchwork-forward/post>, <mailto:patchwork-forward@linaro.org> List-Help: <http://support.google.com/a/linaro.org/bin/topic.py?topic=25838>, <mailto:patchwork-forward+help@linaro.org> List-Archive: <http://groups.google.com/a/linaro.org/group/patchwork-forward/> List-Unsubscribe: <http://groups.google.com/a/linaro.org/group/patchwork-forward/subscribe>, <mailto:googlegroups-manage+836684582541+unsubscribe@googlegroups.com> |
diff --git a/drivers/mfd/aat2870-core.c b/drivers/mfd/aat2870-core.c index 14d9542..4e6e03d 100644 --- a/drivers/mfd/aat2870-core.c +++ b/drivers/mfd/aat2870-core.c @@ -303,7 +303,10 @@ static ssize_t aat2870_reg_write_file(struct file *file, while (*start == ' ') start++; - addr = simple_strtoul(start, &start, 16); + ret = kstrtoul(start, 16, &addr); + if (ret) + return ret; + if (addr >= AAT2870_REG_NUM) { dev_err(aat2870->dev, "Invalid address, 0x%lx\n", addr); return -EINVAL;
Soothes checkpatch warning: WARNING: simple_strtoul is obsolete, use kstrtoul instead #306: FILE: drivers/mfd/aat2870-core.c:306: + addr = simple_strtoul(start, &start, 16); Signed-off-by: Lee Jones <lee.jones@linaro.org> --- drivers/mfd/aat2870-core.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)