security: pfk: Error code was overwritten

Invalidate scm calls overwrites set key call
error code in case set key call has failed.

Change-Id: I9c9d9026ab1f5c593f78fd0e592e2270aa28292c
Signed-off-by: Neeraj Soni <neersoni@codeaurora.org>
This commit is contained in:
Neeraj Soni
2018-02-02 11:50:17 +05:30
parent 4867091eab
commit c23efa56f6

View File

@@ -1,4 +1,4 @@
/* Copyright (c) 2015-2017, The Linux Foundation. All rights reserved.
/* Copyright (c) 2015-2018, The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
@@ -138,6 +138,7 @@ int qti_pfk_ice_set_key(uint32_t index, uint8_t *key, uint8_t *salt,
if (ret1)
pr_err("%s: Invalidate Key Error: %d\n", __func__,
ret1);
goto out;
}
ret = qcom_ice_setup_ice_hw((const char *)s_type, false);