Commit 765f3604 authored by Dan Carpenter's avatar Dan Carpenter Committed by Jakub Kicinski

octeon_ep: unlock the correct lock on error path

The h and the f letters are swapped so it unlocks the wrong lock.

Fixes: 577f0d1b ("octeon_ep: add separate mailbox command and response queues")
Signed-off-by: default avatarDan Carpenter <error27@gmail.com>
Reviewed-by: default avatarLeon Romanovsky <leonro@nvidia.com>
Link: https://lore.kernel.org/r/251aa2a2-913e-4868-aac9-0a90fc3eeeda@kili.mountainSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 615927f1
...@@ -167,7 +167,7 @@ int octep_ctrl_mbox_send(struct octep_ctrl_mbox *mbox, struct octep_ctrl_mbox_ms ...@@ -167,7 +167,7 @@ int octep_ctrl_mbox_send(struct octep_ctrl_mbox *mbox, struct octep_ctrl_mbox_ms
ci = readl(q->hw_cons); ci = readl(q->hw_cons);
if (octep_ctrl_mbox_circq_space(pi, ci, q->sz) < (msg->hdr.s.sz + mbox_hdr_sz)) { if (octep_ctrl_mbox_circq_space(pi, ci, q->sz) < (msg->hdr.s.sz + mbox_hdr_sz)) {
mutex_unlock(&mbox->f2hq_lock); mutex_unlock(&mbox->h2fq_lock);
return -EAGAIN; return -EAGAIN;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment