/* Handles the ESBC uboot client header verification failure. This function handles all the errors which might occur in the parsing and checking of ESBC uboot client header. It will also set the error bits in the SEC_MON.  */
static void fsl_secboot_header_verification_failure(void)
/* Handles the ESBC uboot client header verification failure. This function handles all the errors which might occur in the parsing and checking of ESBC uboot client header. It will also set the error bits in the SEC_MON.  */
static void fsl_secboot_header_verification_failure(void)
{
	struct ccsr_sfp_regs *sfp_regs = (void *)(CONFIG_SYS_SFP_ADDR);
	u32 its = sfp_in32(&sfp_regs->ospr) >> 2;
	if (its == 1)
		set_sec_mon_state(HPSR_SSM_ST_SOFT_FAIL);
	else
		set_sec_mon_state(HPSR_SSM_ST_NON_SECURE);
	printf("Generating reset request\n");
	do_reset(NULL, 0, 0, NULL);
	do_esbc_halt(NULL, 0, 0, NULL);
}