[PATCH] rxrpc: fix bad unlock balance in rxrpc_do_sendmsg
David Howells
dhowells at redhat.com
Mon Aug 22 01:48:14 PDT 2022
Hawkins Jiawei <yin31149 at gmail.com> wrote:
> - if (mutex_lock_interruptible(&call->user_mutex) < 0)
> + if (mutex_lock_interruptible(&call->user_mutex) < 0) {
> + mutex_lock(&call->user_mutex);
Yeah, as Khalid points out that kind of makes the interruptible lock
pointless. Either rxrpc_send_data() needs to return a separate indication
that we returned without the lock held or it needs to always drop the lock on
error (at least for ERESTARTSYS/EINTR) which can be checked for higher up.
David
More information about the linux-afs
mailing list