public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* Building and integrating CorebootPayloadPkg
@ 2016-10-31 13:07 Janne Heß
  2016-11-01  5:13 ` Scott Duplichan
  0 siblings, 1 reply; 2+ messages in thread
From: Janne Heß @ 2016-10-31 13:07 UTC (permalink / raw)
  To: edk2-devel

[-- Attachment #1: Type: text/plain, Size: 1347 bytes --]

Hello everyone,

I'm currently trying to build CorebootPayloadPkg to integrate it into my
coreboot.
I follewed the instructions in
CorebootPayloadPkg/BuildAndIntegrationInstructions.txt to build
UEFIPAYLOAD.fd.
The instructions tell me to add choose this file as an executable elf
payload in the coreboot configuration.
Now, when building coreboot, I end up with the following output:

> Performing operation on 'COREBOOT' region...
> E: The stage file is not in ELF format!
> E: skipping 32 bytes of FV padding
> E: skipping 28 bytes of section padding
> E: Could not add [UEFIPAYLOAD.fd, 852750 bytes (832 KB)@0x0]; too big?
> E: Failed to add 'UEFIPAYLOAD.fd' into ROM image.
> E: Failed while operating on 'COREBOOT' region!
> E: The image will be left unmodified.
> make: *** [build/coreboot.pre] Error 1

As the script tells me to check if the payload is too big, I set my BIOS
chip size to 12 MB in the config just to make sure this is not a problem.
This didn't help.
I also asked on #coreboot, where I was told to use the cbfstool to
include my payload which failed with the same message.

So to me it looks like whatever UEFIPAYLOAD.fd is, it is not a Coreboot
payload.
Are there any commands missing from the documentation that I need to
build a valid payload?

Thanks in advance.

Regards
Janne



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 801 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Building and integrating CorebootPayloadPkg
  2016-10-31 13:07 Building and integrating CorebootPayloadPkg Janne Heß
@ 2016-11-01  5:13 ` Scott Duplichan
  0 siblings, 0 replies; 2+ messages in thread
From: Scott Duplichan @ 2016-11-01  5:13 UTC (permalink / raw)
  To: 'Janne Heß', edk2-devel


]From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Janne Heß
]Sent: Monday, October 31, 2016 08:08 AM
]To: edk2-devel@lists.01.org
]Subject: [edk2] Building and integrating CorebootPayloadPkg
]
]Hello everyone,
]
]I'm currently trying to build CorebootPayloadPkg to integrate it into my
]coreboot.
]I follewed the instructions in
]CorebootPayloadPkg/BuildAndIntegrationInstructions.txt to build
]UEFIPAYLOAD.fd.
]The instructions tell me to add choose this file as an executable elf
]payload in the coreboot configuration.
]Now, when building coreboot, I end up with the following output:
]
]> Performing operation on 'COREBOOT' region...
]> E: The stage file is not in ELF format!
]> E: skipping 32 bytes of FV padding
]> E: skipping 28 bytes of section padding
]> E: Could not add [UEFIPAYLOAD.fd, 852750 bytes (832 KB)@0x0]; too big?
]> E: Failed to add 'UEFIPAYLOAD.fd' into ROM image.
]> E: Failed while operating on 'COREBOOT' region!
]> E: The image will be left unmodified.
]> make: *** [build/coreboot.pre] Error 1
]
]As the script tells me to check if the payload is too big, I set my BIOS
]chip size to 12 MB in the config just to make sure this is not a problem.
]This didn't help.
]I also asked on #coreboot, where I was told to use the cbfstool to
]include my payload which failed with the same message.
]
]So to me it looks like whatever UEFIPAYLOAD.fd is, it is not a Coreboot
]payload.
]Are there any commands missing from the documentation that I need to
]build a valid payload?
]
]Thanks in advance.
]
]Regards
]Janne


You should ignore the message:
    E: The stage file is not in ELF format!

Cbfstool is complaining about the size, after compression, of the payload.
I don't know why your attempt to expand the flash size failed. I never
tried that because the board I was using is limited to 1MB of flash.
For that board, I could make a CorebootPayloadPkg release build fit,
but not a NOOPT build.

Here is a passing example:
   $ build/cbfstool build/coreboot.rom add-payload -f /l/edk2build/edk2/Build/CorebootPayloadPkgX64/RELEASE_VS2010x86/FV/UEFIPAYLOAD.fd -n fallback/payload -c lzma
   E: The stage file is not in ELF format!
   E: skipping 32 bytes of FV padding
   E: skipping 28 bytes of section padding

   $ build/cbfstool build/coreboot.rom print
   coreboot.rom: 1024 kB, bootblocksize 960, romsize 1048576, offset 0x0
   alignment: 64 bytes, architecture: x86

   Name                           Offset     Type         Size
   cmos_layout.bin                0x0        cmos_layout  1776
   pci1002,9610.rom               0x740      optionrom    65536
   cpu_microcode_blob.bin         0x10780    microcode    14336
   fallback/romstage              0x14000    stage        84225
   fallback/ramstage              0x28940    stage        84072
   (empty)                        0x3d200    null         55640
   config                         0x4ab80    raw          4900
   revision                       0x4bf00    raw          701
   fallback/payload               0x4c200    payload      630897
   (empty)                        0xe62c0    null         104728

Here is a failing example:
   $ build/cbfstool build/coreboot.rom remove -n fallback/payload

   $ build/cbfstool build/coreboot.rom add-payload -f /l/edk2build/edk2/Build/CorebootPayloadPkgX64/NOOPT_VS2010x86/FV/UEFIPAYLOAD.fd -n fallback/payload -c lzma
   E: The stage file is not in ELF format!
   E: skipping 32 bytes of FV padding
   E: skipping 28 bytes of section padding
   E: Could not add [L:/edk2build/edk2/Build/CorebootPayloadPkgX64/NOOPT_VS2010x86/FV/UEFIPAYLOAD.fd, 855646 bytes (835 KB)@0x0]; too big?
   E: Failed to add 'L:/edk2build/edk2/Build/CorebootPayloadPkgX64/NOOPT_VS2010x86/FV/UEFIPAYLOAD.fd' into ROM image.

Thanks,
Scott






^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-11-01  5:23 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-10-31 13:07 Building and integrating CorebootPayloadPkg Janne Heß
2016-11-01  5:13 ` Scott Duplichan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox