public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Hannes Reinecke <hare@suse.de>
To: John Garry <john.garry@huawei.com>,
	Sumit Saxena <sumit.saxena@broadcom.com>
Cc: Anand Lodnoor <anand.lodnoor@broadcom.com>,
	Linux SCSI List <linux-scsi@vger.kernel.org>,
	Kashyap Desai <kashyap.desai@broadcom.com>,
	Kiran Kumar Kasturi <kiran-kumar.kasturi@broadcom.com>,
	Sankar Patra <sankar.patra@broadcom.com>,
	Sasikumar PC <sasikumar.pc@broadcom.com>,
	Shivasharan Srikanteshwara 
	<shivasharan.srikanteshwara@broadcom.com>,
	Chandrakanth Patil <chandrakanth.patil@broadcom.com>,
	Ming Lei <ming.lei@redhat.com>,
	Bart Van Assche <bvanassche@acm.org>,
	"Martin K . Petersen" <martin.petersen@oracle.com>
Subject: Re: [PATCH v2 10/11] megaraid_sas: Use Block layer API to check SCSI device in-flight IO requests
Date: Tue, 3 Mar 2020 12:56:56 +0100	[thread overview]
Message-ID: <ac883164-ad0a-908e-7ead-d16a63347803@suse.de> (raw)
In-Reply-To: <aa0d2c4c-b54b-8d68-1a18-d7449f46962b@huawei.com>

On 3/3/20 12:53 PM, John Garry wrote:
>>> And for these low-latency queues, I figure that the issue is not just
>>> polling vs interrupt, but indeed how fast the HW queue can consume SQEs.
>>> A HW queue may only be able to consume at a limited rate - that's why we
>>> segregate.
>> Yes, there is no polling in any of HW queues. High IOPs queues have
>> interrupt coalescing enabled whereas
>> low latency queues does not have interrupt coalescing. megaraid_sas
>> driver would choose which set of queues   
>> among these two has to be used depending on workload. For latency
>> oriented workload, driver would use low
>> latency queues and for IOPs profile, driver would use High IOPs queues.
>>>
>>> As an aside, that is actually an issue for blk-mq. For 1 to many HW
>>> queue-to-CPU mapping, limiting many CPUs a single queue can limit IOPs
>>> since HW queues can only consume at a limited rate.
>> We were able to achieve performance target for MegaRAID latest gen
>> controller with this model of few set
>>   of HW queues mapped to local numa CPUs and low latency queues has one
>> to one mapping to CPUs.
>> This is default behavior of queues segregation in megaraid_sas driver
>> to satisfy our IOPs and latency requirements altogether.
>> However we have given module parameter- "perf_mode" to tune queues
>> behavior. i.e turning on/off interrupt
>> coalescing on all HW queues where this one to many queues to CPU
>> mapping would not happen.
> 
> Hi Sumit,
> 
> OK, I have a rough idea of the concept. And again I'd say megaraid sas
> may not be a good candidate to expose > 1 HW queues, as we hide HW
> queues and don't maintain the symmetry with blk-mq layer.
> 
> Indeed, I do not even expect a performance increase in exposing > 1 HW
> queues since the driver already uses the reply map + managed interrupts.
> 
> The main reason for that change in some drivers - apart from losing the
> duplicated ugliness of the reply map - is to leverage the blk-mq feature
> to drain a hctx for CPU hotplug [0] - is this something which megaraid
> sas is vulnerable to and would benefit from?
> 
I would guess so.
Megaraid_sas (much like mpt3sas) has a mailbox interface, requiring you
to just write the address of the command into it.
The command itself carries the information about which MSIx interrupt
firmware should post completions on, so if the cpu serving that
interrupt is gone we're in trouble as we'll never see the completion.

Cheers,

Hannes
-- 
Dr. Hannes Reinecke		           Kernel Storage Architect
hare@suse.de			                  +49 911 74053 688
SUSE Software Solutions Germany GmbH, Maxfeldstr. 5, 90409 Nürnberg
HRB 36809 (AG Nürnberg), GF: Felix Imendörffer

  reply	other threads:[~2020-03-03 11:57 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-14 11:21 [PATCH v2 00/11] megaraid_sas: driver updates to 07.713.01.00-rc1 Anand Lodnoor
2020-01-14 11:21 ` [PATCH v2 01/11] megaraid_sas: Reset adapter if FW is not in READY state after device resume Anand Lodnoor
2020-01-14 11:21 ` [PATCH v2 02/11] megaraid_sas: Set no_write_same only for Virtual Disk Anand Lodnoor
2020-01-14 11:21 ` [PATCH v2 03/11] megaraid_sas: Update optimal queue depth for SAS and NVMe devices Anand Lodnoor
2020-01-14 11:21 ` [PATCH v2 04/11] megaraid_sas: Do not kill host bus adapter, if adapter is already dead Anand Lodnoor
2020-01-14 11:21 ` [PATCH v2 05/11] megaraid_sas: Do not kill HBA if JBOD Seqence map or RAID map is disabled Anand Lodnoor
2020-01-14 11:21 ` [PATCH v2 06/11] megaraid_sas: Do not set HBA Operational if FW is not in operational state Anand Lodnoor
2020-01-14 11:21 ` [PATCH v2 07/11] megaraid_sas: Re-Define enum DCMD_RETURN_STATUS Anand Lodnoor
2020-01-14 11:21 ` [PATCH v2 08/11] megaraid_sas: Do not initiate OCR if controller is not in ready state Anand Lodnoor
2020-01-14 11:21 ` [PATCH v2 09/11] megaraid_sas: Limit the number of retries for the IOCTLs causing firmware fault Anand Lodnoor
2020-01-14 11:21 ` [PATCH v2 10/11] megaraid_sas: Use Block layer API to check SCSI device in-flight IO requests Anand Lodnoor
2020-01-16 12:30   ` Hannes Reinecke
2020-01-17 11:19     ` Anand Lodnoor
2020-02-26 16:19       ` John Garry
     [not found]         ` <CAAO+jF-P3MkB2mo6pmYH1ihjRGpfjkkgXZg9dAZ29nYmU6T2=A@mail.gmail.com>
2020-02-27 12:32           ` John Garry
2020-03-02  9:17             ` Hannes Reinecke
2020-03-02  9:51               ` John Garry
2020-03-02 18:37                 ` Sumit Saxena
2020-03-03 11:53                   ` John Garry
2020-03-03 11:56                     ` Hannes Reinecke [this message]
2020-03-03 17:04                     ` Sumit Saxena
2020-03-04  9:39                       ` John Garry
2020-01-14 11:21 ` [PATCH v2 11/11] megaraid_sas: Update driver version to 07.713.01.00-rc1 Anand Lodnoor
2020-01-16  4:21 ` [PATCH v2 00/11] megaraid_sas: driver updates " Martin K. Petersen

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=ac883164-ad0a-908e-7ead-d16a63347803@suse.de \
    --to=hare@suse.de \
    --cc=anand.lodnoor@broadcom.com \
    --cc=bvanassche@acm.org \
    --cc=chandrakanth.patil@broadcom.com \
    --cc=john.garry@huawei.com \
    --cc=kashyap.desai@broadcom.com \
    --cc=kiran-kumar.kasturi@broadcom.com \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    --cc=ming.lei@redhat.com \
    --cc=sankar.patra@broadcom.com \
    --cc=sasikumar.pc@broadcom.com \
    --cc=shivasharan.srikanteshwara@broadcom.com \
    --cc=sumit.saxena@broadcom.com \
    /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