From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 210ACC433FE for ; Wed, 27 Apr 2022 17:39:07 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 9CB646B0071; Wed, 27 Apr 2022 13:39:06 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 95C486B0073; Wed, 27 Apr 2022 13:39:06 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 81B1A6B0074; Wed, 27 Apr 2022 13:39:06 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (relay.hostedemail.com [64.99.140.27]) by kanga.kvack.org (Postfix) with ESMTP id 6EC976B0071 for ; Wed, 27 Apr 2022 13:39:06 -0400 (EDT) Received: from smtpin04.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay01.hostedemail.com (Postfix) with ESMTP id 3440B617FA for ; Wed, 27 Apr 2022 17:39:06 +0000 (UTC) X-FDA: 79403369892.04.17F1535 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by imf20.hostedemail.com (Postfix) with ESMTP id 2AF8C1C0067 for ; Wed, 27 Apr 2022 17:39:01 +0000 (UTC) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 0B339B828A5; Wed, 27 Apr 2022 17:39:04 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4DBE1C385AD; Wed, 27 Apr 2022 17:39:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1651081142; bh=28m7Jmv/cP/fZD1raKhoHmAzZkh4E0aSzDdckRwT6ZY=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=Q7ZoWlobJC5xvGAziA+7AvdRJm0UfBN4J2xnMhAHkyexBIn4sf28UWOOYfofiP+JO LLZqd0luZ/XfSv5h3Dt1IL0MFQ1lzk15K0+oZr1DWwAq2DNIlXHNEk53D4L6xDo8kp m+v4BqedM8llnYyA03M4lX47FFYkNgNSN5CnsqGU= Date: Wed, 27 Apr 2022 10:39:01 -0700 From: Andrew Morton To: Andy Shevchenko Cc: Jagdish Gediya , linux-kernel@vger.kernel.org, linux-mm@kvack.org, willy@infradead.org, ying.huang@intel.com, dave.hansen@intel.com, Jonathan.Cameron@huawei.com, adobriyan@gmail.com, rf@opensource.cirrus.com, pmladek@suse.com Subject: Re: [PATCH v3 1/2] lib/kstrtox.c: Add "false"/"true" support to kstrtobool() Message-Id: <20220427103901.7567e7058dcaa3068056b2ed@linux-foundation.org> In-Reply-To: References: <20220426180203.70782-1-jvgediya@linux.ibm.com> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 2AF8C1C0067 X-Stat-Signature: uf7a8wz84higzerx3ijyp6eepirajj18 Authentication-Results: imf20.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=Q7ZoWlob; dmarc=none; spf=pass (imf20.hostedemail.com: domain of akpm@linux-foundation.org designates 145.40.68.75 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org X-Rspam-User: X-Rspamd-Server: rspam08 X-HE-Tag: 1651081141-670795 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Wed, 27 Apr 2022 18:13:43 +0300 Andy Shevchenko wrote: > On Tue, Apr 26, 2022 at 11:32:02PM +0530, Jagdish Gediya wrote: > > At many places in kernel, It is necessary to convert sysfs input > > to corrosponding bool value e.g. "false" or "0" need to be converted > > corresponding > > > to bool false, "true" or "1" need to be converted to bool true, > > places where such conversion is needed currently check the input > > string manually, kstrtobool() can be utilized at such places but > > currently it doesn't have support to accept "false"/"true". > > > > Add support to accept "false"/"true" as valid string in kstrtobool(). > > Andrew, this patch still needs a bit of work. I fixed the two issues you identified in this email. Is there more to do?