[PATCH] target: Fix virtual LUN=0 target_configure_device failure OOPs

2015-03-04 Thread Nicholas A. Bellinger
From: Nicholas Bellinger This patch fixes a NULL pointer dereference triggered by a late target_configure_device() -> alloc_workqueue() failure that results in target_free_device() being called with DF_CONFIGURED already set, which subsequently OOPses in destroy_workqueue() code. Currently this

Re: noise in target_core_register_fabric

2015-03-04 Thread Nicholas A. Bellinger
On Wed, 2015-03-04 at 16:46 +0100, Olaf Hering wrote: > Is there a need to fill dmesg with noise like shown below whenever > targetcli-3.0 runs a command? I think the pr_err calls in those functions > should be converted to pr_debug. > Fair enough. Care to send out a patch for this..? ;) --nab

Re: crash in pscsi_get_device_type

2015-03-04 Thread Nicholas A. Bellinger
On Wed, 2015-03-04 at 16:00 +0100, Olaf Hering wrote: > On Fri, Feb 27, Nicholas A. Bellinger wrote: > > > On Thu, 2015-02-26 at 10:26 +0100, Olaf Hering wrote: > > > > [ 145.661468] IP: [] pscsi_get_device_type+0xb/0x20 > > > [target_core_pscsi] > > Looks like a PSCSI specific NULL pointer der

RE: [libsas] Kernel Crash in smp_execute_task

2015-03-04 Thread Praveen Murali
> -Original Message- > From: James Bottomley [mailto:james.bottom...@hansenpartnership.com] > Sent: Wednesday, March 04, 2015 5:05 PM > To: Praveen Murali > Cc: linux-scsi@vger.kernel.org; dan.j.willi...@intel.com > Subject: Re: [libsas] Kernel Crash in smp_execute_task > > On Thu, 2015-03

Re: [libsas] Kernel Crash in smp_execute_task

2015-03-04 Thread James Bottomley
On Thu, 2015-03-05 at 00:44 +, Praveen Murali wrote: > > From: James Bottomley > Sent: Wednesday, March 4, 2015 4:18 PM > To: Praveen Murali > Cc: linux-scsi@vger.kernel.org; dan.j.willi...@intel.com > Subject: Re: [libsas] Kernel Crash in smp_execute_t

RE: [libsas] Kernel Crash in smp_execute_task

2015-03-04 Thread Praveen Murali
> -Original Message- > From: Douglas Gilbert [mailto:dgilb...@interlog.com] > Sent: Wednesday, March 04, 2015 4:00 PM > To: Praveen Murali; linux-scsi@vger.kernel.org; dan.j.willi...@intel.com > Cc: jbottom...@parallels.com > Subject: Re: [libsas] Kernel Crash in smp_execute_task > > On 15

RE: [libsas] Kernel Crash in smp_execute_task

2015-03-04 Thread Praveen Murali
From: James Bottomley Sent: Wednesday, March 4, 2015 4:18 PM To: Praveen Murali Cc: linux-scsi@vger.kernel.org; dan.j.willi...@intel.com Subject: Re: [libsas] Kernel Crash in smp_execute_task On Wed, 2015-03-04 at 23:29 +, Praveen Murali wrote: >> On s

Re: [libsas] Kernel Crash in smp_execute_task

2015-03-04 Thread James Bottomley
On Wed, 2015-03-04 at 23:29 +, Praveen Murali wrote: > On second thoughts, should we even let smp commands/requests thru for > sas end devices (dev->dev_type == SAS_END_DEV) ? if so, wont the > following patch more sense? (also, in my last mail the kernel logs > were all messed up; sorry dint r

Re: [libsas] Kernel Crash in smp_execute_task

2015-03-04 Thread Douglas Gilbert
On 15-03-04 06:29 PM, Praveen Murali wrote: On second thoughts, should we even let smp commands/requests thru for sas end devices (dev->dev_type == SAS_END_DEV) ? if so, wont the following patch more sense? (also, in my last mail the kernel logs were all messed up; sorry dint realize that when

RE: [libsas] Kernel Crash in smp_execute_task

2015-03-04 Thread Praveen Murali
On second thoughts, should we even let smp commands/requests thru for sas end devices (dev->dev_type == SAS_END_DEV) ? if so, wont the following patch more sense? (also, in my last mail the kernel logs were all messed up; sorry dint realize that when I sent the mail. Trying to fix it here) diff

[libsas] Kernel Crash in smp_execute_task

2015-03-04 Thread Praveen Murali
Hi Dan, I am experiencing a crash in smp_execute_task when it calls mutex_lock with 15K SAS drives HP Model EH0146FAWJB (Seagate model ST9146852SS) connected to a Marvell 88SE9485 SAS/SATA 6Gb/s controller; kernel version is 3.4.87. The crash happens as soon as I connect this drive; crash dump

Re: [PATCH v2] xen-scsiback: use DRV_PFX in the pr macros and DPRINTK

2015-03-04 Thread Joe Perches
On Wed, 2015-03-04 at 18:32 +, Tao Chen wrote: > Defined the string of {xen-pvscsi: } as DRV_PFX, then use it in the pr > sentences and DPRINTK. > Also fixed up some comments just as eliminate redundant white spaces and > format the code. > These will make the code easier to read. It'd proba

[PATCH v2] IB/srp: Add 64-bit LUN support

2015-03-04 Thread Bart Van Assche
The SCSI standard defines 64-bit values for LUNs. Large arrays employing large or hierarchical LUN numbers become more and more common. So update the SRP initiator to use 64-bit LUN numbers. See also Hannes Reinecke, commit 9cb78c16f5da ("scsi: use 64-bit LUNs"), June 2014. The largest LUN number

Re: [PATCH, resend] IB/srp: Add 64-bit LUN support

2015-03-04 Thread Bart Van Assche
On 03/04/15 14:16, Yann Droneaud wrote: > Le mercredi 04 mars 2015 à 11:01 +0100, Bart Van Assche a écrit : >> diff --git a/drivers/infiniband/ulp/srp/ib_srp.c >> b/drivers/infiniband/ulp/srp/ib_srp.c >> index a0e24a8..e427454 100644 >> --- a/drivers/infiniband/ulp/srp/ib_srp.c >> +++ b/drivers/in

noise in target_core_register_fabric

2015-03-04 Thread Olaf Hering
Is there a need to fill dmesg with noise like shown below whenever targetcli-3.0 runs a command? I think the pr_err calls in those functions should be converted to pr_debug. Olaf . [ 1240.045518] target_core_register_fabric() trying autoload for fc [ 1240.045520] target_core_get_fabric() fail

Re: crash in pscsi_get_device_type

2015-03-04 Thread Olaf Hering
On Fri, Feb 27, Nicholas A. Bellinger wrote: > On Thu, 2015-02-26 at 10:26 +0100, Olaf Hering wrote: > > [ 145.661468] IP: [] pscsi_get_device_type+0xb/0x20 > > [target_core_pscsi] > Looks like a PSCSI specific NULL pointer dereference when reading the > dev_type attribute if a backend device w

[PATCH 2/2] bnx2fc: bnx2fc_io.c: match wait_for_completion_timeout return type

2015-03-04 Thread Nicholas Mc Guire
, CONFIG_LIBFC=m, CONFIG_LIBFCOE=m, CONFIG_SCSI_BNX2X_FCOE=m Patch is against 4.0-rc2 (localversion-next is -next-20150304) drivers/scsi/bnx2fc/bnx2fc_io.c |9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/drivers/scsi/bnx2fc/bnx2fc_io.c b/drivers/scsi/bnx2fc/bnx2fc_io.c

[PATCH 2/2] bnx2fc: bnx2fc_io.c: match wait_for_completion_timeout return type

2015-03-04 Thread Nicholas Mc Guire
, CONFIG_LIBFC=m, CONFIG_LIBFCOE=m, CONFIG_SCSI_BNX2X_FCOE=m Patch is against 4.0-rc2 (localversion-next is -next-20150304) drivers/scsi/bnx2fc/bnx2fc_io.c |9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/drivers/scsi/bnx2fc/bnx2fc_io.c b/drivers/scsi/bnx2fc/bnx2fc_io.c

[PATCH 1/2] bnx2fc: bnx2fc_fcoe.c: match wait_for_completion_timeout return type

2015-03-04 Thread Nicholas Mc Guire
, CONFIG_LIBFC=m, CONFIG_LIBFCOE=m, CONFIG_SCSI_BNX2X_FCOE=m Patch is against 4.0-rc2 (localversion-next is -next-20150304) drivers/scsi/bnx2fc/bnx2fc_fcoe.c |6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/scsi/bnx2fc/bnx2fc_fcoe.c b/drivers/scsi/bnx2fc/bnx2fc_fcoe.c

Re: [PATCH v4 4/4] scsi: ufs: inject errors to verify error handling

2015-03-04 Thread Akinobu Mita
2015-03-02 23:56 GMT+09:00 Gilad Broner : > From: Sujit Reddy Thumma > > Use fault-injection framework to simulate error conditions > in the controller and verify error handling mechanisms > implemented in UFS host controller driver. > > This is used only during development and hence > guarded by

Re: [PATCH, resend] IB/srp: Add 64-bit LUN support

2015-03-04 Thread Yann Droneaud
Hi, Le mercredi 04 mars 2015 à 11:01 +0100, Bart Van Assche a écrit : > The SCSI standard defines 64-bit values for LUNs. Large arrays > employing large or hierarchical LUN numbers become more and more > common. So update the SRP initiator to use 64-bit LUN numbers. > See also Hannes Reinecke, com

[PATCH] drivers: scsi: ufs: Fix possible null derefrence

2015-03-04 Thread Tapasweni Pathak
Check for null before being dereferenced to avoid a invalid null dereference. Found using Coccinelle. Signed-off-by: Tapasweni Pathak Acked-by: Julia Lawall --- drivers/scsi/ufs/ufshcd.c |7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/ufs/ufshcd.c b/d

Re: [PATCH, resend] IB/srp: Add 64-bit LUN support

2015-03-04 Thread Sagi Grimberg
On 3/4/2015 12:01 PM, Bart Van Assche wrote: The SCSI standard defines 64-bit values for LUNs. Large arrays employing large or hierarchical LUN numbers become more and more common. So update the SRP initiator to use 64-bit LUN numbers. See also Hannes Reinecke, commit 9cb78c16f5da ("scsi: use 64-

Re: [PATCH] xen-scsiback: use DRV_PFX in the pr macros

2015-03-04 Thread Chentao (Boby)
Hi, Juergen. Thanks for your advice. I will send a v2 patch based on your suggested modifications. On 2015/3/3 17:52, Juergen Gross wrote: On 03/03/2015 09:37 AM, Tao Chen wrote: Replace the string of {xen-pvscsi:} in the pr sentences with DRV_PFX, it makes the code easier to read. I'm not

Re: [PATCH v2] xen-scsiback: use DRV_PFX in the pr macros and DPRINTK

2015-03-04 Thread David Vrabel
On 04/03/15 18:32, Tao Chen wrote: > Defined the string of {xen-pvscsi: } as DRV_PFX, then use it in the pr > sentences and DPRINTK. > Also fixed up some comments just as eliminate redundant white spaces and > format the code. > These will make the code easier to read. I have already said you ne

[PATCH v2] xen-scsiback: use DRV_PFX in the pr macros and DPRINTK

2015-03-04 Thread Tao Chen
Defined the string of {xen-pvscsi: } as DRV_PFX, then use it in the pr sentences and DPRINTK. Also fixed up some comments just as eliminate redundant white spaces and format the code. These will make the code easier to read. Signed-off-by: Tao Chen --- drivers/xen/xen-scsiback.c | 70 +

Re: [Lsf-pc] [LSF/MM TOPIC] Unifying the LIO and SCST target drivers

2015-03-04 Thread Bart Van Assche
On 03/02/15 07:59, Nicholas A. Bellinger wrote: > On Sat, 2015-02-28 at 12:59 +0100, Bart Van Assche wrote: >> On 02/27/15 22:58, Nicholas A. Bellinger wrote: >>> Looking at how your attempting to drive creation + removal of struct >>> config_group from within kernel code here: >>> >>> target: Add

[PATCH] ibmvfc: Fix a locking imbalance

2015-03-04 Thread Bart Van Assche
Avoid that the spin_lock() statement after kref_put() triggers a lockup if rport != NULL && get_device() == 0. Detected by sparse. Compile-tested only. Signed-off-by: Bart Van Assche Cc: Brian King Cc: Nathan Fontenot Cc: Tyrel Datwyler --- drivers/scsi/ibmvscsi/ibmvfc.c | 2 ++ 1 file change

[PATCH, resend] IB/srp: Add 64-bit LUN support

2015-03-04 Thread Bart Van Assche
The SCSI standard defines 64-bit values for LUNs. Large arrays employing large or hierarchical LUN numbers become more and more common. So update the SRP initiator to use 64-bit LUN numbers. See also Hannes Reinecke, commit 9cb78c16f5da ("scsi: use 64-bit LUNs"), June 2014. The largest LUN number

[PATCH, resend] Defer processing of REQ_PREEMPT requests for blocked devices

2015-03-04 Thread Bart Van Assche
SCSI transport drivers and SCSI LLDs block a SCSI device if the transport layer is not operational. This means that in this state no requests should be processed, even if the REQ_PREEMPT flag has been set. This patch avoids that a rescan shortly after a cable pull sporadically triggers the followin

[PATCH 6/7] aacraid: performance improvement changes

2015-03-04 Thread Mahesh Rajashekhara
Add performance improvement changes. Signed-off-by: Mahesh Rajashekhara --- drivers/scsi/aacraid/aacraid.h |6 +++--- drivers/scsi/aacraid/comminit.c | 12 +++- drivers/scsi/aacraid/commsup.c |7 ++- drivers/scsi/aacraid/dpcsup.c |4 ++-- drivers/scsi/aacraid/linit.

[PATCH 5/7] aacraid: vpd page code 0x83 support

2015-03-04 Thread Mahesh Rajashekhara
Add vpd page code 0x83 support Signed-off-by: Mahesh Rajashekhara --- drivers/scsi/aacraid/aachba.c | 154 --- drivers/scsi/aacraid/aacraid.h |4 + drivers/scsi/aacraid/comminit.c |8 ++- drivers/scsi/aacraid/commsup.c | 12 +--- drivers/scsi/aa

[PATCH 3/7] aacraid: 4KB sector support

2015-03-04 Thread Mahesh Rajashekhara
Add 4KB sector support Signed-off-by: Mahesh Rajashekhara --- drivers/scsi/aacraid/aachba.c | 195 +++- drivers/scsi/aacraid/aacraid.h | 10 ++- 2 files changed, 160 insertions(+), 45 deletions(-) diff --git a/drivers/scsi/aacraid/aachba.c b/drivers/scsi/

[PATCH 4/7] aacraid: MSI-x support

2015-03-04 Thread Mahesh Rajashekhara
Add MSI-x interrupt mode support. Signed-off-by: Mahesh Rajashekhara --- drivers/scsi/aacraid/aachba.c |6 +- drivers/scsi/aacraid/aacraid.h | 79 - drivers/scsi/aacraid/comminit.c | 86 +- drivers/scsi/aacraid/commsup.c | 19 ++- drivers/scsi/aacraid/dpcsup.c |

[PATCH 7/7] aacraid: AIF raw device remove support

2015-03-04 Thread Mahesh Rajashekhara
Add AIF raw device remove support Signed-off-by: Mahesh Rajashekhara --- drivers/scsi/aacraid/aacraid.h |3 +++ drivers/scsi/aacraid/commsup.c | 32 2 files changed, 35 insertions(+), 0 deletions(-) diff --git a/drivers/scsi/aacraid/aacraid.h b/drivers/scs

[PATCH 1/7] aacraid: AIF support for SES device add/remove

2015-03-04 Thread Mahesh Rajashekhara
Add new AIF support for SES device add/remove Signed-off-by: Mahesh Rajashekhara --- drivers/scsi/aacraid/aacraid.h |2 ++ drivers/scsi/aacraid/commsup.c |8 ++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/aacraid/aacraid.h b/drivers/scsi/aacraid/aacr

[PATCH 0/7] aacraid driver updates

2015-03-04 Thread Mahesh Rajashekhara
This patch set includes some important bug fixes and new feature supports. Mahesh Rajashekhara (7): aacraid: AIF support for SES device add/remove aacraid: IOCTL pass-through command fix aacraid: 4KB sector support aacraid: MSI-x support aacraid: vpd page code 0x83 support aacraid: per

[PATCH 2/7] aacraid: IOCTL pass-through command fix

2015-03-04 Thread Mahesh Rajashekhara
The Linux aacriad driver fails to detect the case of SG list count=0 on IOCTL pass-through command and cause intermittent fault. The result is the Linux aacriad driver send down IOCTL pass-through command with one not initialized SG list to firmware when receiving SG list count =0 on pass-throug