From: James Smart <james.smart@broadcom.com>
To: Keith Busch <kbusch@kernel.org>, James Smart <jsmart2021@gmail.com>
Cc: linux-nvme@lists.infradead.org
Subject: Re: [PATCH] nvme: Add ctrl attributes for queue_count and sqsize
Date: Wed, 25 Sep 2019 16:50:13 -0700 [thread overview]
Message-ID: <aaee9df2-62ee-d460-ee01-8db3ecb407ed@broadcom.com> (raw)
In-Reply-To: <20190925213624.GA11469@C02WT3WMHTD6>
On 9/25/2019 2:36 PM, Keith Busch wrote:
> On Tue, Sep 24, 2019 at 02:22:08PM -0700, James Smart wrote:
>> Current controller interrogation requires a lot of guesswork
>> on how many io queues were created and what the io sq size is.
>> The numbers are dependent upon core/fabric defaults, connect
>> arguments, and target responses.
>>
>> Add sysfs attributes for queue_count and sqsize.
>>
>> Signed-off-by: James Smart <jsmart2021@gmail.com>
>> ---
>> drivers/nvme/host/core.c | 4 ++++
>> 1 file changed, 4 insertions(+)
>>
>> diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
>> index e0e2dcbfd05e..b1c24af284ca 100644
>> --- a/drivers/nvme/host/core.c
>> +++ b/drivers/nvme/host/core.c
>> @@ -3040,6 +3040,8 @@ static DEVICE_ATTR(field, S_IRUGO, field##_show, NULL);
>>
>> nvme_show_int_function(cntlid);
>> nvme_show_int_function(numa_node);
>> +nvme_show_int_function(queue_count);
>> +nvme_show_int_function(sqsize);
> The sqsize is only valid for fabrics, so I think you need to update the
> 'is_visible' to suppress this attribute for pcie.
I would think knowing the SQ size or an I/O queue is still interesting
although perhaps not as useful.
Looking in pci.c:
- dev->q_depth is the baseline, getting stamped into each of the queue
structures
- nvme_pci_enable() is setting dev->ctrl.sqsize to dev->q_depth - 1;
Or are you asking not to display it as the implied model for how many
outstanding ios is different ?
note: I wasn't trying to go there - only to say what the SQ size is for
an I/O queue
-- james
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
prev parent reply other threads:[~2019-09-25 23:50 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-09-24 21:22 [PATCH] nvme: Add ctrl attributes for queue_count and sqsize James Smart
2019-09-25 12:50 ` Hannes Reinecke
2019-09-25 21:10 ` Chaitanya Kulkarni
2019-09-25 21:36 ` Keith Busch
2019-09-25 23:50 ` James Smart [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=aaee9df2-62ee-d460-ee01-8db3ecb407ed@broadcom.com \
--to=james.smart@broadcom.com \
--cc=jsmart2021@gmail.com \
--cc=kbusch@kernel.org \
--cc=linux-nvme@lists.infradead.org \
/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.