[PATCH v3 1/5] lib: sbi: select expected trap handler per hart
Troy Mitchell
troy.mitchell at linux.spacemit.com
Mon Aug 31 22:45:05 PDT 2026
On Mon, Aug 31, 2026 at 10:21 AM +0800, Alvin Chang wrote:
> Have you tried stack protector?
>
> I changed them to use extern symbol directly because they break stack
> protector.
> Please check my patchset sent last year:
> https://lore.kernel.org/all/20250703151957.2545958-1-alvinga@andestech.com/
I had not tested this version with stack protector enabled. I have now
built and booted it under QEMU with CONFIG_STACK_PROTECTOR_ALL. It boots,
but the generated code confirms that the accessor itself is instrumented
and introduces an out-of-line call in this low-level path.
I will replace it with a per-hart handler address stored in scratch and
loaded directly at each use, then test it on K3 with stack protector
enabled.
- Troy
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 248 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/opensbi/attachments/20260901/260b0bac/attachment.sig>
More information about the opensbi
mailing list