mirror of
https://github.com/smaeul/u-boot.git
synced 2025-09-14 14:06:02 +01:00
Secure firmwares must be loaded if SOC is secure, currently rproc framework chooses non-secure firmware always. So adding support to load secure firmware, when SOC is secure Signed-off-by: Manorit Chawdhry <m-chawdhry@ti.com> Signed-off-by: Udit Kumar <u-kumar1@ti.com> Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> # Intel Edison Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
31 lines
684 B
Bash
31 lines
684 B
Bash
dorprocboot=0
|
|
boot_rprocs=
|
|
if test ${dorprocboot} -eq 1 && test ${boot} = mmc; then
|
|
rproc init;
|
|
run boot_rprocs_mmc;
|
|
fi;
|
|
rproc_load_and_boot_one=
|
|
if load mmc ${bootpart} $loadaddr ${rproc_fw}; then
|
|
if rproc load ${rproc_id} ${loadaddr} ${filesize}; then
|
|
rproc start ${rproc_id};
|
|
fi;
|
|
fi
|
|
boot_rprocs_mmc=
|
|
env set rproc_id;
|
|
env set rproc_fw;
|
|
env set secure_suffix;
|
|
if test ${secure_rprocs} -eq 1; then
|
|
env set secure_suffix -sec;
|
|
fi;
|
|
for i in ${rproc_fw_binaries} ; do
|
|
if test -z "${rproc_id}" ; then
|
|
env set rproc_id $i;
|
|
else
|
|
env set rproc_fw $i${secure_suffix};
|
|
run rproc_load_and_boot_one;
|
|
env set rproc_id;
|
|
env set rproc_fw;
|
|
fi;
|
|
done
|
|
|