Skip to content
Snippets Groups Projects
Commit b69af347 authored by Sourav Poddar's avatar Sourav Poddar Committed by Gerrit - the friendly Code Review server
Browse files

[qca-nss-crypto] Indicate correct message success based on response field.


In current code, we are not checking if the message was successfully handled
in NSS FW code, if an error was encountered on FW side, we still send TX_SUCCESS
to host crypto code which is incorrect.

Change-Id: I9e17144ed0ee77102c75b5bb604131af9a389e56
Signed-off-by: default avatarSourav Poddar <quic_souravp@quicinc.com>
parent 527cfe43
No related merge requests found
......@@ -226,6 +226,12 @@ nss_tx_status_t nss_crypto_cmn_tx_msg_sync(struct nss_ctx_instance *nss_ctx, str
* further details read Linux/Documentation/memory-barrier.txt
*/
smp_rmb();
if (msg->cm.response != NSS_CMN_RESPONSE_ACK) {
up(&pvt->sem);
return NSS_TX_FAILURE;
}
up(&pvt->sem);
return NSS_TX_SUCCESS;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment