Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1158153 > unrolled thread

Re: [PATCH] modules: CONFIG_MODULE_COMPRESS: add hint that userspace support may easily be missing.

Started byRusty Russell <rusty@rustcorp.com.au>
First post2015-06-04 04:00 +0200
Last post2015-06-07 08:20 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH] modules: CONFIG_MODULE_COMPRESS: add hint that userspace support may easily be missing. Rusty Russell <rusty@rustcorp.com.au> - 2015-06-04 04:00 +0200
    Re: [PATCH] modules: CONFIG_MODULE_COMPRESS: add hint that userspace  support may easily be missing. Lucas De Marchi <lucas.de.marchi@gmail.com> - 2015-06-07 08:20 +0200

#1158153 — Re: [PATCH] modules: CONFIG_MODULE_COMPRESS: add hint that userspace support may easily be missing.

FromRusty Russell <rusty@rustcorp.com.au>
Date2015-06-04 04:00 +0200
SubjectRe: [PATCH] modules: CONFIG_MODULE_COMPRESS: add hint that userspace support may easily be missing.
Message-ID<pxsBQ-2wB-7@gated-at.bofh.it>
Lucas De Marchi <lucas.de.marchi@gmail.com> writes:
> On Mon, Jun 1, 2015 at 3:26 AM, Rusty Russell <rusty@rustcorp.com.au> wrote:
>> Andreas Mohr <andi@lisas.de> writes:
>>> Hi,
>>>
>>> I just had a not so nice experience
>>> when finally upgrading to a new 4.1-rc5
>>> with CONFIG_MODULE_COMPRESS newly enabled -
>>> userspace binary parts (kmod 18 or 20 in my case)
>>> did not have compression enabled
>>> (at least on Debian 8pre, vs. encountering it enabled on FC21)
>>> since it does not seem to be
>>> the default build configuration of kmod (yet?).
>>
>> Sure.  Let's get the maintainers to insert the actual version required
>> in the help text though.
>
> kmod supports gz since the first version and xz since version 3.  So both
> of them can be safely fall into "it's supported since the beginning of
> kmod IMO".

Thanks, that's what I needed.

But disappointing that Debian doesn't configure with it, and there's no
easy way to check it.  Looks like Ubuntu vivid is the same.

Might be time to change the default in kmod?

Anyway, here's my patch, comments welcome.

Subject: modules: clarify CONFIG_MODULE_COMPRESS help, suggest 'N'.

Andreas turned this option on, only to find out Debian (and Ubuntu!)
don't enable support in their kmod builds.

Shorten the text, and suggest N at the bottom (at least for now).

Reported-by: Andreas Mohr <andim2@users.sf.net>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>

diff --git a/init/Kconfig b/init/Kconfig
index 968a001790af..5422c44be5f0 100644
--- a/init/Kconfig
+++ b/init/Kconfig
@@ -1948,26 +1948,22 @@ config MODULE_COMPRESS
 	bool "Compress modules on installation"
 	depends on MODULES
 	help
-	  This option compresses the kernel modules when 'make
-	  modules_install' is run.
 
-	  The modules will be compressed either using gzip or xz depend on the
-	  choice made in "Compression algorithm".
+	  Compresses kernel modules when 'make modules_install' is run; gzip or
+	  xz depending on "Compression algorithm" below.
 
-	  module-init-tools has support for gzip format while kmod handle gzip
-	  and xz compressed modules.
+	  module-init-tools supports gzip, and kmod can be configured to handle
+	  gzip and xz (but doesn't by default, at least as of version 18!).
 
-	  When a kernel module is installed from outside of the main kernel
-	  source and uses the Kbuild system for installing modules then that
-	  kernel module will also be compressed when it is installed.
+	  Out-of-tree kernel modules installed using Kbuild will also be
+	  compressed upon installation.
 
-	  This option provides little benefit when the modules are to be used inside
-	  an initrd or initramfs, it generally is more efficient to compress the whole
-	  initrd or initramfs instead.
+	  Note: for modules inside an initrd or initramfs, it's more efficient
+	  to compress the whole initrd or initramfs instead.
 
-	  This is fully compatible with signed modules while the signed module is
-	  compressed. module-init-tools or kmod handles decompression and provide to
-	  other layer the uncompressed but signed payload.
+	  Note: This is fully compatible with signed modules.
+
+	  If in doubt, say N.
 
 choice
 	prompt "Compression algorithm"
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [next] | [standalone]


#1159997 — Re: [PATCH] modules: CONFIG_MODULE_COMPRESS: add hint that userspace support may easily be missing.

FromLucas De Marchi <lucas.de.marchi@gmail.com>
Date2015-06-07 08:20 +0200
SubjectRe: [PATCH] modules: CONFIG_MODULE_COMPRESS: add hint that userspace support may easily be missing.
Message-ID<pyC65-7F5-3@gated-at.bofh.it>
In reply to#1158153
On Thu, Jun 4, 2015 at 5:22 PM, Rusty Russell <rusty@rustcorp.com.au> wrote:
> Lucas De Marchi <lucas.de.marchi@gmail.com> writes:
>>> +         gzip and xz (but doesn't by default, at least as of version 18!).
>>
>> This is pretty much misleading. There's no such a default option. It's
>> like saying kernel doesn't support feature X, Y or Z by default
>> because make defconfig doesn't turn them on.
>
> Nobody except Linus expects a defconfig to boot.
>
> I expect ./configure to give me a working tool; these *are* defaults,
> and setting them *is* your responsibility as author.  When it became an
> in-kernel option rather than some weird distro thing, the old default
> was wrong.
>
> ... Though I hadn't realized that Marco had deliberately decided to
> leave support off.  Surprising, since liblzma and libz seem required on
> Debian anyway.

As you can see, no default to something else will make distros adopt that.
I long ago decided not to provide a default for compression because it's
clearly not agreed upon.  Instead it's everything disabled and the
distro chooses what it wants to support.

So if you think the configuration for your distro should be something else,
convince the maintainer to change it showing why it's important.

FYI I'm adding in kmod the ability to query the flags used during build. So
now we have:

$ ./tools/kmod --version
kmod version 20
+XZ +ZLIB -EXPERIMENTAL

This will be present in kmod 21

-- 
Lucas De Marchi
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web