Attention is currently required from: Angel Pons, Arthur Heymans.
Nico Huber has posted comments on this change by Arthur Heymans. ( https://review.coreboot.org/c/coreboot/+/84043?usp=email )
Change subject: util/cbfstool: Deal with how lld organizes loadable segments ......................................................................
Patch Set 7:
(1 comment)
File util/cbfstool/cbfs-mkstage.c:
https://review.coreboot.org/c/coreboot/+/84043/comment/d2f2e300_bd931faa?usp... : PS7, Line 301: prev = cur
Hmmm, forgot about the return value that should include the XIP segment, right?
Maybe I'm confusing myself too much. What do we actually try to assert? That things for `_data .. _edata` are consecutive, I guess?
Looking at a BFD linked romstage, I would check `vaddr` there as well: ``` $ readelf --segments build/cbfs/fallback/romstage.elf
Elf file type is EXEC (Executable file) Entry point 0x2000031 There are 2 program headers, starting at offset 52
Program Headers: Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align LOAD 0x000080 0x02000000 0x02000000 0x0c1d0 0x0c1d0 R E 0x20 LOAD 0x00c250 0xff7cb0a8 0x0200c1d0 0x00018 0x00018 RW 0x4
Section to Segment mapping: Segment Sections... 00 .text 01 .data ```
Just not compare the executable segment.