Re: [PATCH 05/11] IB/iser: Replace fastreg descriptor valid bool with indicators container

2014-02-23 Thread Nicholas A. Bellinger
On Sun, 2014-02-23 at 22:53 -0800, Nicholas A. Bellinger wrote: > On Sun, 2014-02-23 at 14:19 +0200, Sagi Grimberg wrote: > > In T10-PI support we will have memory keys for protection > > buffers and signature transactions. We prefer to compact > > indicators rather than keeping multiple bools. > >

Re: [PATCH 05/11] IB/iser: Replace fastreg descriptor valid bool with indicators container

2014-02-23 Thread Nicholas A. Bellinger
On Sun, 2014-02-23 at 14:19 +0200, Sagi Grimberg wrote: > In T10-PI support we will have memory keys for protection > buffers and signature transactions. We prefer to compact > indicators rather than keeping multiple bools. > > This commit does not change any functionality. > > Signed-off-by: Sag

Re: [PATCH 08/11] IB/iser: Support T10-PI operations

2014-02-23 Thread Nicholas A. Bellinger
On Sun, 2014-02-23 at 14:19 +0200, Sagi Grimberg wrote: > Add logic to initialize protection information entities. > Upon each iSCSI task, we keep the scsi_cmnd in order to > query the scsi protection operations and reference to > protection buffers. > > Modify iser_fast_reg_mr to receive indicati

[RFC 2/6] vhost/scsi: Add preallocation of protection SGLs

2014-02-23 Thread Nicholas A. Bellinger
From: Nicholas Bellinger This patch updates tcm_vhost_make_nexus() to pre-allocate per descriptor tcm_vhost_cmd->tvc_prot_sgl[] used to expose protection SGLs from within virtio-scsi guest memory to vhost-scsi. Cc: Michael S. Tsirkin Cc: Paolo Bonzini Cc: Martin K. Petersen Cc: Christoph Hell

[RFC 1/6] vhost/scsi: Move sanity check into vhost_scsi_map_iov_to_sgl

2014-02-23 Thread Nicholas A. Bellinger
From: Nicholas Bellinger Move the overflow check for sgl_count > TCM_VHOST_PREALLOC_SGLS into vhost_scsi_map_iov_to_sgl() so that it's based on the total number of SGLs for all IOVs, instead of single IOVs. Also, rename TCM_VHOST_PREALLOC_PAGES -> TCM_VHOST_PREALLOC_UPAGES to better describe poi

[RFC 3/6] vhost/scsi: Add T10 PI IOV -> SGL memory mapping logic

2014-02-23 Thread Nicholas A. Bellinger
From: Nicholas Bellinger This patch adds vhost_scsi_map_iov_to_prot() to perform the mapping of T10 data integrity memory between virtio iov + struct scatterlist using get_user_pages_fast() following existing code. As with vhost_scsi_map_iov_to_sgl(), this does sanity checks against the total pr

[RFC 6/6] virtio-scsi: Enable DIF/DIX modes in SCSI host LLD

2014-02-23 Thread Nicholas A. Bellinger
From: Nicholas Bellinger This patch updates virtscsi_probe() to setup all necessary Scsi_Host level protection resources necessary to enable DIF on virtio-scsi <-> vhost-scsi LUNs. Currently hardcoded to 1. It changes virtscsi_add_cmd() so that outgoing / incoming protection SGLs are attached a

[RFC 5/6] vhost/scsi: Add new VIRTIO_SCSI_F_T10_PI feature bit

2014-02-23 Thread Nicholas A. Bellinger
From: Nicholas Bellinger This patch adds a VIRTIO_SCSI_F_T10_PI feature bit for signaling host support of accepting T10 protection information SGLs from virtio-scsi guest. Cc: Michael S. Tsirkin Cc: Paolo Bonzini Cc: Martin K. Petersen Cc: Christoph Hellwig Cc: Hannes Reinecke Cc: Sagi Grim

[PATCH v13 0/3] ata: Add APM X-Gene SoC AHCI SATA host controller support

2014-02-23 Thread Loc Ho
This patch adds support for the APM X-Gene SoC AHCI SATA host controller. In order for the host controller to work, the corresponding PHY driver musts also be available. v13: * Add fully-winged style comment for function xgene_ahci_read_id and xgene_ahci_do_hardrest * Minor comments update fo

[PATCH v13 1/3] Documentation: Add documentation for APM X-Gene SoC SATA host controller DTS binding

2014-02-23 Thread Loc Ho
Signed-off-by: Loc Ho Signed-off-by: Tuan Phan Signed-off-by: Suman Tripathi --- .../devicetree/bindings/ata/apm-xgene.txt | 70 1 files changed, 70 insertions(+), 0 deletions(-) create mode 100644 Documentation/devicetree/bindings/ata/apm-xgene.txt diff --git

[PATCH v13 3/3] arm64: Add APM X-Gene SoC AHCI SATA host controller DTS entries

2014-02-23 Thread Loc Ho
Signed-off-by: Loc Ho Signed-off-by: Tuan Phan Signed-off-by: Suman Tripathi --- arch/arm64/boot/dts/apm-storm.dtsi | 75 1 files changed, 75 insertions(+), 0 deletions(-) diff --git a/arch/arm64/boot/dts/apm-storm.dtsi b/arch/arm64/boot/dts/apm-storm.dt

[PATCH v13 2/3] ata: Add APM X-Gene SoC AHCI SATA host controller driver

2014-02-23 Thread Loc Ho
This patch adds support for the APM X-Gene SoC AHCI SATA host controller driver. It requires the corresponding APM X-Gene SoC PHY driver. Signed-off-by: Loc Ho Signed-off-by: Tuan Phan Signed-off-by: Suman Tripathi --- drivers/ata/Kconfig |8 + drivers/ata/Makefile |1 + drive

[RFC 0/6] vhost/scsi: Add T10 PI SGL passthrough support

2014-02-23 Thread Nicholas A. Bellinger
From: Nicholas Bellinger Hi MST, MKP, Paolo & Co, The following is an initial RFC series for allowing vhost/scsi to accept T10 protection information (PI) as seperate SGLs along side existing data payload SGLs from within virtio-scsi guest memory. In it's current form, both ends are using virti

[RFC 4/6] vhost/scsi: Enable T10 PI IOV -> SGL memory mapping

2014-02-23 Thread Nicholas A. Bellinger
From: Nicholas Bellinger This patch updates vhost_scsi_handle_vq() to calculate a data_niov + prot_niov currently based upon virtio_scsi_cmd_req->prio for figuring out many of seperate data + protection SGLs to expect from data_num. Also update tcm_vhost_submission_work() to pass the pre-allocat

Re: Proposal for a scalable SCSI midlayer

2014-02-23 Thread Christoph Hellwig
On Sun, Feb 23, 2014 at 02:10:18PM -0600, James Bottomley wrote: > If we can do this, that would be great, because it cuts down on the > maintenance burden for all of us and gives some benefits at least to > non-MQ hardware. So far this seems to work out great, and I think we will be able to stick

Re: memory-barriers.txt again (was Re: [PATCH 4/9] firewire: don't use PREPARE_DELAYED_WORK)

2014-02-23 Thread Stefan Richter
On Feb 23 Paul E. McKenney wrote: >>> Please see below for a patch against the current version of >>> Documentation/memory-barriers.txt. Does this update help? Thank you, this clarifies it. [...] A new nit: > +The operations will always occur in one of the following orders: > > - STORE *A,

Re: memory-barriers.txt again (was Re: [PATCH 4/9] firewire: don't use PREPARE_DELAYED_WORK)

2014-02-23 Thread Peter Hurley
On 02/23/2014 06:50 PM, Paul E. McKenney wrote: On Sun, Feb 23, 2014 at 03:35:31PM -0500, Peter Hurley wrote: Hi Paul, On 02/23/2014 11:37 AM, Paul E. McKenney wrote: commit aba6b0e82c9de53eb032844f1932599f148ff68d Author: Paul E. McKenney Date: Sun Feb 23 08:34:24 2014 -0800 Document

Re: memory-barriers.txt again (was Re: [PATCH 4/9] firewire: don't use PREPARE_DELAYED_WORK)

2014-02-23 Thread Paul E. McKenney
On Sun, Feb 23, 2014 at 03:35:31PM -0500, Peter Hurley wrote: > Hi Paul, > > On 02/23/2014 11:37 AM, Paul E. McKenney wrote: > >commit aba6b0e82c9de53eb032844f1932599f148ff68d > >Author: Paul E. McKenney > >Date: Sun Feb 23 08:34:24 2014 -0800 > > > > Documentation/memory-barriers.txt: Clar

Re: [PATCH 4/9] firewire: don't use PREPARE_DELAYED_WORK

2014-02-23 Thread Peter Hurley
Hi James, On 02/23/2014 03:05 PM, James Bottomley wrote: On Sat, 2014-02-22 at 14:03 -0500, Peter Hurley wrote: If it is necessary for a RELEASE-ACQUIRE pair to produce a full barrier, the ACQUIRE can be followed by an smp_mb__after_unlock_lock() invocation. This will produce a full barrier if

Re: memory-barriers.txt again (was Re: [PATCH 4/9] firewire: don't use PREPARE_DELAYED_WORK)

2014-02-23 Thread Peter Hurley
Hi Paul, On 02/23/2014 11:37 AM, Paul E. McKenney wrote: commit aba6b0e82c9de53eb032844f1932599f148ff68d Author: Paul E. McKenney Date: Sun Feb 23 08:34:24 2014 -0800 Documentation/memory-barriers.txt: Clarify release/acquire ordering This commit fixes a couple of typos and clarif

Re: [PATCH 0/4] isci, libsas fixes for 3.4-rc2

2014-02-23 Thread James Bottomley
On Thu, 2014-02-06 at 12:22 -0800, Dan Williams wrote: > Hi James, > > Here are some collected fixes. All but patch 2 are tagged for -stable. > > Patch 1 and 4 have been on the list since before the 3.14 merge window, > patch 2 and 3 are new. > > Please apply, thank you. > > [PATCH 1/4] isci:

Re: Proposal for a scalable SCSI midlayer

2014-02-23 Thread James Bottomley
On Wed, 2014-02-05 at 04:39 -0800, Christoph Hellwig wrote: > We've run into many issues where the SCSI layer simply does not scale to > keep up with today's hardware, be that in simple single-thread IOPs, or > in lock contention when using multiple LUNs or targets under a single > SCSI host. Thi

Re: [PATCH 4/9] firewire: don't use PREPARE_DELAYED_WORK

2014-02-23 Thread James Bottomley
On Sat, 2014-02-22 at 14:03 -0500, Peter Hurley wrote: > If it is necessary for a RELEASE-ACQUIRE pair to produce a full barrier, the > ACQUIRE can be followed by an smp_mb__after_unlock_lock() invocation. This > will produce a full barrier if either (a) the RELEASE and the ACQUIRE are > executed

Re: [PATCH 12/22] lpfc: Use pci_enable_msix_range()

2014-02-23 Thread Alexander Gordeev
On Thu, Feb 20, 2014 at 11:47:02AM -0500, James Smart wrote: > Alexander, > > I've reworked this patch to layer on top of our rev 8.3.45 patches > that were just posted to linux-scsi. There were some conflicts due to > new additions. Additionally, there were two other uses of pci_enable_msiXXX >

Re: memory-barriers.txt again (was Re: [PATCH 4/9] firewire: don't use PREPARE_DELAYED_WORK)

2014-02-23 Thread Paul E. McKenney
On Sun, Feb 23, 2014 at 02:23:03AM +0100, Stefan Richter wrote: > Hi Paul, > > in patch "Documentation/memory-barriers.txt: Downgrade UNLOCK+BLOCK" (sic), > you wrote: > + Memory operations issued before the LOCK may be completed after the > + LOCK operation has completed. An smp_mb__befo

[PATCH 07/11] IB/iser: Initialize T10-PI resources

2014-02-23 Thread Sagi Grimberg
During connection establishment we also initiatlize T10-PI resources (QP, PI contexts) in order to support SCSI's protection operations. Signed-off-by: Sagi Grimberg --- drivers/infiniband/ulp/iser/iscsi_iser.h | 19 ++ drivers/infiniband/ulp/iser/iser_initiator.c |8 +++ drivers/i

[PATCH 03/11] IB/iser: Move fast_reg_descriptor initialization to a function

2014-02-23 Thread Sagi Grimberg
fastreg descriptor will include protection information context. In order to place the logic in one place we introduce iser_create_fr_desc function. This patch does not change any functionality. Signed-off-by: Sagi Grimberg --- drivers/infiniband/ulp/iser/iser_verbs.c | 58

[PATCH 09/11] SCSI/libiscsi: Add check_protection callback for transports

2014-02-23 Thread Sagi Grimberg
iSCSI needs to be at least aware that a task involves protection information. In case it does, after the transaction completed libiscsi will ask the transport to check the protection status of the transaction. Unlike transport errors, DIF errors should not prevent successful completion of the tran

[PATCH 11/11] IB/iser: Publish T10-PI support to SCSI midlayer

2014-02-23 Thread Sagi Grimberg
After allocating a scsi_host we set protection types and guard type supported. Signed-off-by: Sagi Grimberg --- drivers/infiniband/ulp/iser/iscsi_iser.c | 23 ++- 1 files changed, 22 insertions(+), 1 deletions(-) diff --git a/drivers/infiniband/ulp/iser/iscsi_iser.c b/dri

[PATCH 05/11] IB/iser: Replace fastreg descriptor valid bool with indicators container

2014-02-23 Thread Sagi Grimberg
In T10-PI support we will have memory keys for protection buffers and signature transactions. We prefer to compact indicators rather than keeping multiple bools. This commit does not change any functionality. Signed-off-by: Sagi Grimberg --- drivers/infiniband/ulp/iser/iscsi_iser.h |8

[PATCH 08/11] IB/iser: Support T10-PI operations

2014-02-23 Thread Sagi Grimberg
Add logic to initialize protection information entities. Upon each iSCSI task, we keep the scsi_cmnd in order to query the scsi protection operations and reference to protection buffers. Modify iser_fast_reg_mr to receive indication weather it is registering the data or protection buffers. In add

[PATCH 02/11] IB/iser: Push the desicion what memory key to use into fast_reg_mr routine

2014-02-23 Thread Sagi Grimberg
This is a preparation step for T10-PI offload support. We prefer to push the desicion of which mkey to use (global or fastreg) to iser_fast_reg_mr. We choose to do this since it in T10-PI we may need to register for protection buffers and in this case we wish to simplify iser_fast_reg_mr instead of

[PATCH 00/11] T10-PI Initial support for iSER initiator

2014-02-23 Thread Sagi Grimberg
Hey Roland, Nic and Co This patchset adds T10 protection information offload support over RDMA signature verbs API. This set, along with the iSER target set, allow end-to-end protection information passthrough and validation. The patchset was tested against Linux SCSI target with iSER DIF support

[PATCH 04/11] IB/iser: Keep IB device attributes under iser_device

2014-02-23 Thread Sagi Grimberg
For T10-PI offload support, we will need to know the device signature offload capability upon every connection establishment. This patch does not change any functionality. Signed-off-by: Sagi Grimberg --- drivers/infiniband/ulp/iser/iscsi_iser.h |1 + drivers/infiniband/ulp/iser/iser_verbs.

[PATCH 01/11] IB/iser: Avoid FRWR notation, use fastreg instead

2014-02-23 Thread Sagi Grimberg
FRWR stands for "fast registration work request". We want to avoid calling the fastreg pool with that name, instead we name it fastreg which stands for "fast registration". This pool will include more elements in the future, so it is a good idea to generalize the name. Signed-off-by: Sagi Grimber

[PATCH 06/11] IB/iser: Introduce pi_enable, pi_guard module parameters

2014-02-23 Thread Sagi Grimberg
Use modparams to activate protection information support. pi_enable bool: Based on this parameter iSER will know if it should support T10-PI. We don't want to do this by default as it requires to allocate and initiatlize extra resources. In case pi_enable=N, iSER won't publish to SCSI midlayer any

[PATCH 10/11] IB/iser: Implement check_protection

2014-02-23 Thread Sagi Grimberg
Once the iSCSI transaction is completed we must imeplement check_protection in order to notify on DIF errors that may have occured. The routine boils down to calling ib_check_mr_status to get the signature status of the transaction. Signed-off-by: Sagi Grimberg --- drivers/infiniband/ulp/iser/i