[PATCH 2/6] lpfc: correct oversubscription of nvme io requests for an adapter

2018-05-24 Thread James Smart
Under large configurations, the driver would start to log message 6065 - NVME out of buffers (exchanges). The driver is using the ndlp cmd_qdepth value when determining the max outstanding ios for an adapter. This value, by default, is set to 65536, which exceeds the maximum exchange counts

[PATCH 5/6] lpfc: Fix port initialization failure.

2018-05-24 Thread James Smart
The driver exits port setup after failing the lpfc_sli4_get_parameters command (messages 0356, 2541, & 1412). The older CNA adapters do not support the MBX command. In the past the code was allowed to fail and continue on with initialization. However a nvme change moved a closing bracket and now

[PATCH 4/6] lpfc: Fix 16gb hbas failing cq create.

2018-05-24 Thread James Smart
The lancer G5 chip family fails the CQ create with 16k page size. The hardware incorrectly reports it supports large page sizes when it is actually limited to 4k pages. A prior patch resolved this for the A0 chip revision only. This patch excludes all revisions of the G5 asic from using large

[PATCH 6/6] lpfc: update driver version to 12.0.0.4

2018-05-24 Thread James Smart
Update the driver version to 12.0.0.4 Signed-off-by: Dick Kennedy Signed-off-by: James Smart --- drivers/scsi/lpfc/lpfc_version.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/scsi/lpfc/lpfc_version.h

[PATCH 3/6] lpfc: Fix crash in blk_mq layer when executing modprobe -r lpfc

2018-05-24 Thread James Smart
modprobe -r lpfc produces the following: Call Trace: __blk_mq_run_hw_queue+0xa2/0xb0 __blk_mq_delay_run_hw_queue+0x9d/0xb0 ? blk_mq_hctx_has_pending+0x32/0x80 blk_mq_run_hw_queue+0x50/0xd0 blk_mq_sched_insert_request+0x110/0x1b0 blk_execute_rq_nowait+0x76/0x180

[PATCH 0/6] lpfc updates for 12.0.0.4

2018-05-24 Thread James Smart
This patch contains lpfc bug fixes and a few message updates and cleanups. The patches were cut against the Martin's 4.18/scsi-queue tree James Smart (6): lpfc: Fix MDS diagnostics failure (Rx < Tx) lpfc: correct oversubscription of nvme io requests for an adapter lpfc: Fix crash in

[PATCH 1/6] lpfc: Fix MDS diagnostics failure (Rx < Tx)

2018-05-24 Thread James Smart
MDS diagnostics fail because of frame count mismatch. Unavailability of SGL is the trigger for this issue. If ELS SGL is not available to process MDS frame, IOCB is put in FCP txq but not attempted to post afterwards. So, driver stops processing incoming frames as it runs out of IOCB.

linux-next: manual merge of the scsi tree with the net-next tree

2018-05-24 Thread Mark Brown
Hi James, Today's linux-next merge of the scsi tree got a conflict in: drivers/scsi/qedf/qedf.h between commit: 8673daf4f55bf3b91 ("qedf: Add get_generic_tlv_data handler.") from the net-next tree and commit: 4b9b7fabb39b3e9d7 ("scsi: qedf: Improve firmware debug dump handling") from

Re: [PATCH V2] PCI/portdrv: do not disable device on reboot/shutdown

2018-05-24 Thread Bjorn Helgaas
On Wed, May 23, 2018 at 06:57:18PM -0400, Sinan Kaya wrote: > On 5/23/2018 5:32 PM, Bjorn Helgaas wrote: > > > > The crash seems to indicate that the hpsa device attempted a DMA after > > we cleared the Root Port's PCI_COMMAND_MASTER, which means > > hpsa_shutdown() didn't stop DMA from the

Re: [PATCH 3/6] block: Create scsi_sense.h for SCSI and ATAPI

2018-05-24 Thread Kees Cook
On Thu, May 24, 2018 at 1:00 AM, Christoph Hellwig wrote: > On Wed, May 23, 2018 at 03:14:19PM -0600, Jens Axboe wrote: >> Ugh, so that would necessitate a change there too. As I said before, >> I don't really care where it lives. I know the SCSI folks seem bothered >> by

[PATCH] scsi: isci: fix memcmp casting

2018-05-24 Thread Ivan Bornyakov
memcmp() returns int, but variable of type u8 is used to store it. When casting int to u8, one can lose significant bits and get 0 from non-0 value returned by the memcmp(). Signed-off-by: Ivan Bornyakov --- drivers/scsi/isci/host.c | 4 ++-- 1 file changed, 2 insertions(+),

[RESEND] TCMUser: add read length support

2018-05-24 Thread Bodo Stroesser
This is patch version 3. Generally target core and TCMUser seem to work fine for tape devices and media changers. But there is at least one situation, where TCMUser is not able to support sequential access device emulation correctly. The situation is when an initiator sends a SCSI READ CDB with

Re: [PATCH] mpt3sas: Add an i/o barrier

2018-05-24 Thread Tomas Henzl
On 05/24/2018 05:33 PM, James Bottomley wrote: > On Thu, 2018-05-24 at 17:31 +0200, Tomas Henzl wrote: >> On 05/24/2018 05:19 PM, James Bottomley wrote: >>> On Thu, 2018-05-24 at 17:12 +0200, Tomas Henzl wrote: A barrier should be added to ensure proper ordering of memory mapped

Re: [PATCH] mpt3sas: Add an i/o barrier

2018-05-24 Thread James Bottomley
On Thu, 2018-05-24 at 17:31 +0200, Tomas Henzl wrote: > On 05/24/2018 05:19 PM, James Bottomley wrote: > > On Thu, 2018-05-24 at 17:12 +0200, Tomas Henzl wrote: > > > A barrier should be added to ensure proper ordering of memory > > > mapped > > > writes. > > > > > > Signed-off-by: Tomas Henzl

Re: [PATCH] mpt3sas: Add an i/o barrier

2018-05-24 Thread Tomas Henzl
On 05/24/2018 05:19 PM, James Bottomley wrote: > On Thu, 2018-05-24 at 17:12 +0200, Tomas Henzl wrote: >> A barrier should be added to ensure proper ordering of memory mapped >> writes. >> >> Signed-off-by: Tomas Henzl >> --- >>  drivers/scsi/mpt3sas/mpt3sas_base.c | 1 + >>  1

Re: [PATCH] mpt3sas: Add an i/o barrier

2018-05-24 Thread James Bottomley
On Thu, 2018-05-24 at 17:12 +0200, Tomas Henzl wrote: > A barrier should be added to ensure proper ordering of memory mapped > writes. > > Signed-off-by: Tomas Henzl > --- >  drivers/scsi/mpt3sas/mpt3sas_base.c | 1 + >  1 file changed, 1 insertion(+) > > diff --git

[PATCH] mpt3sas: Add an i/o barrier

2018-05-24 Thread Tomas Henzl
A barrier should be added to ensure proper ordering of memory mapped writes. Signed-off-by: Tomas Henzl --- drivers/scsi/mpt3sas/mpt3sas_base.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/scsi/mpt3sas/mpt3sas_base.c b/drivers/scsi/mpt3sas/mpt3sas_base.c index

Re: [PATCH 6/6] scsi: Check sense buffer size at build time

2018-05-24 Thread Christoph Hellwig
> +/* Make sure any sense buffer is the correct size. */ > +#define scsi_execute(sdev, cmd, data_direction, buffer, bufflen, sense, > \ > + sshdr, timeout, retries, flags, rq_flags, resid) \ > +({ \ > +

[PATCH 1/2 v2] scsi: libsas: remove irq save in sas_ata_qc_issue()

2018-05-24 Thread Sebastian Andrzej Siewior
Since commit 312d3e56119a ("[SCSI] libsas: remove ata_port.lock management duties from lldds") the sas_ata_qc_issue() function unlocks the ata_port.lock and disables interrupts before doing so. That lock is always taken with disabled interrupts so at this point, the interrupts are already

Re: [PATCH V2] PCI/portdrv: do not disable device on reboot/shutdown

2018-05-24 Thread okaya
On 2018-05-24 09:07, Bjorn Helgaas wrote: On Thu, May 24, 2018 at 07:43:05AM -0400, Sinan Kaya wrote: On 5/23/2018 6:57 PM, Sinan Kaya wrote: >> The crash seems to indicate that the hpsa device attempted a DMA after >> we cleared the Root Port's PCI_COMMAND_MASTER, which means >>

Re: [PATCH V2] PCI/portdrv: do not disable device on reboot/shutdown

2018-05-24 Thread Bjorn Helgaas
On Thu, May 24, 2018 at 07:43:05AM -0400, Sinan Kaya wrote: > On 5/23/2018 6:57 PM, Sinan Kaya wrote: > >> The crash seems to indicate that the hpsa device attempted a DMA after > >> we cleared the Root Port's PCI_COMMAND_MASTER, which means > >> hpsa_shutdown() didn't stop DMA from the device (it

RE: [PATCH RFC 0/3] Add ufs provisioning support in driver

2018-05-24 Thread Stanislav Nijnikov
Hi Sayali, I have several notes about the patches: 1. New descriptors structures are redefinition of the descriptors info (see definitions of device_desc_param, unit_desc_param, etc in drivers/scsi/ufs/ufs.h) 2. You didn't took into consideration the recently added UFS sysfs infostructure. 3.

Re: [PATCH V2] PCI/portdrv: do not disable device on reboot/shutdown

2018-05-24 Thread Sinan Kaya
On 5/23/2018 6:57 PM, Sinan Kaya wrote: >> The crash seems to indicate that the hpsa device attempted a DMA after >> we cleared the Root Port's PCI_COMMAND_MASTER, which means >> hpsa_shutdown() didn't stop DMA from the device (it looks like *most* >> shutdown methods don't disable device DMA, so

[PATCH 4.16 108/161] scsi: devinfo: add HP DISK-SUBSYSTEM device, for HP XP arrays

2018-05-24 Thread Greg Kroah-Hartman
4.16-stable review patch. If anyone has any objections, please let me know. -- From: Xose Vazquez Perez [ Upstream commit 5f96f42b76e00e2871033745ff029056cc725c76 ] "The DISK-SUBSYSTEM is a special model name returned when LUs are not installed. For

[PATCH] scsi: qla2xxx: reduce the time granularity of the qla2x00_eh_wait_on_command

2018-05-24 Thread Jianchao Wang
If the cmd has not be returned after aborted by qla2x00_eh_abort, when qla2x00_eh_wait_on_command is invoked, it has to wait for it. However, the time is 1000ms at least currently. If there are a lot cmds need to be aborted, the delay could be long enough to lead to panic due to such as hung task,

Re: BUG: scsi/qla2xxx: BUG_ON(blk_queued_rq(req) is triggered in blk_finish_request

2018-05-24 Thread jianchao.wang
Hi Himanshu Thanks god get response from your side finally :) I get qla2xxx-upstr...@qlogic.com from the maintainer information of driver/scsi/qla2xxx Looks like it should be modified. Thanks Jianchao On 05/24/2018 12:21 PM, Madhani, Himanshu wrote: > Hi, > > Yes. We'll look at this issue.

Re: [PATCH 1/2] libsas: remove irq save in sas_ata_qc_issue()

2018-05-24 Thread Sebastian Andrzej Siewior
On 2018-05-24 16:20:33 [+0800], Jason Yan wrote: > NO, this: > > /* TODO: audit callers to ensure they are ready for qc_issue to >* unconditionally re-enable interrupts >*/ > local_irq_save(flags); > spin_unlock(ap->lock); indeed, I have no idea how I could have

Re: [PATCH 1/2] libsas: remove irq save in sas_ata_qc_issue()

2018-05-24 Thread Jason Yan
On 2018/5/24 16:18, Sebastian Andrzej Siewior wrote: On 2018-05-24 16:00:47 [+0800], Jason Yan wrote: Because you are trying to delete the irq-save code which will make the comment hard to understand, I'm just giving an advise. It's welcome if you have a better way. I am removing

Re: [PATCH 1/2] libsas: remove irq save in sas_ata_qc_issue()

2018-05-24 Thread Sebastian Andrzej Siewior
On 2018-05-24 16:00:47 [+0800], Jason Yan wrote: > > > Because you are trying to delete the irq-save code which will make the > > > comment hard to understand, I'm just giving an advise. It's welcome > > > if you have a better way. > > > > I am removing local_irq_save() prior an unlock of a lock

Re: [PATCH 1/2] libsas: remove irq save in sas_ata_qc_issue()

2018-05-24 Thread Jason Yan
On 2018/5/24 15:52, Sebastian Andrzej Siewior wrote: On 2018-05-24 15:38:51 [+0800], Jason Yan wrote: no, please don't do this. Please add instead lockdep_assert_held() on the lock in question and let lockdep to its work. Lockdep has way better coverage than your irqs_disabled()

Re: [PATCH 3/6] block: Create scsi_sense.h for SCSI and ATAPI

2018-05-24 Thread Christoph Hellwig
On Wed, May 23, 2018 at 03:14:19PM -0600, Jens Axboe wrote: > Ugh, so that would necessitate a change there too. As I said before, > I don't really care where it lives. I know the SCSI folks seem bothered > by moving it, but in reality, it's not like this stuff will likely ever > really change. Of

Re: [PATCH 1/2] libsas: remove irq save in sas_ata_qc_issue()

2018-05-24 Thread Jason Yan
On 2018/5/24 15:50, Johannes Thumshirn wrote: On Thu, May 24, 2018 at 03:38:51PM +0800, Jason Yan wrote: On 2018/5/24 15:15, Sebastian Andrzej Siewior wrote: On 2018-05-24 10:58:44 [+0800], Jason Yan wrote: I think it's fine to delete this irq save code. As for the "TODO" comment, I think

Re: [PATCH 1/2] libsas: remove irq save in sas_ata_qc_issue()

2018-05-24 Thread Sebastian Andrzej Siewior
On 2018-05-24 09:50:07 [+0200], Johannes Thumshirn wrote: > > lockdep_assert_held() cannot detect the irq state, it can only detect > > whether we have held the lock. > > I think Sebastian wanted to say lockdep_assert_irqs_disabled(). nope, meant the right thing. > Byte, > Johannes

Re: [PATCH 1/2] libsas: remove irq save in sas_ata_qc_issue()

2018-05-24 Thread Sebastian Andrzej Siewior
On 2018-05-24 15:38:51 [+0800], Jason Yan wrote: > > no, please don't do this. Please add instead > > lockdep_assert_held() > > > > on the lock in question and let lockdep to its work. Lockdep has way > > better coverage than your irqs_disabled() check which also breaks RT. > > > >

Re: [PATCH 1/2] libsas: remove irq save in sas_ata_qc_issue()

2018-05-24 Thread Johannes Thumshirn
On Thu, May 24, 2018 at 03:38:51PM +0800, Jason Yan wrote: > > > On 2018/5/24 15:15, Sebastian Andrzej Siewior wrote: > > On 2018-05-24 10:58:44 [+0800], Jason Yan wrote: > > > I think it's fine to delete this irq save code. As for the "TODO" > > > comment, I think we can add: > > > > > >

Re: [PATCH 1/2] libsas: remove irq save in sas_ata_qc_issue()

2018-05-24 Thread Jason Yan
On 2018/5/24 15:15, Sebastian Andrzej Siewior wrote: On 2018-05-24 10:58:44 [+0800], Jason Yan wrote: I think it's fine to delete this irq save code. As for the "TODO" comment, I think we can add: BUG_ON(!irqs_disabled()); or WARN_ON_ONCE(!irqs_disabled()); no, please don't do this.

Re: [PATCH 3/6] block: Create scsi_sense.h for SCSI and ATAPI

2018-05-24 Thread Christoph Hellwig
On Wed, May 23, 2018 at 02:17:14PM -0700, Kees Cook wrote: > > True, though I'm finding other robustness issues in the CDROM code. > They're probably all insane corner cases, but it seems like it'd be > nice to just fix them: > > diff --git a/drivers/cdrom/cdrom.c b/drivers/cdrom/cdrom.c > index

Re: [PATCH 1/2] libsas: remove irq save in sas_ata_qc_issue()

2018-05-24 Thread Sebastian Andrzej Siewior
On 2018-05-24 10:58:44 [+0800], Jason Yan wrote: > I think it's fine to delete this irq save code. As for the "TODO" > comment, I think we can add: > > BUG_ON(!irqs_disabled()); > > or > > WARN_ON_ONCE(!irqs_disabled()); no, please don't do this. Please add instead

[Bug 198689] Setro has no effect for SCSI device

2018-05-24 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=198689 Li Ning (yzlin...@foxmail.com) changed: What|Removed |Added Status|NEW |RESOLVED