lib: Add dynamic registration of SBI extensions

This patch extends our SBI ecall implementation to allow
dynamic registration of various SBI extensions. Using this
dynamic registration we can break-up SBI ecall implementation
into multiple files and even register experimental/custom
SBI extensions from platform code.

Signed-off-by: Anup Patel <anup.patel@wdc.com>
Reviewed-by: Atish Patra <atish.patra@wdc.com>
This commit is contained in:
Anup Patel
2020-01-16 11:38:49 +05:30
committed by Anup Patel
parent 0a411bf717
commit 37923c4a66
3 changed files with 199 additions and 65 deletions

View File

@@ -112,6 +112,10 @@ static void __noreturn init_coldboot(struct sbi_scratch *scratch, u32 hartid)
if (rc)
sbi_hart_hang();
rc = sbi_ecall_init();
if (rc)
sbi_hart_hang();
rc = sbi_system_final_init(scratch, TRUE);
if (rc)
sbi_hart_hang();