From patchwork Wed May 29 10:16:11 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ding Xiang X-Patchwork-Id: 10966721 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 1516315E6 for ; Wed, 29 May 2019 10:26:19 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 076A5287AA for ; Wed, 29 May 2019 10:26:19 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id ECF6C21F61; Wed, 29 May 2019 10:26:18 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 243D721F61 for ; Wed, 29 May 2019 10:26:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726985AbfE2K0R (ORCPT ); Wed, 29 May 2019 06:26:17 -0400 Received: from cmccmta1.chinamobile.com ([221.176.66.79]:2484 "EHLO cmccmta1.chinamobile.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726439AbfE2K0R (ORCPT ); Wed, 29 May 2019 06:26:17 -0400 X-Greylist: delayed 545 seconds by postgrey-1.27 at vger.kernel.org; Wed, 29 May 2019 06:26:16 EDT Received: from spf.mail.chinamobile.com (unknown[172.16.121.17]) by rmmx-syy-dmz-app01-12001 (RichMail) with SMTP id 2ee15cee5c1c5ec-e1cb0; Wed, 29 May 2019 18:17:01 +0800 (CST) X-RM-TRANSID: 2ee15cee5c1c5ec-e1cb0 X-RM-TagInfo: emlType=0 X-RM-SPAM-FLAG: 00000000 Received: from localhost.localdomain (unknown[223.105.0.243]) by rmsmtp-syy-appsvr09-12009 (RichMail) with SMTP id 2ee95cee5c1c2ed-2ea11; Wed, 29 May 2019 18:17:01 +0800 (CST) X-RM-TRANSID: 2ee95cee5c1c2ed-2ea11 From: Ding Xiang To: ysato@users.sourceforge.jp, dalias@libc.org Cc: linux-sh@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] sh/intc: Fix obsolete function Date: Wed, 29 May 2019 18:16:11 +0800 Message-Id: <1559124971-13074-1-git-send-email-dingxiang@cmss.chinamobile.com> X-Mailer: git-send-email 1.9.1 Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP simple_strtoul is obsolete, use kstrtoul instead. Signed-off-by: Ding Xiang --- drivers/sh/intc/userimask.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/sh/intc/userimask.c b/drivers/sh/intc/userimask.c index 87d69e7..d1d8e9b 100644 --- a/drivers/sh/intc/userimask.c +++ b/drivers/sh/intc/userimask.c @@ -33,7 +33,8 @@ { unsigned long level; - level = simple_strtoul(buf, NULL, 10); + if (kstrtoul(buf, 10, &level)) + return -EINVAL; /* * Minimal acceptable IRQ levels are in the 2 - 16 range, but