Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp600261pxf; Wed, 31 Mar 2021 11:03:03 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw2BVIvAT4+ZvnH75OxXpiVjKzMXWMnBqRwImwBZErwOe1Le1NYIVlBVuSGBbkeu/Mi0EEI X-Received: by 2002:a05:6402:354b:: with SMTP id f11mr5203207edd.361.1617213783309; Wed, 31 Mar 2021 11:03:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1617213783; cv=none; d=google.com; s=arc-20160816; b=UejHAsggwCCRPm0I5QQOHly1FnXufYl3EUcP8ocGb2pZTYAnJbebbstPvCI6r+uLbF uBb6tKZDQcLFQy8RE40tdr+xwUqRQ1qycBxRN7Uos2tn9mw/8eV+9czAwwFxrUss2J9n BLJ9CZRywlZc90kr+LOLNwwOmF5lz6RU82YLrZGIUWF6Ba540dr0fcRvgVjt7KfU4ciX iRzQnyRnjLt/Qd0j1g3r14yhkBCEL4ryRiZmB+7ab9ZDNaIJGLC+YEzjcWffh/VIkjm1 UivbXSrOgGJTQPcz6twz9+tDYaPwDvJ6y2+0k+bbpyl/OKkE7TMFkQldj0J6GJkl4R3p jPhA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=t9nMQTEmpT7k/RP+1/1nM1b4H1NgzFziXfj4iuE1q+g=; b=oC8Igrf5aAQfa7Qks20biBqLD0dMu8+IijY9IWMtsbGbxmxwLWwtvhuNEeG/iOCu69 rtm3C/jJH0GcbhU+ECJaPKk1zKFa0d0wvj+H+Q5t7FaRnsE2B3veWBcx7yLiBuc/+IMg b3IO/7kS3WdvCbgSyHGtYCDFtBo5PH0j1oL/k5kIBkQ614Gm62qfSU5VUePJPJqBGhEY TxsmB2CeKiK1BnhDjv8w5fONgXcoQCrdlJfdAcmWNK7N7wr+r+WCIunz0CvZgts39k9t PexfEM7C/W2kfLp8cTA//L1AHuCfJTFUH9MRf81zWCy0NGBRRf0+aH8ZX7EUdmPDOQFx 5bsw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=JrmLn+27; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d5si2289554edv.281.2021.03.31.11.02.39; Wed, 31 Mar 2021 11:03:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=JrmLn+27; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234466AbhCaSBg (ORCPT + 99 others); Wed, 31 Mar 2021 14:01:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35246 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234743AbhCaSBY (ORCPT ); Wed, 31 Mar 2021 14:01:24 -0400 Received: from mail-lj1-x22e.google.com (mail-lj1-x22e.google.com [IPv6:2a00:1450:4864:20::22e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D4698C06174A for ; Wed, 31 Mar 2021 11:01:23 -0700 (PDT) Received: by mail-lj1-x22e.google.com with SMTP id a1so24933880ljp.2 for ; Wed, 31 Mar 2021 11:01:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=t9nMQTEmpT7k/RP+1/1nM1b4H1NgzFziXfj4iuE1q+g=; b=JrmLn+27truBlWU70KBlFbjf3BnhN2BonvBPyaskH1q4fTarMAgSc6yxIQQvh7vW0a YIjNBvBnkM5luLwvQ45+/hFGqkBEbutTjNKLX5T0BHeci58bZe9hFmHBOfFOiaYmEJoc A39FZyF3IBRNzShPWnHJyBbQSNd+3iiVs65P4DUHh/L5FzTD4knvdzABYZw3+WPyVjea esgumkbEOwS17+xhdECxRgvsJLU0v1NqVYBBK/E8qYCFLWJvpRru8PVmvCUQ7Dtsy58B G7I/HApX73BZj+z0Tm5QiZQ91kBoqYznQumQkT7v8qAlbqlqCRI0+p1niGn/8I3UTKfv wNaw== 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=t9nMQTEmpT7k/RP+1/1nM1b4H1NgzFziXfj4iuE1q+g=; b=oVMdmYGDI3iB4nCQehw73eD3/gQ7zyCUv8WkSQk+sL9aPOR4QdES6dutxTE4wit0Mx n18B3nCRN0Fxcwf7GXLeX98i3yB/2/ECw/XmFgl7EJtaS1DQsOs3rxFdeiAbXxLfiauD pYU7WJ2bFavOgknaIyZ9FVUmxmZBHmJ/49KbPUcaLJ50W6BIOJ7VXB6ojNzH60wFT/PU znfJj1or8Kx/bGYJWSoR0a12hMLc1o6sJ8ABM8GBopbiXBgm1cS0KChge+3tUZyvTWvi I/PY9csOMZ4YqZUnHQHX6zklhmNqvZmff/bZ9ADOF9UuglpwRcnVpNNWTJU3xUDxFT0H Kw1Q== X-Gm-Message-State: AOAM532JeXR3Qvv9YRPLBMewZa3pnAvjMb1rEerJ/9VYuIeR3n0lNkUh 4pHAZixeGTS5gc1LGSjd6ZoYUR7mbvlz3oHlMmwJCw== X-Received: by 2002:a2e:868e:: with SMTP id l14mr2910204lji.479.1617213682119; Wed, 31 Mar 2021 11:01:22 -0700 (PDT) MIME-Version: 1.0 References: <20210331133811.3221540-1-masahiroy@kernel.org> <20210331133811.3221540-9-masahiroy@kernel.org> In-Reply-To: <20210331133811.3221540-9-masahiroy@kernel.org> From: Nick Desaulniers Date: Wed, 31 Mar 2021 11:01:11 -0700 Message-ID: Subject: Re: [PATCH 9/9] kbuild: remove CONFIG_MODULE_COMPRESS To: Masahiro Yamada Cc: Linux Kbuild mailing list , LKML , Andrew Morton , Chris Wilson , David Howells , Johannes Weiner , Kees Cook , Nathan Chancellor , Nick Terrell , Valentin Schneider , Vlastimil Babka Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Mar 31, 2021 at 6:39 AM Masahiro Yamada wrote: Should the online be Kconfig rather than Kbuild, for a commit that only changes Kconfigs? > > CONFIG_MODULE_COMPRESS is only used to activate the choice for module > compression algorithm. It will be simpler to make the choice visible > all the time by adding CONFIG_MODULE_COMPRESS_NONE to allow the user to > disable module compression. > > This is more consistent with the "Kernel compression mode" and "Built-in > initramfs compression mode" choices. > > CONFIG_KERNEL_UNCOMPRESSED and CONFIG_INITRAMFS_COMPRESSION_NONE are > available to choose to not compress the kernel, initrd, respectively. > > Signed-off-by: Masahiro Yamada > --- > > init/Kconfig | 45 ++++++++++++++++++++++++++------------------- > 1 file changed, 26 insertions(+), 19 deletions(-) > > diff --git a/init/Kconfig b/init/Kconfig > index 019c1874e609..3ca1ffd219c4 100644 > --- a/init/Kconfig > +++ b/init/Kconfig > @@ -2225,40 +2225,47 @@ config MODULE_SIG_HASH > default "sha384" if MODULE_SIG_SHA384 > default "sha512" if MODULE_SIG_SHA512 > > -config MODULE_COMPRESS The top level Makefile has comments and code that refer to this choice which is now removed. I think you'll want to fix that up in this change as well? Ah, patch 7 in the series does that: https://lore.kernel.org/linux-kbuild/20210331133811.3221540-7-masahiroy@kernel.org/ Ok then this LGTM. Reviewed-by: Nick Desaulniers > - bool "Compress modules on installation" > +choice > + prompt "Module compression mode" > help > + This option allows you to choose the algorithm which will be used to > + compress modules when 'make modules_install' is run. (or, you can > + choose to not compress modules at all.) > > - Compresses kernel modules when 'make modules_install' is run; gzip or > - xz depending on "Compression algorithm" below. > + External modules will also be compressed in the same way during the > + installation. > > - module-init-tools MAY support gzip, and kmod MAY support gzip and xz. > + For modules inside an initrd or initramfs, it's more efficient to > + compress the whole initrd or initramfs instead. > > - Out-of-tree kernel modules installed using Kbuild will also be > - compressed upon installation. > + This is fully compatible with signed modules. > > - Note: for modules inside an initrd or initramfs, it's more efficient > - to compress the whole initrd or initramfs instead. > + Please note that the tool used to load modules needs to support the > + corresponding algorithm. module-init-tools MAY support gzip, and kmod > + MAY support gzip and xz. > > - Note: This is fully compatible with signed modules. > + Your build system needs to provide the appropriate compression tool > + to compress the modules. > > - If in doubt, say N. > + If in doubt, select 'None'. > > -choice > - prompt "Compression algorithm" > - depends on MODULE_COMPRESS > - default MODULE_COMPRESS_GZIP > +config MODULE_COMPRESS_NONE > + bool "None" > help > - This determines which sort of compression will be used during > - 'make modules_install'. > - > - GZIP (default) and XZ are supported. > + Do not compress modules. The installed modules are suffixed > + with .ko. > > config MODULE_COMPRESS_GZIP > bool "GZIP" > + help > + Compress modules with XZ. The installed modules are suffixed > + with .ko.gz. > > config MODULE_COMPRESS_XZ > bool "XZ" > + help > + Compress modules with XZ. The installed modules are suffixed > + with .ko.xz. > > endchoice > > -- > 2.27.0 > -- Thanks, ~Nick Desaulniers