[coreboot] Rettungsboot

David Hendricks dhendrix at google.com
Mon Nov 28 20:26:11 CET 2016

On Sun, Nov 27, 2016 at 8:28 PM, ron minnich <rminnich at gmail.com> wrote:

> yeah, david and nico both make very good points. I like the idea of  JSON
> file, and further we're working on a Go program
> on the u-root project that would parse said file (trivial in Go to parse
> JSON, it's one statement and blam! your Go struct is all
> filled in) and then decide what to configure/what to download/how to
> validate (we have a gpgv command written in Go by
> Eric Grosse) and then how to kexec it.
> I think what we're doing might be useful?

Now we're talkin' - A standardized data format that is human
readable/writeable that can be easily parsed and generated using small
libraries. It looks like Go can already handle it easily, for C we could
maybe use JSMN (http://zserge.com/jsmn.html) or something similar. I think
that addresses Nico's first point.

For the other points, I imagine we'd have two varieties of the JSON file.
One would be generated along with the payload and included as a CBFS file
to specify things like capabilities and bootable device priority*. The
other would be on the bootable media and specify things like the kernel
path and parameters. A tool which is used to generate the latter would
verify the capabilities and warn the user if their coreboot payload lacks
support for something.

*Stuff like boot device priority might need some more thought since CMOS
may be a preferable way of controlling something like that. However given
that CMOS might not exist on a particular platform (especially in the
non-x86 world) replacing the config file in CBFS file might not be a bad
way to go.

David Hendricks (dhendrix)
Systems Software Engineer, Google Inc.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.coreboot.org/pipermail/coreboot/attachments/20161128/aef902a4/attachment.html>

More information about the coreboot mailing list