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

file: Support reading EFI zboot images #53

Closed
wants to merge 3 commits into from

Conversation

hexchain
Copy link
Contributor

This type of image is generated when the kernel has CONFIG_EFI_ZBOOT enabled.

ecleankernel/file.py Outdated Show resolved Hide resolved
@mgorny
Copy link
Member

mgorny commented Sep 21, 2024

Oh, and we're going to need a test for this file format.

@hexchain hexchain force-pushed the aarch64-zboot branch 2 times, most recently from 367ca82 to a3e6ca0 Compare September 22, 2024 16:00
@hexchain
Copy link
Contributor Author

All done.

@sbraz
Copy link

sbraz commented Oct 27, 2024

Thanks, it works with gentoo-kernel-bin:

# eclean-kernel -n 3
Legend:
[-] file being removed
[x] file does not exist (anymore)
[+] file being kept (used by other kernels)

* Removing kernel bls 6.10.5-gentoo-dist (not referenced by bootloader (symlinks))
 [-] /lib/modules/6.10.5-gentoo-dist
 [x] /efi/096c976bec474096a295d1e643e5291d/6.10.5-gentoo-dist/linux
 [x] /efi/096c976bec474096a295d1e643e5291d/6.10.5-gentoo-dist/initrd
 [x] /efi/096c976bec474096a295d1e643e5291d/6.10.5-gentoo-dist
* Removing kernel bls 6.10.4-gentoo-dist (not referenced by bootloader (symlinks))
 [-] /lib/modules/6.10.4-gentoo-dist
 [x] /efi/096c976bec474096a295d1e643e5291d/6.10.4-gentoo-dist/linux
 [x] /efi/096c976bec474096a295d1e643e5291d/6.10.4-gentoo-dist/initrd
 [x] /efi/096c976bec474096a295d1e643e5291d/6.10.4-gentoo-dist
* Removing kernel bls 6.10.3-gentoo-dist (not referenced by bootloader (symlinks))
 [-] /lib/modules/6.10.3-gentoo-dist
 [x] /efi/096c976bec474096a295d1e643e5291d/6.10.3-gentoo-dist/linux
 [x] /efi/096c976bec474096a295d1e643e5291d/6.10.3-gentoo-dist/initrd
 [x] /efi/096c976bec474096a295d1e643e5291d/6.10.3-gentoo-dist
* Removing kernel bls 6.10.2-gentoo-dist (not referenced by bootloader (symlinks))
 [-] /lib/modules/6.10.2-gentoo-dist
 [x] /efi/096c976bec474096a295d1e643e5291d/6.10.2-gentoo-dist/linux
 [x] /efi/096c976bec474096a295d1e643e5291d/6.10.2-gentoo-dist/initrd
 [x] /efi/096c976bec474096a295d1e643e5291d/6.10.2-gentoo-dist
* Removing kernel bls 6.9.10-gentoo-dist (not referenced by bootloader (symlinks))
 [-] /lib/modules/6.9.10-gentoo-dist
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.10-gentoo-dist/linux
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.10-gentoo-dist/initrd
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.10-gentoo-dist
* Removing kernel bls 6.9.9-gentoo-dist (not referenced by bootloader (symlinks))
 [-] /lib/modules/6.9.9-gentoo-dist
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.9-gentoo-dist/linux
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.9-gentoo-dist/initrd
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.9-gentoo-dist
* Removing kernel bls 6.9.8-gentoo-dist (not referenced by bootloader (symlinks))
 [-] /lib/modules/6.9.8-gentoo-dist
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.8-gentoo-dist/linux
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.8-gentoo-dist/initrd
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.8-gentoo-dist
* Removing kernel bls 6.9.7-gentoo-dist (not referenced by bootloader (symlinks))
 [-] /lib/modules/6.9.7-gentoo-dist
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.7-gentoo-dist/linux
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.7-gentoo-dist/initrd
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.7-gentoo-dist
* Removing kernel bls 6.9.4-gentoo-dist (not referenced by bootloader (symlinks))
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.4-gentoo-dist/initrd
 [-] /lib/modules/6.9.4-gentoo-dist
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.4-gentoo-dist/linux
 [x] /efi/096c976bec474096a295d1e643e5291d/6.9.4-gentoo-dist
Removed 9 kernels

Copy link
Member

@mgorny mgorny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm sorry for the delay. If you don't want to work on it anymore, please let me know and I'll finish it.

ecleankernel/file.py Outdated Show resolved Hide resolved
test/test_file.py Outdated Show resolved Hide resolved
ecleankernel/file.py Outdated Show resolved Hide resolved
ecleankernel/file.py Outdated Show resolved Hide resolved
@hexchain
Copy link
Contributor Author

Thanks for your review. I've applied all suggestions.

Copy link
Member

@mgorny mgorny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@mgorny mgorny closed this in 14b395e Oct 27, 2024
@mgorny
Copy link
Member

mgorny commented Oct 27, 2024

I'll look through other open PRs and release in the next few days.

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