hv: replace 'return' with 'panic' in bsp_boot_post

If hardware_detect_support() failed,as it return to
bsp_boot_init with a different stack and thus returning
from bsp_boot_init becomes an undefined behavior.

Tracked-On: #861
Signed-off-by: Mingqiang Chi <mingqiang.chi@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
Mingqiang Chi 2018-09-05 15:22:04 +08:00 committed by wenlingz
parent bad8d81ab6
commit 1b334ec08f

View File

@ -461,8 +461,7 @@ static void bsp_boot_post(void)
pr_dbg("Core %hu is up", BOOT_CPU_ID);
if (hardware_detect_support() != 0) {
pr_fatal("hardware not support!\n");
return;
panic("hardware not support!");
}
/* Warn for security feature not ready */