public inbox for linux-nvme@lists.infradead.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@lst.de>
To: Chaitanya Kulkarni <chaitanyak@nvidia.com>
Cc: Hannes Reinecke <hare@suse.de>, Christoph Hellwig <hch@lst.de>,
	Sagi Grimberg <sagi@grimberg.me>,
	Keith Busch <keith.busch@wdc.com>,
	"linux-nvme@lists.infradead.org" <linux-nvme@lists.infradead.org>
Subject: Re: [PATCH 3/6] nvmet: set 'CNTRLTYPE' in the identify controller data
Date: Wed, 22 Sep 2021 07:00:28 +0200	[thread overview]
Message-ID: <20210922050028.GA12802@lst.de> (raw)
In-Reply-To: <0afe1307-44d8-50d5-13b1-1939745dc2a5@nvidia.com>

On Wed, Sep 22, 2021 at 01:23:03AM +0000, Chaitanya Kulkarni wrote:
> since this check is used on more than one place in this patch,
> why not have a helper instead of opencoding that makes code easy so
> search e.g.
> 
> bool nvmet_is_subsys_disc(struct nvmet_subsys *s)
> {
> 	return subsys->type == NVME_NQN_DISC ? true : false;

That can be just:

	return subsys->type == NVME_NQN_DISC;

_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme

  reply	other threads:[~2021-09-22  5:01 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-21 15:15 [PATCHv2 0/6] nvme: support unique discovery controller Hannes Reinecke
2021-09-21 15:15 ` [PATCH 1/6] nvmet: make discovery NQN configurable Hannes Reinecke
2021-09-22  1:15   ` Chaitanya Kulkarni
2021-09-22 13:32   ` Himanshu Madhani
2021-09-21 15:15 ` [PATCH 2/6] nvme: add CNTRLTYPE definitions for 'identify controller' Hannes Reinecke
2021-09-22  1:17   ` Chaitanya Kulkarni
2021-09-22 13:33   ` Himanshu Madhani
2021-09-21 15:15 ` [PATCH 3/6] nvmet: set 'CNTRLTYPE' in the identify controller data Hannes Reinecke
2021-09-22  1:23   ` Chaitanya Kulkarni
2021-09-22  5:00     ` Christoph Hellwig [this message]
2021-09-22  6:01     ` Hannes Reinecke
2021-09-21 15:15 ` [PATCH 4/6] nvme: expose subsystem type in sysfs attribute 'subtype' Hannes Reinecke
2021-09-22  1:25   ` Chaitanya Kulkarni
2021-09-22 13:34   ` Himanshu Madhani
2021-09-21 15:15 ` [PATCH 5/6] nvme: Add connect option 'discovery' Hannes Reinecke
2021-09-22  1:31   ` Chaitanya Kulkarni
2021-09-22 13:34   ` Himanshu Madhani
2021-09-21 15:15 ` [PATCH 6/6] nvme: display correct subsystem NQN Hannes Reinecke
2021-09-22  1:32   ` Chaitanya Kulkarni
2021-09-22 13:34   ` Himanshu Madhani
  -- strict thread matches above, loose matches on Subject: below --
2021-08-27 12:09 [PATCH 0/6] nvme: support unique discovery controller Hannes Reinecke
2021-08-27 12:09 ` [PATCH 3/6] nvmet: set 'CNTRLTYPE' in the identify controller data Hannes Reinecke

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=20210922050028.GA12802@lst.de \
    --to=hch@lst.de \
    --cc=chaitanyak@nvidia.com \
    --cc=hare@suse.de \
    --cc=keith.busch@wdc.com \
    --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