Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp5415358yba; Wed, 10 Apr 2019 19:48:15 -0700 (PDT) X-Google-Smtp-Source: APXvYqxPcKuAyXRBU8giUHY1Z2rHIqDq2AvW2s/1uguzqQ4YKKER92BIwvPi1OPtTDRDnC92DK2z X-Received: by 2002:a17:902:8d89:: with SMTP id v9mr47634337plo.230.1554950895842; Wed, 10 Apr 2019 19:48:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554950895; cv=none; d=google.com; s=arc-20160816; b=HG/CHIRGN50fEFmCN4hiXZ7mZd74GHQt6Ptrn+ZpApAFOpFpAgNlf6Jm+4t81HcpZi EoPXhCmqkFUybeKkhIllatkpmYRmjjj5V0SObsHn8bJrsbXwG66W2q58cVfCxVzLGqYB uFGYryzdnyCYpWRSZvLGnTLJKV6K9HwEnkq+UcTLTMdsIRtiLNjVpQd+cF55JB19QJf2 swTdMpg2I+THe+0RSFmMYX46wmIjov4rYU85LKfg6/EBgYSQYNVqvyawR29Bs2AifzB8 4jbc5sfn+OJKoAYj73iqzCCfMtuxYwfjid90zDm77lIOiHuVR1GXaLEMoE51qlZLp4dR VczA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=7h8a+DAJL8hqysadYjKn6udNQom9LPAme8QIHO+0C3c=; b=c7quB0OuuYlvzfAr/1y4tXfCSorpsyY1sAwea77XdQd8zFcstb1YJdxWZx24YXPXFl t1Y4jdMw4i5mdzxCXZFqkK06PTzprV/0YNJS/xgHI/ACX6AFcB/MWzeYGC20ObMYhvvg owcf83AcjKfW3d1Fgb+HLgiJq8ZicHuS4nlskpPwfi6n6OewMxyjqpOYARNbE/klJ8fF px4QIyHG+KaGadw7l6TVWWc1OeYbTImYBIXwEAAamQ1H8E1P8YdCHOs9R/MnQZZPNXiH WFBv93zFH6MP24ZFrWNWPwVlxpl7CKS5d9lfJGtmufxWuqYMH2Fg9A2xQJTK4V1pM4TX 2Myg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=KlAIUqIx; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t17si31406265pgv.493.2019.04.10.19.48.00; Wed, 10 Apr 2019 19:48:15 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=KlAIUqIx; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726785AbfDKCpz (ORCPT + 99 others); Wed, 10 Apr 2019 22:45:55 -0400 Received: from mail-vs1-f65.google.com ([209.85.217.65]:34029 "EHLO mail-vs1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726615AbfDKCpz (ORCPT ); Wed, 10 Apr 2019 22:45:55 -0400 Received: by mail-vs1-f65.google.com with SMTP id t78so2630470vsc.1 for ; Wed, 10 Apr 2019 19:45:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=7h8a+DAJL8hqysadYjKn6udNQom9LPAme8QIHO+0C3c=; b=KlAIUqIxxmcZ08qH5i3m8xv/hSw2NOeltTNqKv1oMrmpP12o7GQ1Pa0iDslYClGBT/ VN8FWKctABfFTAzLEzCbqb1WWL9YWZinF5hcWdORbQi9Gr6Pu/Wgt+ba1wcmydMSFUsj tJP24DNDeIoMx75nyGBFLQ/bi20yCPDCBLvUE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=7h8a+DAJL8hqysadYjKn6udNQom9LPAme8QIHO+0C3c=; b=FQKc5AZgkTzRvdRevR/Gyte5NKHXXQFI8J7IwIkyCHQCdBA7SB9Yhxru1pMWN5Rqbw L7HO/cKLOg45/H4sAklxoR5gtMBVyVCvlIpYSsboC3uSN2wIfyrk63E/mS+2p5huxJWi zTVZdp1xWNhDfvs14cUN7ZMJ92+Wxon7X+gfgwIAIgO4B3csrQ2TOicig2qPyEO9d7RE atM2tJ7Z7nNNP67sz6kjmIs/FQbn3iXfIaIHBOPhy+vsubBGwBxb+4GFh5Crb9KH9BQ2 XxI8DzalaTPOSBG0wd+6309qG8FksLn80U4XOVD9sQ5lvAFjfru8thgdwIep8jKh8K41 +ftg== X-Gm-Message-State: APjAAAWciLN7yvdTDc83EXh2NpNEVIY3U80NeIO2z60vgY9NN9dwXOMV 0GvHDdJBV0K4pykTlDLxwwRgaMCc/SE= X-Received: by 2002:a67:f753:: with SMTP id w19mr25789709vso.27.1554950754322; Wed, 10 Apr 2019 19:45:54 -0700 (PDT) Received: from mail-ua1-f48.google.com (mail-ua1-f48.google.com. [209.85.222.48]) by smtp.gmail.com with ESMTPSA id 2sm16844042vke.27.2019.04.10.19.45.53 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 10 Apr 2019 19:45:54 -0700 (PDT) Received: by mail-ua1-f48.google.com with SMTP id h4so1511073uaj.9 for ; Wed, 10 Apr 2019 19:45:53 -0700 (PDT) X-Received: by 2002:ab0:a97:: with SMTP id d23mr8084301uak.99.1554950355141; Wed, 10 Apr 2019 19:39:15 -0700 (PDT) MIME-Version: 1.0 References: <20190411005634.8495-1-okaya@kernel.org> In-Reply-To: <20190411005634.8495-1-okaya@kernel.org> From: Kees Cook Date: Wed, 10 Apr 2019 19:39:03 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v3] init: Do not select DEBUG_KERNEL by default To: Sinan Kaya , Masahiro Yamada Cc: LKML , Josh Triplett , Kees Cook , Andrew Morton , "Peter Zijlstra (Intel)" , Johannes Weiner , Nicholas Piggin , Mathieu Desnoyers , Vasily Gorbik , Adrian Reber , Richard Guy Briggs , Andy Shevchenko , Petr Mladek , Joe Lawrence , Matthew Wilcox , Randy Dunlap , Mikulas Patocka , Robin Murphy , Tetsuo Handa , Changbin Du Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Apr 10, 2019 at 5:56 PM Sinan Kaya wrote: > > We can't seem to have a kernel with CONFIG_EXPERT set but > CONFIG_DEBUG_KERNEL unset these days. > > While some of the features under the CONFIG_EXPERT require > CONFIG_DEBUG_KERNEL, it doesn't apply for all features. > > It looks like CONFIG_KALLSYMS_ALL is the only feature that > requires CONFIG_DEBUG_KERNEL. > > Select CONFIG_EXPERT when CONFIG_DEBUG_KERNEL is chosen but > you can still choose CONFIG_EXPERT without CONFIG_DEBUG_KERNEL. > > Signed-off-by: Sinan Kaya > Reviewed-by: Kees Cook Masahiro, should this go via your tree, or somewhere else? Thanks! -Kees > --- > init/Kconfig | 2 -- > lib/Kconfig.debug | 1 + > 2 files changed, 1 insertion(+), 2 deletions(-) > > diff --git a/init/Kconfig b/init/Kconfig > index 4592bf7997c0..37e10a8391a3 100644 > --- a/init/Kconfig > +++ b/init/Kconfig > @@ -1206,8 +1206,6 @@ config BPF > > menuconfig EXPERT > bool "Configure standard kernel features (expert users)" > - # Unhide debug options, to make the on-by-default options visible > - select DEBUG_KERNEL > help > This option allows certain base kernel options and settings > to be disabled or tweaked. This is for specialized > diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug > index 0d9e81779e37..9fbf3499ec8d 100644 > --- a/lib/Kconfig.debug > +++ b/lib/Kconfig.debug > @@ -434,6 +434,7 @@ config MAGIC_SYSRQ_SERIAL > > config DEBUG_KERNEL > bool "Kernel debugging" > + default EXPERT > help > Say Y here if you are developing drivers or trying to debug and > identify kernel problems. > -- > 2.21.0 > -- Kees Cook