[Buildroot] [PATCH v1 3/9] board/intel/common: Add possibility for adding ACPI tables to the initrd

Thomas Petazzoni thomas.petazzoni at free-electrons.com
Fri Aug 26 09:30:22 UTC 2016


Hello,

On Fri, 26 Aug 2016 12:04:54 +0300, Mika Westerberg wrote:

> > On 25-08-16 16:04, Andy Shevchenko wrote:  
> > > Add script which takes ASL files as input, compiles them to AML bytecode,
> > > and prepends the whole thing to the initrd archive. They are placed in
> > > kernel/firmware/acpi directory where the kernel is able to find and use
> > > them.  
> > 
> >  Why is this a post-image script, and not just a post-build script that copies
> > everything in the right place and lets the cpio rootfs take care of generating
> > the cpio? AFAIK there is no particular requirement for this stuff to be at the
> > beginning of the cpio image, is there?  
> 
> Actually there is - the kernel looks only from the first uncompressed
> cpio archive for these additional AML files.

Still not clear: Arnout doesn't suggest to generate multiple cpio
archives, but rather to simply have the AML files within the cpio
archive in the first place.

The Buildroot process looks like this:

 1. Build all packages
 2. Run post-build scripts
 3. Create filesystem images (including cpio one)
 4. Run post-image scripts

Right now, if I understand correctly, in step (4), you're generating an
additional initrd with just the AML files. Is this correct?

What about instead having things done in step (2): install the AML
files at the appropriate places in $(TARGET_DIR) so that they
automatically end up in the rootfs.cpio generated by Buildroot?

In this case, there's a single initrd, which contains both the root
filesystem itself and the AML files.

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com


More information about the buildroot mailing list