lib: Simplify sbi_platform early_init() and final_init() hooks
authorAnup Patel <anup.patel@wdc.com>
Wed, 26 Dec 2018 12:51:22 +0000 (18:21 +0530)
committerAnup Patel <anup@brainfault.org>
Thu, 27 Dec 2018 04:05:09 +0000 (09:35 +0530)
commit7b59571758a5dec75c89928a60d982b29629cee6
tree455e803910c993bcd465cee1f2b0b1c80b8ba9a8
parentcfa3fba14f27f1fabaa8194d1ea1a6a21c2cc83a
lib: Simplify sbi_platform early_init() and final_init() hooks

Instead of having separate early_init() and final_init() hooks
for cold and warm boot, this patch updates struct sbi_platform
to have just one early_init() and one final_init() hook. The
type of boot (cold or warm) is now a boolean flag parameter for
the updated early_init() and final_init() hooks.

Signed-off-by: Anup Patel <anup.patel@wdc.com>
include/sbi/sbi_platform.h
include/sbi/sbi_system.h
lib/sbi_init.c
lib/sbi_system.c
platform/kendryte/k210/platform.c
platform/qemu/sifive_u/platform.c
platform/qemu/virt/platform.c
platform/sifive/hifive_u540/platform.c