[PATCH v3] ufs: introduce UFSHCD_QUIRK_PRDT_BYTE_GRAN quirk

2016-11-18 Thread Kiwoong Kim
Some UFS host controllers may think granularities of PRDT length and offset as bytes, not double words. Signed-off-by: Kiwoong Kim --- V2: change the name of the quirk (UFSHCD_QUIRK_BROKEN_DWORD_UTRD -> UFSHCD_QUIRK_PRDT_BYTE_GRAN) V3: (rebased to 4.10/scsi-queue tip) ---

[PATCH] ufs: qcom: Properly clear hba priv on failure

2016-11-18 Thread Bjorn Andersson
In the case where we fail to acquire the phy the hba priv will be set already, so during cleanup ufs_qcom_setup_clocks() will dereference the now free, but still "valid looking" pointer "host". Signed-off-by: Bjorn Andersson --- drivers/scsi/ufs/ufs-qcom.c | 2 +- 1

Re: [RFC PATCH] scsi: libsas: fix WARN on device removal

2016-11-18 Thread Dan Williams
On Fri, Nov 18, 2016 at 1:00 AM, John Garry wrote: > On 18/11/2016 01:53, Dan Williams wrote: >> >> On Thu, Nov 17, 2016 at 7:23 AM, John Garry wrote: >>> >>> On 11/11/2016 08:49, wangyijing wrote: >>> >>> >>> I have not seen the flutter

Re: [PATCH net-next] cxgb4: Allocate Tx queues dynamically

2016-11-18 Thread David Miller
From: Atul Gupta Date: Fri, 18 Nov 2016 16:37:40 +0530 > From: Hariprasad Shenai > > Allocate resources dynamically for Upper layer driver's (ULD) like > cxgbit, iw_cxgb4, cxgb4i and chcr. The resources allocated include Tx > queues which are

RE: [PATCH 5/5] megaraid_sas: add mmio barrier after register writes

2016-11-18 Thread Kashyap Desai
> -Original Message- > From: linux-scsi-ow...@vger.kernel.org [mailto:linux-scsi- > ow...@vger.kernel.org] On Behalf Of Tomas Henzl > Sent: Friday, November 18, 2016 9:23 PM > To: Hannes Reinecke; Martin K. Petersen > Cc: Christoph Hellwig; James Bottomley; Sumit Saxena; linux- >

Re: use PCI layer IRQ affinity in lpfc

2016-11-18 Thread James Smart
Hi Christoph, We had already done this work in the larger lpfc patch that had been posted for nvme work. I'll look at separating out just the irq part and post a reply. -- james On 11/17/2016 7:14 AM, Christoph Hellwig wrote: This series has two patches: the first is a simple conversion

[PATCH] isci: avoid array subscript warning

2016-11-18 Thread Arnd Bergmann
I'm getting a new warning with gcc-7: isci/remote_node_context.c: In function 'sci_remote_node_context_destruct': isci/remote_node_context.c:69:16: error: array subscript is above array bounds [-Werror=array-bounds] This is odd, since we clearly cover all values for enum

Re: [PATCH 5/5] megaraid_sas: add mmio barrier after register writes

2016-11-18 Thread Tomas Henzl
On 11.11.2016 10:44, Hannes Reinecke wrote: > The megaraid_sas HBA only has a single register for I/O submission, > which will be hit pretty hard with scsi-mq. To ensure that the > PCI writes have made it across we need to add a mmio barrier > after each write; otherwise I've been seeing spurious

Re: [PATCH 1/5] scsi: bnx2i: convert to kworker

2016-11-18 Thread Christoph Hellwig
On Fri, Nov 18, 2016 at 03:39:32PM +0100, Sebastian Andrzej Siewior wrote: > On 2016-11-18 13:56:22 [+0100], Christoph Hellwig wrote: > > still says kwork in the subject.. > > I was thinking about this before sending it out. But then it uses the > generic workqueue / kworker and a custom kthread

Re: [PATCH 1/5] scsi: bnx2i: convert to kworker

2016-11-18 Thread Sebastian Andrzej Siewior
On 2016-11-18 13:56:22 [+0100], Christoph Hellwig wrote: > still says kwork in the subject.. I was thinking about this before sending it out. But then it uses the generic workqueue / kworker and a custom kthread like it did before. What would you prefer to call it then? Just workqueue? Sebastian

Re: use PCI layer IRQ affinity in lpfc

2016-11-18 Thread Johannes Thumshirn
On Fri, Nov 18, 2016 at 05:22:11AM -0800, Christoph Hellwig wrote: > On Fri, Nov 18, 2016 at 02:13:12PM +0100, Johannes Thumshirn wrote: > > This is what /proc/interrupts looks like after booting from the lpfc HBA, > > with your patches: > > > > ettrick:~ # grep lpfc /proc/interrupts > > 44:

Re: use PCI layer IRQ affinity in lpfc

2016-11-18 Thread Johannes Thumshirn
On Fri, Nov 18, 2016 at 05:22:11AM -0800, Christoph Hellwig wrote: > On Fri, Nov 18, 2016 at 02:13:12PM +0100, Johannes Thumshirn wrote: > > This is what /proc/interrupts looks like after booting from the lpfc HBA, > > with your patches: > > > > ettrick:~ # grep lpfc /proc/interrupts > > 44:

Re: use PCI layer IRQ affinity in lpfc

2016-11-18 Thread Hannes Reinecke
On 11/18/2016 02:13 PM, Johannes Thumshirn wrote: > Hi Christoph, > > On Thu, Nov 17, 2016 at 04:14:51PM +0100, Christoph Hellwig wrote: >> This series has two patches: the first is a simple conversion of >> lpfc to use pci_alloc_irq_vectors. The second is more interesting, >> and makes use of

Re: use PCI layer IRQ affinity in lpfc

2016-11-18 Thread Christoph Hellwig
On Fri, Nov 18, 2016 at 02:13:12PM +0100, Johannes Thumshirn wrote: > This is what /proc/interrupts looks like after booting from the lpfc HBA, > with your patches: > > ettrick:~ # grep lpfc /proc/interrupts > 44: 2056 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 PCI-MSI 5242880-edge lpfc > 46: 2186 0 0 0

Re: [PATCH] bfa: turn bfa_mem_{kva,dma}_setup into inline functions

2016-11-18 Thread Johannes Thumshirn
On Wed, Nov 16, 2016 at 04:14:27PM +0100, Arnd Bergmann wrote: > These two macros cause lots of warnings with gcc-7: > > drivers/scsi/bfa/bfa_svc.c: In function 'bfa_fcxp_meminfo': > drivers/scsi/bfa/bfa_svc.c:521:103: error: '*' in boolean context, suggest > '&&' instead

Re: use PCI layer IRQ affinity in lpfc

2016-11-18 Thread Johannes Thumshirn
Hi Christoph, On Thu, Nov 17, 2016 at 04:14:51PM +0100, Christoph Hellwig wrote: > This series has two patches: the first is a simple conversion of > lpfc to use pci_alloc_irq_vectors. The second is more interesting, > and makes use of the PCI_IRQ_AFFINITY option to use the core interrupt >

Re: [PATCH 1/5] scsi: bnx2i: convert to kworker

2016-11-18 Thread Christoph Hellwig
still says kwork in the subject.. -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH] mpt2sas: Fix secure erase premature termination.

2016-11-18 Thread Greg KH
On Fri, Nov 18, 2016 at 05:12:49PM +0530, Suganath Prabu S wrote: > Problem: > This is a work around for a bug with LSI Fusion MPT SAS2 when > pefroming secure erase. Due to the very long time the operation > takes commands issued during the erase will time out and will trigger > execution of

[patch] scsi: be2iscsi: allocate enough memory in beiscsi_boot_get_sinfo()

2016-11-18 Thread Dan Carpenter
We accidentally allocate sizeof(u32) instead of sizeof(struct be_cmd_get_session_resp). Fixes: 50a4b824be9e ("scsi: be2iscsi: Fix to make boot discovery non-blocking") Signed-off-by: Dan Carpenter diff --git a/drivers/scsi/be2iscsi/be_mgmt.c

[PATCH] mpt2sas: Fix secure erase premature termination.

2016-11-18 Thread Suganath Prabu S
Problem: This is a work around for a bug with LSI Fusion MPT SAS2 when pefroming secure erase. Due to the very long time the operation takes commands issued during the erase will time out and will trigger execution of abort hook. Even though the abort hook is called for the specific command which

[PATCH net-next] cxgb4: Allocate Tx queues dynamically

2016-11-18 Thread Atul Gupta
From: Hariprasad Shenai Allocate resources dynamically for Upper layer driver's (ULD) like cxgbit, iw_cxgb4, cxgb4i and chcr. The resources allocated include Tx queues which are allocated when ULD register with cxgb4 driver and freed while un-registering. The Tx queues

[PATCH 4/5] scsi: bnx2fc: annoate unlock + release for sparse

2016-11-18 Thread Sebastian Andrzej Siewior
The caller of bnx2fc_abts_cleanup() holds the tgt->tgt_lock lock and it is expected to release the lock during wait_for_completion() and acquire the lock afterwards. This patch was only compile-tested due to -ENODEV. Cc: qlogic-storage-upstr...@qlogic.com Cc: Christoph Hellwig

[PATCH 1/5] scsi: bnx2i: convert to kworker

2016-11-18 Thread Sebastian Andrzej Siewior
The driver creates its own per-CPU threads which are updated based on CPU hotplug events. It is also possible to use kworkers and remove some of the infrastructure get the same job done while saving a few lines of code. The DECLARE_PER_CPU() definition is moved into the header file where it

[PATCH 3/5] scsi: bnx2fc: clean up header definitions

2016-11-18 Thread Sebastian Andrzej Siewior
- All symbols which are only used within one .c file are marked static and removed from the bnx2fc.h file if possible. - the declarion of bnx2fc_percpu is moved into the header file This patch was only compile-tested due to -ENODEV. Cc: qlogic-storage-upstr...@qlogic.com Cc: Christoph Hellwig

[PATCH 5/5] scsi: bnx2fc: convert bnx2fc_l2_rcv_thread() to worker

2016-11-18 Thread Sebastian Andrzej Siewior
This is not driven by the hotplug conversation but while I am at it looks like a good candidate. Converting the thread to a kworker user removes also the kthread member from struct fcoe_percpu_s. This driver uses the struct fcoe_percpu_s but it does not need the crc_eof_page member, only the work

bnx2i + bnx2fc: convert to generic workqueue

2016-11-18 Thread Sebastian Andrzej Siewior
This is the second repost + fixups to get the patches applied against v4.9-rc4. mkp's scsi for-next tree can be merged with no conflicts. The last repost was not merged and stalled after Chad Dupuis said to hold on because he is testing but never came back with the results [0]. Johannes confirmed

[PATCH 2/5] scsi: bnx2fc: convert per-CPU thread to kworker

2016-11-18 Thread Sebastian Andrzej Siewior
The driver creates its own per-CPU threads which are updated based on CPU hotplug events. It is also possible to use kworkers and remove some of the infrastructure get the same job done while saving a few lines of code. bnx2fc_percpu_io_thread() becomes bnx2fc_percpu_io_work() which is mostly the

[PATCH v2] ata: xgene: Enable NCQ support for APM X-Gene SATA controller hardware v1.1

2016-11-18 Thread Rameshwar Prasad Sahu
This patch enables NCQ support for APM X-Gene SATA controller hardware v1.1 that was broken with hardware v1.0. Second thing, here we should not assume XGENE_AHCI_V2 always in case of having valid _CID in ACPI table. I need to remove this assumption because V1_1 also has a valid _CID for backward

Re: [RFC PATCH] scsi: libsas: fix WARN on device removal

2016-11-18 Thread John Garry
On 18/11/2016 01:53, Dan Williams wrote: On Thu, Nov 17, 2016 at 7:23 AM, John Garry wrote: On 11/11/2016 08:49, wangyijing wrote: I have not seen the flutter issue. I am just trying to solve the horrible WARN dump. However I do understand that there may be a issue