mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-24 13:55:56 +00:00
Merge "fix(ti): release lock in all TI-SCI xfer return paths" into integration
This commit is contained in:
commit
9ac3bcdd9a
1 changed files with 5 additions and 4 deletions
|
@ -155,14 +155,14 @@ static int ti_sci_do_xfer(struct ti_sci_xfer *xfer)
|
||||||
ret = k3_sec_proxy_clear_rx_thread(SP_RESPONSE);
|
ret = k3_sec_proxy_clear_rx_thread(SP_RESPONSE);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
ERROR("Could not clear response queue (%d)\n", ret);
|
ERROR("Could not clear response queue (%d)\n", ret);
|
||||||
return ret;
|
goto unlock;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Send the message */
|
/* Send the message */
|
||||||
ret = k3_sec_proxy_send(SP_HIGH_PRIORITY, tx_msg);
|
ret = k3_sec_proxy_send(SP_HIGH_PRIORITY, tx_msg);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
ERROR("Message sending failed (%d)\n", ret);
|
ERROR("Message sending failed (%d)\n", ret);
|
||||||
return ret;
|
goto unlock;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Get the response if requested */
|
/* Get the response if requested */
|
||||||
|
@ -170,13 +170,14 @@ static int ti_sci_do_xfer(struct ti_sci_xfer *xfer)
|
||||||
ret = ti_sci_get_response(rx_msg, SP_RESPONSE);
|
ret = ti_sci_get_response(rx_msg, SP_RESPONSE);
|
||||||
if (ret != 0U) {
|
if (ret != 0U) {
|
||||||
ERROR("Failed to get response (%d)\n", ret);
|
ERROR("Failed to get response (%d)\n", ret);
|
||||||
return ret;
|
goto unlock;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
unlock:
|
||||||
bakery_lock_release(&ti_sci_xfer_lock);
|
bakery_lock_release(&ti_sci_xfer_lock);
|
||||||
|
|
||||||
return 0;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Add table
Reference in a new issue