Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e0aac817 authored by AnilKumar Chimata's avatar AnilKumar Chimata Committed by Gerrit - the friendly Code Review server
Browse files

qseecom: Fix ICE create and wipe key issues



While create/wipe the encryption key ICE hw setup is triggered
to make sure that HW is ready. During that return value is not
properly checked which results in key create/wipe success even
if its not set on the hardware.

Change-Id: I96ad90c760d93fbcdf6ae13e2e497b147fe00b7c
Signed-off-by: default avatarAnilKumar Chimata <anilc@codeaurora.org>
parent be60ad58
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -5870,7 +5870,8 @@ static int qseecom_create_key(struct qseecom_dev_handle *data,
		 * It will return false if it is GPCE based crypto instance or
		 * ICE is setup properly
		 */
		if (qseecom_enable_ice_setup(create_key_req.usage))
		ret = qseecom_enable_ice_setup(create_key_req.usage);
		if (ret)
			goto free_buf;

		do {
@@ -5999,7 +6000,8 @@ static int qseecom_wipe_key(struct qseecom_dev_handle *data,
		 * It will return false if it is GPCE based crypto instance or
		 * ICE is setup properly
		 */
		if (qseecom_enable_ice_setup(wipe_key_req.usage))
		ret = qseecom_enable_ice_setup(wipe_key_req.usage);
		if (ret)
			goto free_buf;

		ret = __qseecom_set_clear_ce_key(data, wipe_key_req.usage,