Closed vilukissa68 closed 1 month ago
I think the link script sdram_sysctrl.x
is not present on https://github.com/vilukissa68/headsail-vp/tree/feat/asic-sysctrl-dla. Perhaps forgot to add it in tree.
The compile error is debuggable without it though. Link script is only queried for upon linkage (at end of build).
Issue is unrelated to headsail-sysctrl-pac
. That just happened to be building simultaneously due to parallel build. Actual problem is with spin
crate (which is producing the errors).
cargo tree -Falloc -i spin
gives inverted deps:
spin v0.9.8
└── good_memory_allocator v0.1.7
└── headsail-bsp v0.1.0
Root cause identified: the SpinLockAllocator
of good_memory_allocator
uses atomics. Atomics are not present for SysCtrl.
I'm not sure if an allocator can be implemented without atomics. You can look into it if you want to.
I don't think execution from SDRAM on SysCtrl will be in high demand, so I say it's not worth putting in the effort and looking for a suitable replacement for good_memory_allocator
. good_memory_allocator
has been working great on HPC.
Trying to run alloc example in headsail-bsp:
fails to build with the following error when compiling headsail-sysctrl-pac:
This branch https://github.com/vilukissa68/headsail-vp/tree/feat/asic-sysctrl-dla supplies sdram link.x for sysctrl.