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

RFC: bzImage / initrd support #428

Closed
wants to merge 2 commits into from
Closed

RFC: bzImage / initrd support #428

wants to merge 2 commits into from

Conversation

tim-deegan-aws
Copy link
Contributor

I put this together for testing embedded images where I couldn't easily build my own ELF vmlinux. I'm not sure if this is something you want at all. :) I see it's explicitly not on the customer milestones and it's slower than booting an ELF because of the decompression time. If it is useful I can add some unit tests &c. If not, nbd.

Tries loading as ELF first, then falls back to bzImage.
bzImage is slower to boot than ELF, because the kernel has to
decompress itself.

Added an init_size field to the bootparams block, which the
decompressor uses to know how much space it has to work with.  Made it
big enough for a moderate sized kernel.  We really ought to be extracting
the bootparams block from the kernel instead.

Signed-off-by: Tim Deegan <tdeegan@amazon.com>
Plumb through an optional initrd path from the REST API, and load it
at a fixed address.

Signed-off-by: Tim Deegan <tdeegan@amazon.com>
@rn
Copy link
Contributor

rn commented Oct 20, 2018

You can uncompress a bzImage with extract-vmlinux and maybe use squashfs as rootfs (faster boot, less memory usage). See also https://github.com/linuxkit/linuxkit/blob/master/contrib/crosvm/README.md

But, in general, bzImage and initrd support would be nice to have.

@tim-deegan-aws
Copy link
Contributor Author

I have rebased this but the source repo was removed, so I needed to make a new PR: #670

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.

None yet

3 participants