[iscsiadm] iscsiadm creates multiple same sessions when run with --login option in parallel.

2017-09-27 Thread Tangchen (UVP)
Hi guys, If we run iscsiadm -m node --login command through the same IP address 4 times, only one session will be created. But if we run them in parallel, then 4 same sessions could be created. ( Here, xxx.xxx.xxx.xxx is the IP address to the IPSAN. I'm using the same IP in these 4 commands. )

Re: [PATCH] scsi: ILLEGAL REQUEST + ASC==27 => target failure

2017-09-27 Thread Martin K. Petersen
Martin, > ASC 0x27 is "WRITE PROTECTED". This error code is returned e.g. by > Fujitsu ETERNUS systems under certain conditions for WRITE SAME 16 > commands with UNMAP bit set. It should not be treated as a path > error. In general, it makes sense to assume that being write protected > is a targ

Re: [PATCH] scsi: libsas: remove unused variable sas_ha

2017-09-27 Thread Martin K. Petersen
Colin, > Remove unused variable sas_ha to clean up build warning > "unused variable ‘sas_ha’ [-Wunused-variable]" Applied to 4.15/scsi-queue. Thanks! -- Martin K. Petersen Oracle Linux Engineering

Re: [PATCH] scsi: ufs: fix wrong command type of UTRD for UFSHCI v2.1

2017-09-27 Thread Martin K. Petersen
kehuanlin, > Since the command type of UTRD in UFS 2.1 specification is the same with > UFS 2.0. And it assumes the future UFS specification will follow the same > definition. Applied to 4.15/scsi-queue. Thanks! -- Martin K. Petersen Oracle Linux Engineering

Re: [PATCH] scsi: ufs: continue to boot even with Boot LUN is disabled

2017-09-27 Thread Martin K. Petersen
Huanlin, > Several configurable fields of the Device Descriptor and the Unit > Descriptors determine the Boot LUN status. The bBootEnable field and > the bBootLunEn attribute is set to zero by default, so the Boot LUN is > disabled by default. > > At which point the scsi device add for Boot LUN w

Re: [PATCH] scsi: ufs: add ufs a command complete time stamp

2017-09-27 Thread Martin K. Petersen
Zang, Applied to 4.15/scsi-queue. Thank you! -- Martin K. Petersen Oracle Linux Engineering

Re: [PATCH] scsi: aacraid: Add a small delay after IOP reset

2017-09-27 Thread Martin K. Petersen
Dave, >> > Previously we had used sleep to delay until the controller got its > mind back, but early testing indicated it wasn't needed. I'm good with > this. Applied to 4.14/scsi-fixes. Thanks! -- Martin K. Petersen Oracle Linux Engineering

Re: [PATCH] scsi: ufs: fix a pclint warning

2017-09-27 Thread Martin K. Petersen
Zang, Applied to 4.15/scsi-queue. Thank you! -- Martin K. Petersen Oracle Linux Engineering

[PATCH] scsi: sd: Do not override max_sectors_kb sysfs setting

2017-09-27 Thread Martin K. Petersen
A user may lower the max_sectors_kb setting in sysfs to accommodate certain workloads. Previously we would always set the max I/O size to either the block layer default or the optional preferred I/O size reported by the device. Keep the current heuristics for the initial setting of max_sectors_kb.

Re: [PATCH] sd: preserve sysfs updates to max_sectors_kb

2017-09-27 Thread Martin K. Petersen
Martin, > Could you please explain why you think Don's patch is wrong? User > settings being discarded because of a BLKRRPART ioctl violates the > principle of least surprise. With Don's patch, that won't happen any > more. If hardware limits change, whether they increase or decrease, the > patch

[PATCH] scsi: sd: Implement blacklist option for WRITE SAME w/ UNMAP

2017-09-27 Thread Martin K. Petersen
SBC-4 states: "A MAXIMUM UNMAP LBA COUNT field set to a non-zero value indicates the maximum number of LBAs that may be unmapped by an UNMAP command" "A MAXIMUM WRITE SAME LENGTH field set to a non-zero value indicates the maximum number of contiguous logical blocks that the device serv

Re: [PATCH] sd: Limit WRITE SAME / WRITE SAME(16) w/UNMAP length for certain devices

2017-09-27 Thread Martin K. Petersen
Ewan, >> The spec is crystal clear. The device needs to be fixed. We can >> blacklist older firmware revs. > > Yes, I know that is what SBC-4 says, and I agree that the devices > are not conforming. Unfortunately, I've come across 3 different > arrays now from 3 different manufacturers that exhi

Re: [PATCH] scsi: ufs: add ufs a command complete time stamp

2017-09-27 Thread Subhash Jadavani
On 2017-09-26 19:06, Zang Leigang wrote: Signed-off-by: Zang Leigang diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c index 794a460..7e8d583 100644 --- a/drivers/scsi/ufs/ufshcd.c +++ b/drivers/scsi/ufs/ufshcd.c @@ -385,6 +385,8 @@ void ufshcd_print_trs(struct ufs_hba *hba, un

[PATCH 3/3] smartpqi: update driver version to 1.1.2-126

2017-09-27 Thread Don Brace
Reviewed-by: Gerry Morong Reviewed-by: Scott Benesh Reviewed-by: Scott Teel Signed-off-by: Kevin Barnett Signed-off-by: Don Brace --- drivers/scsi/smartpqi/smartpqi_init.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/smartpqi/smartpqi_init.c b/drive

[PATCH 2/3] smartpqi: cleanup raid map warning message

2017-09-27 Thread Don Brace
From: Kevin Barnett Fix a small cosmetic bug in a very rarely encountered error message that can occur when a LD has a corrupted raid map. Reviewed-by: Scott Benesh Signed-off-by: Kevin Barnett Signed-off-by: Don Brace --- drivers/scsi/smartpqi/smartpqi_init.c |6 +++--- 1 file changed,

[PATCH 1/3] smartpqi: update controller ids

2017-09-27 Thread Don Brace
From: Kevin Barnett Update the driver’s PCI IDs Reviewed-by: Scott Benesh Reviewed-by: Scott Teel Signed-off-by: Kevin Barnett Signed-off-by: Don Brace --- drivers/scsi/smartpqi/smartpqi_init.c |8 1 file changed, 8 insertions(+) diff --git a/drivers/scsi/smartpqi/smartpqi_ini

[PATCH 0/3] smartpqi updates

2017-09-27 Thread Don Brace
These patches are based on Linus's tree The changes are: - update list of controllers - cleanup warning message - change driver version to 1.1.2-126 --- Don Brace (1): smartpqi: update driver version to 1.1.2-126 Kevin Barnett (2): smartpqi: update controller ids smartpqi: c

RE: [PATCH] scsi: aacraid: Add a small delay after IOP reset

2017-09-27 Thread Dave Carroll
> > > Guilherme, > > > James/Martin, am I expected to send a v2 with some change? Perhaps > > with Dave's ack? Sorry to annoy, thanks in advance for any advice! > > I was just about to mail Dave and ask for confirmation that your > interpretation > of the controller behavior is correct. > >

[PATCH] scsi: sd: add check for changing allow_restart

2017-09-27 Thread weiping zhang
/sys/class/scsi_disk/0:2:0:0/allow_restart can be changed to 0 unexpectly by writing invalid string, like following: echo asdf > /sys/class/scsi_disk/0:2:0:0/allow_restart Signed-off-by: weiping zhang --- drivers/scsi/sd.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git

RE: [PATCH] sd: Limit WRITE SAME / WRITE SAME(16) w/UNMAP length for certain devices

2017-09-27 Thread Knight, Frederick
I agree that it is disappointing that so many vendors seem to have trouble reading the spec. This case is pretty clear. The best the T10 committee could do is add a bit to indicate that the device uses the length from MAXIMUM UNMAP LBA COUNT field for the length of unmaps via the WRITE SAME w/

Re: [PATCH] sd: Limit WRITE SAME / WRITE SAME(16) w/UNMAP length for certain devices

2017-09-27 Thread Ewan D. Milne
On Mon, 2017-09-25 at 21:46 -0400, Martin K. Petersen wrote: > Ewan, > > > Some devices do not support a WRITE SAME / WRITE SAME(16) with the > > UNMAP bit set up to the length specified in the MAXIMUM WRITE SAME > > LENGTH field in the block limits VPD page (or, the field is zero, > > indicating

Re: [PATCH] scsi: ILLEGAL REQUEST + ASC==27 => target failure

2017-09-27 Thread Lee Duncan
On 09/27/2017 05:44 AM, Martin Wilck wrote: > ASC 0x27 is "WRITE PROTECTED". This error code is returned e.g. > by Fujitsu ETERNUS systems under certain conditions for > WRITE SAME 16 commands with UNMAP bit set. It should not be > treated as a path error. In general, it makes sense to assume > tha

Re: [PATCH] scsi: ioctl reset should wait for IOs to complete

2017-09-27 Thread Lee Duncan
On 09/26/2017 11:58 PM, Hannes Reinecke wrote: > On 09/26/2017 08:24 PM, Bart Van Assche wrote: >> On Tue, 2017-09-26 at 10:22 -0700, Lee Duncan wrote: >>> The SCSI ioctl reset path is smart enough to set the >>> flag tmf_in_progress when a user-requested reset is >>> processed, but it does not wai

[PATCH] scsi: ILLEGAL REQUEST + ASC==27 => target failure

2017-09-27 Thread Martin Wilck
ASC 0x27 is "WRITE PROTECTED". This error code is returned e.g. by Fujitsu ETERNUS systems under certain conditions for WRITE SAME 16 commands with UNMAP bit set. It should not be treated as a path error. In general, it makes sense to assume that being write protected is a target rather than a path

Re: [PATCH V6 6/6] SCSI: set block queue at preempt only when SCSI device is put into quiesce

2017-09-27 Thread Ming Lei
On Wed, Sep 27, 2017 at 09:54:09AM +, Bart Van Assche wrote: > On Wed, 2017-09-27 at 13:48 +0800, Ming Lei wrote: > > @@ -2928,12 +2929,28 @@ scsi_device_quiesce(struct scsi_device *sdev) > > { > > int err; > > > > + /* > > +* Simply quiesing SCSI device isn't safe, it is easy > >

Re: [PATCH V6 6/6] SCSI: set block queue at preempt only when SCSI device is put into quiesce

2017-09-27 Thread Bart Van Assche
On Wed, 2017-09-27 at 13:48 +0800, Ming Lei wrote: > @@ -2928,12 +2929,28 @@ scsi_device_quiesce(struct scsi_device *sdev) > { > int err; > > + /* > + * Simply quiesing SCSI device isn't safe, it is easy > + * to use up requests because all these allocated requests > + *

Re: [PATCH V6 0/6] block/scsi: safe SCSI quiescing

2017-09-27 Thread Ming Lei
On Wed, Sep 27, 2017 at 04:27:51PM +0800, Ming Lei wrote: > On Wed, Sep 27, 2017 at 09:57:37AM +0200, Martin Steigerwald wrote: > > Hi Ming. > > > > Ming Lei - 27.09.17, 13:48: > > > Hi, > > > > > > The current SCSI quiesce isn't safe and easy to trigger I/O deadlock. > > > > > > Once SCSI devic

Re: [PATCH V6 0/6] block/scsi: safe SCSI quiescing

2017-09-27 Thread Ming Lei
On Wed, Sep 27, 2017 at 09:57:37AM +0200, Martin Steigerwald wrote: > Hi Ming. > > Ming Lei - 27.09.17, 13:48: > > Hi, > > > > The current SCSI quiesce isn't safe and easy to trigger I/O deadlock. > > > > Once SCSI device is put into QUIESCE, no new request except for > > RQF_PREEMPT can be disp

Re: [PATCH V6 0/6] block/scsi: safe SCSI quiescing

2017-09-27 Thread Martin Steigerwald
Hi Ming. Ming Lei - 27.09.17, 13:48: > Hi, > > The current SCSI quiesce isn't safe and easy to trigger I/O deadlock. > > Once SCSI device is put into QUIESCE, no new request except for > RQF_PREEMPT can be dispatched to SCSI successfully, and > scsi_device_quiesce() just simply waits for complet

mptsas driver cannot detect hotplugging disk with the LSI SCSI SAS1068 controller in Ubuntu guest on VMware

2017-09-27 Thread Gavin Guo
There is a problem in the latest upstream kernel with the device: $ grep -i lsi lspci 03:00.0 Serial Attached SCSI controller [0107]: LSI Logic / Symbios Logic SAS1068 PCI-X Fusion-MPT SAS [1000:0054] (rev 01) The device is simulated by the VMware ESXi 5.5 When hotplugging a new disk to the Gues