From patchwork Fri Jan 18 09:39:16 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Abhijit Pawar X-Patchwork-Id: 2000381 Return-Path: X-Original-To: patchwork-v9fs-devel@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from lists.sourceforge.net (lists.sourceforge.net [216.34.181.88]) by patchwork2.kernel.org (Postfix) with ESMTP id 917C9DF280 for ; Fri, 18 Jan 2013 09:40:35 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=sfs-ml-2.v29.ch3.sourceforge.com) by sfs-ml-2.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1Tw8R7-0004eO-Re; Fri, 18 Jan 2013 09:40:33 +0000 Received: from sog-mx-2.v43.ch3.sourceforge.com ([172.29.43.192] helo=mx.sourceforge.net) by sfs-ml-2.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1Tw8R5-0004eH-K0 for v9fs-developer@lists.sourceforge.net; Fri, 18 Jan 2013 09:40:31 +0000 Received-SPF: pass (sog-mx-2.v43.ch3.sourceforge.com: domain of gmail.com designates 209.85.160.49 as permitted sender) client-ip=209.85.160.49; envelope-from=abhi.c.pawar@gmail.com; helo=mail-pb0-f49.google.com; Received: from mail-pb0-f49.google.com ([209.85.160.49]) by sog-mx-2.v43.ch3.sourceforge.com with esmtps (TLSv1:RC4-SHA:128) (Exim 4.76) id 1Tw8R4-0005eI-Sd for v9fs-developer@lists.sourceforge.net; Fri, 18 Jan 2013 09:40:31 +0000 Received: by mail-pb0-f49.google.com with SMTP id un15so1942956pbc.22 for ; Fri, 18 Jan 2013 01:40:25 -0800 (PST) X-Received: by 10.68.135.99 with SMTP id pr3mr3479937pbb.151.1358502025029; Fri, 18 Jan 2013 01:40:25 -0800 (PST) Received: from apawar-f16.cybage.com ([121.242.40.10]) by mx.google.com with ESMTPS id rv8sm2793384pbc.27.2013.01.18.01.40.21 (version=TLSv1 cipher=RC4-SHA bits=128/128); Fri, 18 Jan 2013 01:40:23 -0800 (PST) From: Abhijit Pawar To: akpm@linux-foundation.org, Eric Van Hensbergen , Ron Minnich , Latchesar Ionkov Date: Fri, 18 Jan 2013 15:09:16 +0530 Message-Id: <1358501956-31493-1-git-send-email-abhi.c.pawar@gmail.com> X-Mailer: git-send-email 1.7.7.6 X-Spam-Score: -1.6 (-) X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -1.5 SPF_CHECK_PASS SPF reports sender host as permitted sender for sender-domain 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (abhi.c.pawar[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature X-Headers-End: 1Tw8R4-0005eI-Sd Cc: v9fs-developer@lists.sourceforge.net, linux-kernel@vger.kernel.org, Abhijit Pawar Subject: [V9fs-developer] [PATCH 1/3] fs/9p: remove obsolete simple_strto X-BeenThere: v9fs-developer@lists.sourceforge.net X-Mailman-Version: 2.1.9 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: v9fs-developer-bounces@lists.sourceforge.net This patch replace the obsolete simple_strto with kstrto. Signed-off-by: Abhijit Pawar --- fs/9p/v9fs.c | 7 +++---- 1 files changed, 3 insertions(+), 4 deletions(-) diff --git a/fs/9p/v9fs.c b/fs/9p/v9fs.c index d934f04..6ac48fc 100644 --- a/fs/9p/v9fs.c +++ b/fs/9p/v9fs.c @@ -112,7 +112,7 @@ static int v9fs_parse_options(struct v9fs_session_info *v9ses, char *opts) substring_t args[MAX_OPT_ARGS]; char *p; int option = 0; - char *s, *e; + char *s; int ret = 0; /* setup defaults */ @@ -249,9 +249,8 @@ static int v9fs_parse_options(struct v9fs_session_info *v9ses, char *opts) v9ses->flags |= V9FS_ACCESS_CLIENT; } else { v9ses->flags |= V9FS_ACCESS_SINGLE; - v9ses->uid = simple_strtoul(s, &e, 10); - if (*e != '\0') { - ret = -EINVAL; + ret = kstrtouint(s, 10, &v9ses->uid); + if (ret) { pr_info("Unknown access argument %s\n", s); kfree(s);