arm: scm: check error codes as well during secure authentication

Currently, during secure authentication only return values are checked,
error codes are not considered. So, added respective check to verify both
return value and error codes value during secure_authentication scm call.

Change-Id: Ie3e4fbf8651666001bdfacc0705fb2799a306b96
Signed-off-by: Ram Kumar D <quic_ramd@quicinc.com>
This commit is contained in:
Ram Kumar D 2021-12-28 16:24:41 +05:30
parent cdc16476d9
commit 93937d92f3

View file

@ -585,6 +585,8 @@ int qca_scm_secure_authenticate(void *cmd_buf, size_t cmd_len)
desc.args[2] = * (((unsigned long *)cmd_buf) + 2);
ret = scm_call_64(SCM_SVC_BOOT, SCM_CMD_SEC_AUTH, &desc);
if(!ret && desc.ret[0])
return SCM_ERROR;
}
else
{