From: Keith Busch <keith.busch@linux.intel.com>
To: Jianchao Wang <jianchao.w.wang@oracle.com>
Cc: keith.busch@intel.com, axboe@fb.com, hch@lst.de,
sagi@grimberg.me, linux-kernel@vger.kernel.org,
linux-nvme@lists.infradead.org
Subject: Re: [PATCH 2/2] nvme-pci: don't send delete cq command when allocate sq return -EINTR
Date: Thu, 24 May 2018 07:38:59 -0600 [thread overview]
Message-ID: <20180524133859.GH11037@localhost.localdomain> (raw)
In-Reply-To: <1527155494-1891-2-git-send-email-jianchao.w.wang@oracle.com>
On Thu, May 24, 2018 at 05:51:34PM +0800, Jianchao Wang wrote:
> result = adapter_alloc_sq(dev, qid, nvmeq);
> - if (result < 0)
> + /*
> + * If return -EINTR, it means the allocate sq command times out and is completed
> + * with NVME_REQ_CANCELLED. At the time, the controller has been disabled
> + * and admin request queue has been quiesced. So don't try to send delete cq
> + * command any more.
> + */
> + if (result == -EINTR)
> + goto out;
> + else if (result < 0)
> goto release_cq;
Since you're touching this part anyway, you'd really only want to goto
the release_cq if result is > 0.
next prev parent reply other threads:[~2018-05-24 13:36 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-24 9:51 [PATCH 1/2] nvme-pci: set nvmeq->cq_vector after alloc cq/sq Jianchao Wang
2018-05-24 9:51 ` [PATCH 2/2] nvme-pci: don't send delete cq command when allocate sq return -EINTR Jianchao Wang
2018-05-24 13:38 ` Keith Busch [this message]
2018-05-24 13:36 ` [PATCH 1/2] nvme-pci: set nvmeq->cq_vector after alloc cq/sq Keith Busch
2018-05-25 8:53 ` 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=20180524133859.GH11037@localhost.localdomain \
--to=keith.busch@linux.intel.com \
--cc=axboe@fb.com \
--cc=hch@lst.de \
--cc=jianchao.w.wang@oracle.com \
--cc=keith.busch@intel.com \
--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 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).