Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix modinfo error #57

Closed
wants to merge 6 commits into from
Closed

Conversation

reagentoo
Copy link

@reagentoo reagentoo commented Feb 2, 2024

gen_moddeps.sh: always include firmware for built-in modules with ALLFIRMWARE="no"

These do not occur in the "modules.dep" file so they won't be caught by the
dependency scanning loop in gen_dep_list() - they need to be manually added
to the module list.

Closes: #54
Signed-off-by: Maciej S. Szmigiero <mail@maciej.szmigiero.name>
gen_moddeps.sh: use KEXT along with default '.ko' extension to prevent modinfo error

Also improved gen_dep_list() and get rid xbasename()

Bug: https://bugs.gentoo.org/922663
Closes: #57
Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>
gen_initramfs.sh: copy compressed firmwares

Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>
gen_initramfs.sh: unpack compressed modules/firmwares to reduce image size

Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>
gen_initramfs.sh: fix gen_die message in append_modules()

Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>
gen_configkernel.sh: add priority kernel config in determine_kernel_config_file()

This is useful for building an image with sys-kernel/gentoo-kernel.

Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>

reagentoo added a commit to reagentoo/genkernel that referenced this pull request Feb 2, 2024
…t modinfo error

Also improved gen_dep_list() and get rid xbasename()

Bug: https://bugs.gentoo.org/922663
Closes: gentoo#57
Signed-off-by: Dmitry Baranov <reagentoo@gmail.com>
@maciejsszmigiero
Copy link

Tested this PR and the use case from #54 seems okay, as long as sys-kernel/linux-firmware has USE="-compress-xz".

With USE="compress-xz" (and probably other compress-* options too) the firmware files aren't included in the initramfs, so this will probably need a separate fix.

@reagentoo reagentoo marked this pull request as draft February 5, 2024 07:28
@reagentoo
Copy link
Author

With USE="compress-xz" (and probably other compress-* options too) the firmware files aren't included in the initramfs, so this will probably need a separate fix.

I also don't like that modules.dep can contain multiple extensions: .ko and .ko.xz. For example: uncompressed extended modules (e.g. sys-fs/zfs-kmod) and compressed all gentoo-kernel's modules. I think we need to add IUSE modules-compress in virtual/dist-kernel and upgrade linux-mod-r1.eclass to restrict usage different modules-compress for all packages. Converting PR to draft...

@mgorny Can you please suggest?

@maciejsszmigiero
Copy link

I also don't like that modules.dep can contain multiple extensions: .ko and .ko.xz
For example: uncompressed extended modules (e.g. sys-fs/zfs-kmod) and compressed all gentoo-kernel's modules.

I had compressed firmware (sys-kernel/linux-firmware) on mind, not modules.

@reagentoo
Copy link
Author

I also don't like that modules.dep can contain multiple extensions: .ko and .ko.xz
For example: uncompressed extended modules (e.g. sys-fs/zfs-kmod) and compressed all gentoo-kernel's modules.

I had compressed firmware (sys-kernel/linux-firmware) on mind, not modules.

I understood you. But I think you correctly pointed out earlier that this is a separate fix for future PRs.
I would also like your opinion on modules and modules-compress IUSE.

@maciejsszmigiero
Copy link

I would also like your opinion on modules and modules-compress IUSE.

I think that supporting compressed modules and firmware in genkernel would make a lot of sense, considering it's only a matter of wildcard matching filename{,.xz,.zstd} for firmware or filename.ko{,.gz,.xz,.zstd} for modules.

reagentoo added a commit to reagentoo/genkernel that referenced this pull request Mar 6, 2024
…t modinfo error

Also improved gen_dep_list() and get rid xbasename()

Bug: https://bugs.gentoo.org/922663
Closes: gentoo#57
Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>
reagentoo added a commit to reagentoo/genkernel that referenced this pull request Mar 6, 2024
…t modinfo error

Also improved gen_dep_list() and get rid xbasename()

Bug: https://bugs.gentoo.org/922663
Closes: gentoo#57
Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>
@reagentoo
Copy link
Author

reagentoo commented Mar 6, 2024

@FlyingWaffleDev @maciejsszmigiero Please test PR on your configurations.
Note:

  • added support for compressed modules/firmwares
  • auto use kernel-config from packaged kernels (sys-kernel/gentoo-kernel)

@maciejsszmigiero
Copy link

I have tested this PR and it works fine with XZ-compressed sys-kernel/linux-firmware, including for modules built into kernel.

@reagentoo reagentoo marked this pull request as ready for review March 16, 2024 09:01
@reagentoo
Copy link
Author

@robbat2 @thesamesam Look here please.

maciejsszmigiero and others added 6 commits April 27, 2024 14:44
…FIRMWARE="no"

These do not occur in the "modules.dep" file so they won't be caught by the
dependency scanning loop in gen_dep_list() - they need to be manually added
to the module list.

Closes: gentoo#54
Signed-off-by: Maciej S. Szmigiero <mail@maciej.szmigiero.name>
…t modinfo error

Also improved gen_dep_list() and get rid xbasename()

Bug: https://bugs.gentoo.org/922663
Closes: gentoo#57
Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>
Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>
… size

Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>
Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>
…onfig_file()

This is useful for building an image with sys-kernel/gentoo-kernel.

Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>
@thesamesam
Copy link
Member

@benkohler

gentoo-bot pushed a commit that referenced this pull request May 20, 2024
…onfig_file()

This is useful for building an image with sys-kernel/gentoo-kernel.

Signed-off-by: Dmitriy Baranov <reagentoo@gmail.com>
Closes: #57
Signed-off-by: Ben Kohler <bkohler@gentoo.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants