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 2FFA8C54EE9 for ; Thu, 8 Sep 2022 11:24:50 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 95F5E6B0072; Thu, 8 Sep 2022 07:24:49 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 8C1AF8D0002; Thu, 8 Sep 2022 07:24:49 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 712E46B0074; Thu, 8 Sep 2022 07:24:49 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id 5A97F6B0072 for ; Thu, 8 Sep 2022 07:24:49 -0400 (EDT) Received: from smtpin10.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id 2C16AC1A2E for ; Thu, 8 Sep 2022 11:24:49 +0000 (UTC) X-FDA: 79888685898.10.986AE08 Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) by imf18.hostedemail.com (Postfix) with ESMTP id A64061C0075 for ; Thu, 8 Sep 2022 11:24:47 +0000 (UTC) Received: from pps.filterd (m0098410.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 2889lXvI001698; Thu, 8 Sep 2022 11:24:25 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=date : from : to : cc : subject : message-id : references : mime-version : content-type : in-reply-to; s=pp1; bh=AlvwoiXcWmTt4XPcR/9fgVZLjS0MEKff4YeJmUQI89o=; b=l0B1FT+tPd3eq0awvMDZowmZ0/6WaQ+a/my7wgS9FYfsTc6W4BmuYTLaww9M2WsNOyut 3c+41syPeeL9eXRCViUkDZ8s5YRGP94y3aZamk/f8K3FDrbL5cyU+wV8LBedR3pKE3+6 n+IKqWLIKBRVC/3ARZTFRZN4kcwoK1dJSaIEin1VGZABVzTQ9OKbvt8vNJz6mTevuUBP owb4WYddLj0bXE1+QFzdhaEaxYGtYU4j9fe7hmQ6Uhye2p7i+G8PwzYQOW4W55IXtjPi Ar55Xz+i1HyFtT/380gXsDmMa3zToIfOjzko7/qtQJ/3zflmVGeEAZlRfICZunZO2Vot RQ== Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3jfe2vudpc-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 08 Sep 2022 11:24:25 +0000 Received: from m0098410.ppops.net (m0098410.ppops.net [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 288AsKj0007600; Thu, 8 Sep 2022 11:24:24 GMT Received: from ppma06ams.nl.ibm.com (66.31.33a9.ip4.static.sl-reverse.com [169.51.49.102]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3jfe2vudnm-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 08 Sep 2022 11:24:24 +0000 Received: from pps.filterd (ppma06ams.nl.ibm.com [127.0.0.1]) by ppma06ams.nl.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 288BMVQr024019; Thu, 8 Sep 2022 11:24:22 GMT Received: from b06cxnps4076.portsmouth.uk.ibm.com (d06relay13.portsmouth.uk.ibm.com [9.149.109.198]) by ppma06ams.nl.ibm.com with ESMTP id 3jbx6hpgwn-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 08 Sep 2022 11:24:21 +0000 Received: from d06av22.portsmouth.uk.ibm.com (d06av22.portsmouth.uk.ibm.com [9.149.105.58]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 288BOJPo35258858 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 8 Sep 2022 11:24:19 GMT Received: from d06av22.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id A30E24C044; Thu, 8 Sep 2022 11:24:19 +0000 (GMT) Received: from d06av22.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id BF9BC4C040; Thu, 8 Sep 2022 11:24:17 +0000 (GMT) Received: from linux.ibm.com (unknown [9.145.44.9]) by d06av22.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Thu, 8 Sep 2022 11:24:17 +0000 (GMT) Date: Thu, 8 Sep 2022 14:24:15 +0300 From: Mike Rapoport To: Lukas Bulwahn Cc: Russell King , linux-arm-kernel@lists.infradead.org, Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org, Mauro Carvalho Chehab , linux-media@vger.kernel.org, Peter Chen , Greg Kroah-Hartman , linux-usb@vger.kernel.org, Andrew Morton , linux-mm@kvack.org, Masahiro Yamada , linux-kbuild@vger.kernel.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 5/6] mm: Kconfig: make config SECRETMEM visible with EXPERT Message-ID: References: <20220908104337.11940-1-lukas.bulwahn@gmail.com> <20220908104337.11940-6-lukas.bulwahn@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220908104337.11940-6-lukas.bulwahn@gmail.com> X-TM-AS-GCONF: 00 X-Proofpoint-GUID: uIjwroCFkW0oicsSGIESTem3oxG1McVV X-Proofpoint-ORIG-GUID: pk9wGSrUqEXg-ItWBg8TagzjQ1laFaY7 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.895,Hydra:6.0.528,FMLib:17.11.122.1 definitions=2022-09-08_06,2022-09-07_02,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 priorityscore=1501 suspectscore=0 clxscore=1011 mlxscore=0 impostorscore=0 adultscore=0 spamscore=0 mlxlogscore=999 malwarescore=0 lowpriorityscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2207270000 definitions=main-2209080040 ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1662636287; a=rsa-sha256; cv=none; b=yM9Lnjw5RawbMT2fsdOFFqerOuYW6XpMps1aI41e25tUyvZdTZav5pX8PrKeNq7bPSg+eF NfoUUwGFJhlIgrcycqeOPksGkS+5bwtT1B0eG4UdUv7t7LX8tGgZi12HzXqYbyjwuSYKqs OEnMzkK49YuBU+KuZDXypUSzp9/USPc= ARC-Authentication-Results: i=1; imf18.hostedemail.com; dkim=pass header.d=ibm.com header.s=pp1 header.b=l0B1FT+t; spf=pass (imf18.hostedemail.com: domain of rppt@linux.ibm.com designates 148.163.156.1 as permitted sender) smtp.mailfrom=rppt@linux.ibm.com; dmarc=pass (policy=none) header.from=ibm.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1662636287; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=AlvwoiXcWmTt4XPcR/9fgVZLjS0MEKff4YeJmUQI89o=; b=G6E2a0oe5aFMR7lW+lT9jBLNmtQPjWV6PmDaLHBEUrSVf0GjVn2Iu6bkrNGkJYbLqLGFxl yUMwf8SfO63z13Y3cxH6hs/Zu6pF4iQ4uT2Ux+Mg9AVs1OzdG8MY4S+m2VYLhMMEUgtbxh /0dYV1weGgdZqxDGqbJS8BenRvbwULI= Authentication-Results: imf18.hostedemail.com; dkim=pass header.d=ibm.com header.s=pp1 header.b=l0B1FT+t; spf=pass (imf18.hostedemail.com: domain of rppt@linux.ibm.com designates 148.163.156.1 as permitted sender) smtp.mailfrom=rppt@linux.ibm.com; dmarc=pass (policy=none) header.from=ibm.com X-Stat-Signature: bkhptqifnot43jdmxm6h76zkgdrc5uts X-Rspam-User: X-Rspamd-Server: rspam10 X-Rspamd-Queue-Id: A64061C0075 X-HE-Tag: 1662636287-411557 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 Thu, Sep 08, 2022 at 12:43:36PM +0200, Lukas Bulwahn wrote: > Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT") > introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED > and just gives that intent a much better name. That has been clearly a good > and long overdue renaming, and it is clearly an improvement to the kernel > build configuration that has shown to help managing the kernel build > configuration in the last decade. > > However, rather than bravely and radically just deleting CONFIG_EMBEDDED, > this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it > open for future contributors to implement that intended semantics: > > A new CONFIG_EMBEDDED option is added that automatically selects > CONFIG_EXPERT when enabled and can be used in the future to isolate > options that should only be considered for embedded systems (RISC > architectures, SLOB, etc). > > Since then, this CONFIG_EMBEDDED implicitly had two purposes: > > - It can make even more options visible beyond what CONFIG_EXPERT makes > visible. In other words, it may introduce another level of enabling the > visibility of configuration options: always visible, visible with > CONFIG_EXPERT and visible with CONFIG_EMBEDDED. > > - Set certain default values of some configurations differently, > following the assumption that configuring a kernel build for an > embedded system generally starts with a different set of default values > compared to kernel builds for all other kind of systems. > > Considering the second purpose, note that already probably arguing that a > kernel build for an embedded system would choose some values differently is > already tricky: the set of embedded systems with Linux kernels is already > quite diverse. Many embedded system have powerful CPUs and it would not be > clear that all embedded systems just optimize towards one specific aspect, > e.g., a smaller kernel image size. So, it is unclear if starting with "one > set of default configuration" that is induced by CONFIG_EMBEDDED is a good > offer for developers configuring their kernels. > > Also, the differences of needed user-space features in an embedded system > compared to a non-embedded system are probably difficult or even impossible > to name in some generic way. > > So it is not surprising that in the last decade hardly anyone has > contributed changes to make something default differently in case of > CONFIG_EMBEDDED=y. > > Currently, in v6.0-rc4, SECRETMEM is the only config switched off if > CONFIG_EMBEDDED=y. > > As long as that is actually the only option that currently is selected or > deselected, it is better to just make SECRETMEM configurable at build time > by experts using menuconfig instead. > > Make SECRETMEM configurable when EXPERT is set and otherwise default to > yes. Further, SECRETMEM needs ARCH_HAS_SET_DIRECT_MAP. > > This allows us to remove CONFIG_EMBEDDED in the close future. > > Signed-off-by: Lukas Bulwahn Acked-by: Mike Rapoport > --- > mm/Kconfig | 8 +++++++- > 1 file changed, 7 insertions(+), 1 deletion(-) > > diff --git a/mm/Kconfig b/mm/Kconfig > index ceec438c0741..aa154c20b129 100644 > --- a/mm/Kconfig > +++ b/mm/Kconfig > @@ -1068,7 +1068,13 @@ config IO_MAPPING > bool > > config SECRETMEM > - def_bool ARCH_HAS_SET_DIRECT_MAP && !EMBEDDED > + default y > + bool "Enable memfd_secret() system call" if EXPERT > + depends on ARCH_HAS_SET_DIRECT_MAP > + help > + Enable the memfd_secret() system call with the ability to create > + memory areas visible only in the context of the owning process and > + not mapped to other processes and other kernel page tables. > > config ANON_VMA_NAME > bool "Anonymous VMA name support" > -- > 2.17.1 > -- Sincerely yours, Mike.