All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@lst.de>
To: Caleb Sander Mateos <csander@purestorage.com>
Cc: Keith Busch <kbusch@kernel.org>, Jens Axboe <axboe@kernel.dk>,
	Christoph Hellwig <hch@lst.de>, Sagi Grimberg <sagi@grimberg.me>,
	linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] nvme-pci: deduplicate empty request list checks in nvme_queue_rqs()
Date: Wed, 19 Nov 2025 06:48:48 +0100	[thread overview]
Message-ID: <20251119054848.GA20072@lst.de> (raw)
In-Reply-To: <20251119021701.3165123-1-csander@purestorage.com>

On Tue, Nov 18, 2025 at 07:17:00PM -0700, Caleb Sander Mateos wrote:
> nvme_queue_rqs() checks that nvmeq is non-NULL before calling
> nvme_submit_cmds() and nvme_submit_cmds() checks that submit_list is
> non-empty before doing anything. A NULL nvmeq means no requests were
> processed from the rqlist in nvme_queue_rqs() since the last call to
> nvme_submit_cmds(), which implies submit_list is empty. So just check
> that submit_list is non-empty before calling nvme_submit_cmds() and drop
> the check for NULL nvmeq.

What is the rationale for this?  I had a hard time understanding the
logic in the new version, so I don't think this helps with readability
at least.


  reply	other threads:[~2025-11-19  5:49 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-19  2:17 [PATCH] nvme-pci: deduplicate empty request list checks in nvme_queue_rqs() Caleb Sander Mateos
2025-11-19  5:48 ` Christoph Hellwig [this message]
2025-11-19 16:01   ` Caleb Sander Mateos
2025-11-20  6:49     ` Christoph Hellwig

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=20251119054848.GA20072@lst.de \
    --to=hch@lst.de \
    --cc=axboe@kernel.dk \
    --cc=csander@purestorage.com \
    --cc=kbusch@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-nvme@lists.infradead.org \
    --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.