dsp-kernel: Handle spin lock in error scenarios
Currently, the code flow bails out without releasing the spin lock, leading to spin lock recursion. Additionally, the free function is called during this bail, which is a sleep function. To address this issue, ensure that the spin lock is released before proceeding to the bail. Change-Id: I57884049d7799c3c69eccb4fa2db043b073d5312 Signed-off-by: Abhishek Singh <quic_abhishes@quicinc.com>
This commit is contained in:
@@ -7769,6 +7769,7 @@ static void fastrpc_print_debug_data(int cid)
|
|||||||
hlist_for_each_entry_safe(fl, n, &me->drivers, hn) {
|
hlist_for_each_entry_safe(fl, n, &me->drivers, hn) {
|
||||||
err = fastrpc_file_get(fl);
|
err = fastrpc_file_get(fl);
|
||||||
if (err) {
|
if (err) {
|
||||||
|
spin_unlock_irqrestore(&me->hlock, irq_flags);
|
||||||
ADSPRPC_ERR("Failed to get user process reference\n");
|
ADSPRPC_ERR("Failed to get user process reference\n");
|
||||||
goto free_buf;
|
goto free_buf;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user