linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Masahiro Yamada <masahiroy@kernel.org>
To: Linux Kbuild mailing list <linux-kbuild@vger.kernel.org>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Chris Wilson <chris@chris-wilson.co.uk>,
	David Howells <dhowells@redhat.com>,
	Johannes Weiner <hannes@cmpxchg.org>,
	Kees Cook <keescook@chromium.org>,
	Nathan Chancellor <nathan@kernel.org>,
	Nick Desaulniers <ndesaulniers@google.com>,
	Nick Terrell <terrelln@fb.com>,
	Valentin Schneider <valentin.schneider@arm.com>,
	Vlastimil Babka <vbabka@suse.cz>
Subject: Re: [PATCH 9/9] kbuild: remove CONFIG_MODULE_COMPRESS
Date: Wed, 7 Apr 2021 23:29:27 +0900	[thread overview]
Message-ID: <CAK7LNASCmTMtS+4MxTKJDcdCxtDfBTgXkZPUssjrWbmoPYuwAA@mail.gmail.com> (raw)
In-Reply-To: <20210331133811.3221540-9-masahiroy@kernel.org>

On Wed, Mar 31, 2021 at 10:39 PM Masahiro Yamada <masahiroy@kernel.org> wrote:
>
> 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 <masahiroy@kernel.org>
> ---
>
>  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
> -       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


This should be "Compress modules with GZIP."


I will fix it when applied.







> +         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
>


-- 
Best Regards
Masahiro Yamada

  parent reply	other threads:[~2021-04-07 14:30 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-31 13:38 [PATCH 1/9] kbuild: remove unneeded mkdir for external modules_install Masahiro Yamada
2021-03-31 13:38 ` [PATCH 2/9] kbuild: unify modules(_install) for in-tree and external modules Masahiro Yamada
2021-03-31 13:38 ` [PATCH 3/9] kbuild: show the target directory for depmod log Masahiro Yamada
2021-03-31 13:38 ` [PATCH 4/9] kbuild: check module name conflict for external modules as well Masahiro Yamada
2021-03-31 13:38 ` [PATCH 5/9] kbuild: rename extmod-prefix to extmod_prefix Masahiro Yamada
2021-03-31 17:54   ` Nick Desaulniers
2021-03-31 13:38 ` [PATCH 6/9] kbuild: refactor scripts/Makefile.modinst Masahiro Yamada
2021-05-12 14:23   ` Johannes Berg
2021-03-31 13:38 ` [PATCH 7/9] kbuild: move module strip/compression code into scripts/Makefile.modinst Masahiro Yamada
2021-03-31 13:38 ` [PATCH 8/9] kbuild: merge scripts/Makefile.modsign to scripts/Makefile.modinst Masahiro Yamada
2021-03-31 13:38 ` [PATCH 9/9] kbuild: remove CONFIG_MODULE_COMPRESS Masahiro Yamada
2021-03-31 18:01   ` Nick Desaulniers
2021-04-07 14:29   ` Masahiro Yamada [this message]
2021-04-07 14:30 ` [PATCH 1/9] kbuild: remove unneeded mkdir for external modules_install Masahiro Yamada

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAK7LNASCmTMtS+4MxTKJDcdCxtDfBTgXkZPUssjrWbmoPYuwAA@mail.gmail.com \
    --to=masahiroy@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=chris@chris-wilson.co.uk \
    --cc=dhowells@redhat.com \
    --cc=hannes@cmpxchg.org \
    --cc=keescook@chromium.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nathan@kernel.org \
    --cc=ndesaulniers@google.com \
    --cc=terrelln@fb.com \
    --cc=valentin.schneider@arm.com \
    --cc=vbabka@suse.cz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).