From: "Maurizio Lombardi" <mlombard@bsdbackstore.eu>
To: "Maurizio Lombardi" <mlombard@bsdbackstore.eu>,
"Yi Zhang" <yi.zhang@redhat.com>,
"linux-block" <linux-block@vger.kernel.org>,
"open list:NVM EXPRESS DRIVER" <linux-nvme@lists.infradead.org>
Cc: "Shinichiro Kawasaki" <shinichiro.kawasaki@wdc.com>,
"Maurizio Lombardi" <mlombard@redhat.com>
Subject: Re: [bug report] blktests nvme/tcp nvme/060 hang
Date: Wed, 06 Aug 2025 08:44:18 +0200 [thread overview]
Message-ID: <DBV53ULYUBX6.1ZBU5KFWA2SHH@bsdbackstore.eu> (raw)
In-Reply-To: <DBV4NAR2A6N2.1LFJCYHLTHUN2@bsdbackstore.eu>
On Wed Aug 6, 2025 at 8:22 AM CEST, Maurizio Lombardi wrote:
> On Wed Aug 6, 2025 at 8:16 AM CEST, Maurizio Lombardi wrote:
>>
>> I think that the problem is due to the fact that nvmet_tcp_data_ready()
>> calls the queue->data_ready() callback with the sk_callback_lock
>> locked.
>> The data_ready callback points to nvmet_tcp_listen_data_ready()
>> which tries to lock the same sk_callback_lock, hence the deadlock.
>>
>> Maybe it can be fixed by deferring the call to queue->data_ready() by
>> using a workqueue.
>>
>
> Ops sorry they are two read locks, the real problem then is that
> something is holding the write lock.
Ok, I think I get what happens now.
The threads that call nvmet_tcp_data_ready() (takes the read lock 2
times) and
nvmet_tcp_release_queue_work() (tries to take the write lock)
are blocking each other.
So I still think that deferring the call to queue->data_ready() by
using a workqueue should fix it.
Maurizio
next prev parent reply other threads:[~2025-08-06 6:50 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-06 1:57 [bug report] blktests nvme/tcp nvme/060 hang Yi Zhang
2025-08-06 6:16 ` Maurizio Lombardi
2025-08-06 6:22 ` Maurizio Lombardi
2025-08-06 6:44 ` Maurizio Lombardi [this message]
2025-08-06 9:30 ` Maurizio Lombardi
2025-08-06 10:54 ` Hannes Reinecke
2025-08-06 10:52 ` Hannes Reinecke
2025-08-07 1:57 ` Yi Zhang
2025-08-11 14:10 ` Maurizio Lombardi
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=DBV53ULYUBX6.1ZBU5KFWA2SHH@bsdbackstore.eu \
--to=mlombard@bsdbackstore.eu \
--cc=linux-block@vger.kernel.org \
--cc=linux-nvme@lists.infradead.org \
--cc=mlombard@redhat.com \
--cc=shinichiro.kawasaki@wdc.com \
--cc=yi.zhang@redhat.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