[PATCH 0/2] lib: sbi: Fix stale trap_context/prev_context linking
Evgeny Voevodin
evvoevod at tenstorrent.com
Wed Sep 9 12:34:20 PDT 2026
LGTM, but please resend with some changes in the descriptions.
Patch 1/2: it clears trap_context and not tmp0 and tmp1, so the
_scratch_init mirroring mentioned is not precise. Also it avoids a
broken trap dump and a sbi_memcpy via scratch->trap_context with no
NULL check, which corrupts memory silently.
Add a Fixes tag, I think this is what gets fixed with this
patch:
Fixes: 60ffc154c84d ("include: sbi: Add trap_context pointer in struct sbi_scratch")
Reviewed-by: Evgeny Voevodin <evvoevod at tenstorrent.com>
Thanks,
Evgeny
More information about the opensbi
mailing list