Commit 00621a5
committed
scripts: reset LLEXT VMA accumulators before each west build
llext_link_helper.py uses openmod_module_size and module_size as
persistent counters to assign pre-linked VMAs to LLEXT ELFs. Running
ninja more than once without a pristine build causes these files to
accumulate across invocations. The second run doubles the counter
values, placing all ELF VMAs outside the valid LLEXT virtual region
[CONFIG_LIBRARY_BASE_ADDRESS, +CONFIG_LIBRARY_REGION_SIZE).
When pre_located=true the LLEXT loader uses the ELF sh_addr VMAs
directly as physical load addresses. sys_mm_drv_map_region() silently
fails for out-of-range addresses, so the module is never registered.
The kernel then receives IPC4_MOD_NOT_INITIALIZED (error 104) for every
module init IPC.
Reset both accumulator files to 0 before every west build invocation so
VMA assignment always starts from CONFIG_LIBRARY_BASE_ADDRESS.
Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>1 parent 2896e23 commit 00621a5
1 file changed
Lines changed: 14 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
979 | 979 | | |
980 | 980 | | |
981 | 981 | | |
| 982 | + | |
| 983 | + | |
| 984 | + | |
| 985 | + | |
| 986 | + | |
| 987 | + | |
| 988 | + | |
| 989 | + | |
| 990 | + | |
| 991 | + | |
| 992 | + | |
| 993 | + | |
| 994 | + | |
| 995 | + | |
982 | 996 | | |
983 | 997 | | |
984 | 998 | | |
| |||
0 commit comments