Re: [PATCH v3 3/7] scsi: ufs: Add fill task management request

2018-09-05 Thread Christoph Hellwig
On Wed, Sep 05, 2018 at 07:08:50PM +0200, Christoph Hellwig wrote: > On Wed, Sep 05, 2018 at 03:53:41PM +, Avri Altman wrote: > > But on the other hand, task management request and response UPIUs > > are honorable members of the ufs spec (JEDEC 220C paragraphs 10.7.6 & > > 10.7.7). > > and

Re: [PATCH v3 3/7] scsi: ufs: Add fill task management request

2018-09-05 Thread Christoph Hellwig
On Wed, Sep 05, 2018 at 03:53:41PM +, Avri Altman wrote: > But on the other hand, task management request and response UPIUs > are honorable members of the ufs spec (JEDEC 220C paragraphs 10.7.6 & 10.7.7). > and indeed they lives in ufs.h, where they should. There is no other use anywhere.

RE: [PATCH v3 3/7] scsi: ufs: Add fill task management request

2018-09-05 Thread Avri Altman
> On Wed, Sep 05, 2018 at 07:30:03AM +, Avri Altman wrote: > > Looking into the UFSHCI spec (JESD223C March 2016) paragraph 6.2, > > It doesn't specify any inner structure of the task management > > request or response, just a bunch of 8 DW each. > > I guess this is why it is defined as a

Re: [Patch v1 0/7] mpt3sas: Hot-Plug Surprise removal support on IOC.

2018-09-05 Thread Keith Busch
On Wed, Sep 05, 2018 at 09:38:16AM +0200, Lukas Wunner wrote: > On Wed, Sep 05, 2018 at 11:45:45AM +0530, Sreekanth Reddy wrote: > > On Tue, Sep 4, 2018 at 3:12 PM, Lukas Wunner wrote: > > > Many scsi drivers call pci_channel_offline() to detect inaccessibility > > > of the device due to a PCI

Re: [PATCH 1/5] qedf: fixup bit operations

2018-09-05 Thread Martin Wilck
On Wed, 2018-09-05 at 15:53 +0200, Hannes Reinecke wrote: > test_bit() is atomic, test_bit() || test_bit() is not. > So protect consecutive bit tests with a lock to avoid races. > > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/qedf/qedf_els.c | 9 +++-- >

[PATCH 4/5] qedf: remove stale variables in qedf_eh_XXX functions

2018-09-05 Thread Hannes Reinecke
Signed-off-by: Hannes Reinecke --- drivers/scsi/qedf/qedf_main.c | 11 --- 1 file changed, 11 deletions(-) diff --git a/drivers/scsi/qedf/qedf_main.c b/drivers/scsi/qedf/qedf_main.c index 3407a05e898b..2bedad13f3f4 100644 --- a/drivers/scsi/qedf/qedf_main.c +++

[PATCH 0/5] qedf: fixup NULL pointer reference in fc_lookup_rport()

2018-09-05 Thread Hannes Reinecke
Hi all, occasionally the qedf driver will crash in fc_lookup_rport() due to missing locking and incorrect reference counting of the fc_rport_priv() structure from libfc. This patchset fixes up the reference counting and ensures that the locking rules of libfc are followed. As usual, comments and

[PATCH 3/5] qedf: missing kref_put in qedf_xmit()

2018-09-05 Thread Hannes Reinecke
qedf_xmit() calls fc_rport_lookup(), but discards the returned rdata structure almost immediately without decreasing the refcount. This leads to a refcount leak and the rdata never to be freed. Signed-off-by: Hannes Reinecke --- drivers/scsi/qedf/qedf_main.c | 4 +++- 1 file changed, 3

[PATCH 5/5] qedf: fc_rport_priv reference counting fixes

2018-09-05 Thread Hannes Reinecke
The fc_rport_priv structure is reference counted, so we need to ensure that the reference is increased before accessing the structure. Signed-off-by: Hannes Reinecke --- drivers/scsi/qedf/qedf_els.c | 12 ++-- drivers/scsi/qedf/qedf_io.c | 32 ++--

[PATCH 1/5] qedf: fixup bit operations

2018-09-05 Thread Hannes Reinecke
test_bit() is atomic, test_bit() || test_bit() is not. So protect consecutive bit tests with a lock to avoid races. Signed-off-by: Hannes Reinecke --- drivers/scsi/qedf/qedf_els.c | 9 +++-- drivers/scsi/qedf/qedf_main.c | 5 - 2 files changed, 11 insertions(+), 3 deletions(-) diff

[PATCH 2/5] qedf: fixup locking in qedf_restart_rport()

2018-09-05 Thread Hannes Reinecke
fc_rport_create() needs to be called with disc_mutex held. And we should re-assign the 'rdata' pointer in case it got changed. Signed-off-by: Hannes Reinecke --- drivers/scsi/qedf/qedf_els.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/scsi/qedf/qedf_els.c

Re: [PATCH v3 3/7] scsi: ufs: Add fill task management request

2018-09-05 Thread Christoph Hellwig
On Wed, Sep 05, 2018 at 07:30:03AM +, Avri Altman wrote: > Looking into the UFSHCI spec (JESD223C March 2016) paragraph 6.2, > It doesn't specify any inner structure of the task management > request or response, just a bunch of 8 DW each. > I guess this is why it is defined as a __le32 array.

Re: [PATCH 4/4] pm80xx : Update driver version to 0.1.39

2018-09-05 Thread Jinpu Wang
On Wed, Sep 5, 2018 at 7:47 AM Viswas G wrote: > > From: Deepak Ukey > > Updated the driver version from 0.1.38 to 0.1.39. > > Signed-off-by: Deepak Ukey > Signed-off-by: Viswas G > --- > drivers/scsi/pm8001/pm8001_sas.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git

Re: [PATCH 3/4] pm80xx : Fixed system hang issue during kexec boot.

2018-09-05 Thread Jinpu Wang
On Wed, Sep 5, 2018 at 7:47 AM Viswas G wrote: > > From: Deepak Ukey > > When the firmware is not responding, execution of kexec boot > causes a system hang. When firmware assertion happened, driver > get notified with interrupt vector updated in MPI configuration > table. Then, the driver will

RE: [PATCH v3 4/7] scsi: ufs: Allow ufshcd_issue_tm_cmd accept raw task upius

2018-09-05 Thread Avri Altman
> > --- > > drivers/scsi/ufs/ufshcd.c | 35 ++- > > 1 file changed, 26 insertions(+), 9 deletions(-) > > > > diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c > > index d18832a..15be103 100644 > > --- a/drivers/scsi/ufs/ufshcd.c > > +++

Re: [PATCH 2/4] pm80xx : Corrected dma_unmap_sg() parameter.

2018-09-05 Thread Jinpu Wang
On Wed, Sep 5, 2018 at 7:47 AM Viswas G wrote: > > From: Deepak Ukey > > For the function dma_unmap_sg(), the parameter should be > number of elements in the scatter list prior to the mapping, not > after the mapping. > > Signed-off-by: Deepak Ukey > Signed-off-by: Viswas G > --- >

Re: [PATCH 1/4] pm80xx : Fix for phy enable/disable functionality.

2018-09-05 Thread Jinpu Wang
On Wed, Sep 5, 2018 at 7:47 AM Viswas G wrote: > > From: Deepak Ukey > > Added proper mask for phy id in mpi_phy_stop_resp(). > > Signed-off-by: Deepak Ukey > Signed-off-by: Viswas G > --- > drivers/scsi/pm8001/pm8001_defs.h | 7 +++ > drivers/scsi/pm8001/pm8001_hwi.c | 4 ++-- >

Re: [Patch v1 0/7] mpt3sas: Hot-Plug Surprise removal support on IOC.

2018-09-05 Thread Lukas Wunner
On Wed, Sep 05, 2018 at 11:45:45AM +0530, Sreekanth Reddy wrote: > On Tue, Sep 4, 2018 at 3:12 PM, Lukas Wunner wrote: > > Many scsi drivers call pci_channel_offline() to detect inaccessibility > > of the device due to a PCI error: > >

RE: [PATCH v3 3/7] scsi: ufs: Add fill task management request

2018-09-05 Thread Avri Altman
> -Original Message- > From: linux-scsi-ow...@vger.kernel.org > On Behalf Of Christoph Hellwig > Sent: Tuesday, September 04, 2018 10:12 PM > To: Avri Altman > Cc: Christoph Hellwig ; Johannes Thumshirn > ; Hannes Reinecke ; Bart Van Assche > ; James E.J. Bottomley > ; Martin K.

RE: [PATCH v3 1/7] scsi: ufs: Add ufs-bsg module

2018-09-05 Thread Avri Altman
> > + */ > > +#ifndef SCSI_BSG_UFS_H > > +#define SCSI_BSG_UFS_H > > + > > +/* > > + * This file intended to be included by both kernel and user space > > + */ > > + > > + > > +/** > > + * struct ufs_bsg_upiu - upiu transaction structure > > + * > > + * @header: upiu header > > + * @tsf:

Re: [Patch v1 0/7] mpt3sas: Hot-Plug Surprise removal support on IOC.

2018-09-05 Thread Sreekanth Reddy
l On Tue, Sep 4, 2018 at 3:12 PM, Lukas Wunner wrote: > On Tue, Sep 04, 2018 at 11:19:04AM +0530, Sreekanth Reddy wrote: >> On Fri, Aug 31, 2018 at 2:25 PM, Lukas Wunner wrote: >> > * Just reading the vendor ID may not be sufficient to detect unplug, >> > it may also read as "all ones" if

RE: [PATCH v3 1/7] scsi: ufs: Add ufs-bsg module

2018-09-05 Thread Avri Altman
> -Original Message- > From: Christoph Hellwig > Sent: Tuesday, September 04, 2018 10:20 PM > To: Avri Altman > Cc: Christoph Hellwig ; Johannes Thumshirn > ; Hannes Reinecke ; Bart Van Assche > ; James E.J. Bottomley > ; Martin K. Petersen > ; linux-scsi@vger.kernel.org; Stanislav

RE: [PATCH v3 2/7] scsi: ufs: Instantiate a ufs bsg if its available

2018-09-05 Thread Avri Altman
> -Original Message- > From: Christoph Hellwig > Sent: Tuesday, September 04, 2018 10:16 PM > To: Avri Altman > Cc: Christoph Hellwig ; Johannes Thumshirn > ; Hannes Reinecke ; Bart Van Assche > ; James E.J. Bottomley > ; Martin K. Petersen > ; linux-scsi@vger.kernel.org; Stanislav