From: Sowmini Varadhan <sowmini.varadhan@oracle.com>
To: syzbot <syzbot+52140d69ac6dc6b927a9@syzkaller.appspotmail.com>
Cc: davem@davemloft.net, linux-kernel@vger.kernel.org,
linux-rdma@vger.kernel.org, netdev@vger.kernel.org,
rds-devel@oss.oracle.com, santosh.shilimkar@oracle.com,
syzkaller-bugs@googlegroups.com
Subject: Re: possible deadlock in rds_wake_sk_sleep
Date: Tue, 7 Aug 2018 17:07:54 -0400 [thread overview]
Message-ID: <20180807210754.GE23593@oracle.com> (raw)
In-Reply-To: <000000000000fb5cd90572de7ebd@google.com>
On (08/07/18 13:47), syzbot wrote:
> Possible unsafe locking scenario:
>
> CPU0 CPU1
> ---- ----
> lock(&(&rm->m_rs_lock)->rlock);
> lock(&rs->rs_recv_lock);
> lock(&(&rm->m_rs_lock)->rlock);
> lock(&rs->rs_recv_lock);
>
> *** DEADLOCK ***
looks like a valid find, I think the deadlock should be avoided
by having rds_clear_recv_queue do something like
get rs_recv_lock
un-tether the rs_recv_queue into a temporary list
releease rs_recv_lock
purge the rds_incoming temporary list
I can give this a shot later this week.
--Sowmini
prev parent reply other threads:[~2018-08-07 23:24 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-07 20:47 possible deadlock in rds_wake_sk_sleep syzbot
2018-08-07 21:07 ` Sowmini Varadhan [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180807210754.GE23593@oracle.com \
--to=sowmini.varadhan@oracle.com \
--cc=davem@davemloft.net \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=rds-devel@oss.oracle.com \
--cc=santosh.shilimkar@oracle.com \
--cc=syzbot+52140d69ac6dc6b927a9@syzkaller.appspotmail.com \
--cc=syzkaller-bugs@googlegroups.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).