All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@lst.de>
To: Guixin Liu <kanie@linux.alibaba.com>
Cc: Keith Busch <kbusch@kernel.org>, Jens Axboe <axboe@kernel.dk>,
	Christoph Hellwig <hch@lst.de>, Sagi Grimberg <sagi@grimberg.me>,
	Nilay Shroff <nilay@linux.ibm.com>,
	Daniel Wagner <dwagner@suse.de>, Hannes Reinecke <hare@suse.de>,
	linux-nvme@lists.infradead.org
Subject: Re: [PATCH v2] nvmet: Handle a NULL admin queue in nvmet_queue_tls_keyid()
Date: Thu, 29 Oct 2026 13:15:52 +0100	[thread overview]
Message-ID: <20261029121552.GC24375@lst.de> (raw)
In-Reply-To: <20261029034306.3626274-1-kanie@linux.alibaba.com>

On Thu, Oct 29, 2026 at 11:43:06AM +0800, Guixin Liu wrote:
> The admin queue is not necessarily installed when the tls_key debugfs
> entry is read: it may not have been created yet, or it may have been
> destroyed already.  nvmet_queue_tls_keyid() then dereferences a NULL
> sq.
> 
> Guard the helper and return 0 instead, which also covers the read
> racing with admin queue teardown.

The patch itself looks obviously fine, but do we have any synchronization
that ensure it does not go away while we're looking at the submission
queue?



      parent reply	other threads:[~2026-10-29 12:16 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-29  3:43 [PATCH v2] nvmet: Handle a NULL admin queue in nvmet_queue_tls_keyid() Guixin Liu
2026-10-29  3:50 ` sashiko-bot
2026-10-29 12:15 ` Christoph Hellwig [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=20261029121552.GC24375@lst.de \
    --to=hch@lst.de \
    --cc=axboe@kernel.dk \
    --cc=dwagner@suse.de \
    --cc=hare@suse.de \
    --cc=kanie@linux.alibaba.com \
    --cc=kbusch@kernel.org \
    --cc=linux-nvme@lists.infradead.org \
    --cc=nilay@linux.ibm.com \
    --cc=sagi@grimberg.me \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.