Re: [PATCH 3/3] Make blk_cleanup_queue() wait until request_fn finished

2012-10-02 Thread Bart Van Assche
On 10/01/12 19:41, Dan Williams wrote: On Thu, Sep 27, 2012 at 9:39 AM, Bart Van Assche bvanass...@acm.org wrote: [ ... ] diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c index 593fc71..03571a3 100644 --- a/drivers/scsi/scsi_lib.c +++ b/drivers/scsi/scsi_lib.c @@ -1517,10

[PATCH 0/4] target: Add target_submit_cmd_map_mem and convert tcm_loop+tcm_vhost

2012-10-02 Thread Nicholas A. Bellinger
From: Nicholas Bellinger n...@linux-iscsi.org Hi hch Co, This series adds a new target_submit_cmd_map_mem() caller to accept pre-allocated SGL memory within the core generic I/O submission path. Patch #1 contains the core I/O changes, patch #2 + #4 includes the conversion of tcm_loop+tcm_vhost

[PATCH 1/4] target: Add target_submit_cmd_map_mem for SGL fabric memory passthrough

2012-10-02 Thread Nicholas A. Bellinger
From: Nicholas Bellinger n...@linux-iscsi.org This patch adds a new TARGET_SCF_MAP_MEM flag within __target_submit_cmd() + a target_submit_cmd_map_mem() wrapper to pass pre-allocated SGL memory using existing transport_generic_map_mem_to_cmd() logic into the generic target submit I/O codepath.

[PATCH 3/4] target: Add TARGET_SCF_MAP_CLEAR_MEM work-around for tcm_loop

2012-10-02 Thread Nicholas A. Bellinger
From: Nicholas Bellinger n...@linux-iscsi.org This patch carries forward a work-around from tcm_loop to target core code to explicitly clear control CDB READ paylods in order to avoid bugs in scsi-generic user-space code for INQUIRY that do not explicitly zero CDB payload memory. Cc: Christoph

[PATCH 2/4] tcm_loop: Convert I/O path to use target_submit_cmd_map_mem

2012-10-02 Thread Nicholas A. Bellinger
From: Nicholas Bellinger n...@linux-iscsi.org This patch converts tcm_loop to use target_submit_cmd_map_mem() for I/O submission and mapping of pre-allocated SGL memory from incoming scsi_cmnd - se_cmd descriptors. This includes removing the original open-coded fabric uses of target core callers

[PATCH 4/4] tcm_vhost: Convert I/O path to use target_submit_cmd_map_mem

2012-10-02 Thread Nicholas A. Bellinger
From: Nicholas Bellinger n...@linux-iscsi.org This patch converts tcm_vhost to use target_submit_cmd_map_mem() for I/O submission and mapping of pre-allocated SGL memory from incoming virtio-scsi SGL memory - se_cmd descriptors. This includes removing the original open-coded fabric uses of

[PATCH v2] qla2xxx: silence two GCC warnings

2012-10-02 Thread Paul Bolle
Compiling qla_gs.o (part of the qla2xxx module) triggers two GCC warnings: drivers/scsi/qla2xxx/qla_gs.c: In function ‘qla2x00_fdmi_rhba’: drivers/scsi/qla2xxx/qla_gs.c:1339:7: warning: array subscript is above array bounds [-Warray-bounds] drivers/scsi/qla2xxx/qla_gs.c: In function

Re: [PATCH 0/2] virtio-scsi fixes for 3.6

2012-10-02 Thread James Bottomley
On Mon, 2012-10-01 at 15:11 +0200, Paolo Bonzini wrote: Il 26/07/2012 15:28, Paolo Bonzini ha scritto: James, patch 1 fixes scanning of LUNs whose number is greater than 255. QEMU passes a max_lun of 16383 (because it uses SAM numbering) but in Linux it must become 32768 (because LUNs

[patch] target/iscsi: precedence bug in iscsit_set_dataout_sequence_values()

2012-10-02 Thread Dan Carpenter
Clang warns about this bug: drivers/target/iscsi/iscsi_target_erl0.c:52:45: warning: operator '?:' has lower precedence than '+'; '+' will be evaluated first [-Wparentheses] Signed-off-by: Dan Carpenter dan.carpen...@oracle.com --- Please review this very carefully because I

Re: [PATCH 0/2] virtio-scsi fixes for 3.6

2012-10-02 Thread Paolo Bonzini
Il 02/10/2012 10:18, James Bottomley ha scritto: On Mon, 2012-10-01 at 15:11 +0200, Paolo Bonzini wrote: Il 26/07/2012 15:28, Paolo Bonzini ha scritto: James, patch 1 fixes scanning of LUNs whose number is greater than 255. QEMU passes a max_lun of 16383 (because it uses SAM numbering) but

Re: [patch] target/iscsi: precedence bug in iscsit_set_dataout_sequence_values()

2012-10-02 Thread walter harms
Am 02.10.2012 10:22, schrieb Dan Carpenter: Clang warns about this bug: drivers/target/iscsi/iscsi_target_erl0.c:52:45: warning: operator '?:' has lower precedence than '+'; '+' will be evaluated first [-Wparentheses] Signed-off-by: Dan Carpenter dan.carpen...@oracle.com ---

Re: [patch] target/iscsi: precedence bug in iscsit_set_dataout_sequence_values()

2012-10-02 Thread Dan Carpenter
On Tue, Oct 02, 2012 at 01:48:57PM +0200, walter harms wrote: Am 02.10.2012 10:22, schrieb Dan Carpenter: Clang warns about this bug: drivers/target/iscsi/iscsi_target_erl0.c:52:45: warning: operator '?:' has lower precedence than '+'; '+' will be evaluated first

Re: [PATCH 4/4] tcm_vhost: Convert I/O path to use target_submit_cmd_map_mem

2012-10-02 Thread Michael S. Tsirkin
On Tue, Oct 02, 2012 at 07:15:47AM +, Nicholas A. Bellinger wrote: From: Nicholas Bellinger n...@linux-iscsi.org This patch converts tcm_vhost to use target_submit_cmd_map_mem() for I/O submission and mapping of pre-allocated SGL memory from incoming virtio-scsi SGL memory - se_cmd

Re: [PATCH 0/4] target: Add target_submit_cmd_map_mem and convert tcm_loop+tcm_vhost

2012-10-02 Thread Michael S. Tsirkin
On Tue, Oct 02, 2012 at 07:15:43AM +, Nicholas A. Bellinger wrote: From: Nicholas Bellinger n...@linux-iscsi.org Hi hch Co, This series adds a new target_submit_cmd_map_mem() caller to accept pre-allocated SGL memory within the core generic I/O submission path. Patch #1 contains the

Re: [PATCH 1/4] target: Add target_submit_cmd_map_mem for SGL fabric memory passthrough

2012-10-02 Thread Christoph Hellwig
On Tue, Oct 02, 2012 at 07:15:44AM +, Nicholas A. Bellinger wrote: From: Nicholas Bellinger n...@linux-iscsi.org This patch adds a new TARGET_SCF_MAP_MEM flag within __target_submit_cmd() + a target_submit_cmd_map_mem() wrapper to pass pre-allocated SGL memory using existing

Re: [PATCH 2/4] tcm_loop: Convert I/O path to use target_submit_cmd_map_mem

2012-10-02 Thread Christoph Hellwig
On Tue, Oct 02, 2012 at 07:15:45AM +, Nicholas A. Bellinger wrote: From: Nicholas Bellinger n...@linux-iscsi.org This patch converts tcm_loop to use target_submit_cmd_map_mem() for I/O submission and mapping of pre-allocated SGL memory from incoming scsi_cmnd - se_cmd descriptors.

RE: [PATCH][SCSI] mpt3sas: Paer 1 of MPI API headers

2012-10-02 Thread Nandigama, Nagalakshmi
On Sat, Sep 29, 2012 at 10:52:50PM +0200, Bj??rn Mork wrote: sreekanth.re...@lsi.com writes: This patch contains MPI API headers Why can't this and the other headers be shared between the mpt2sas and mpt3sas drivers? Looks like you are duplicating a lot of code already present in

Re: [PATCH 3/4] target: Add TARGET_SCF_MAP_CLEAR_MEM work-around for tcm_loop

2012-10-02 Thread Christoph Hellwig
On Tue, Oct 02, 2012 at 07:15:46AM +, Nicholas A. Bellinger wrote: From: Nicholas Bellinger n...@linux-iscsi.org This patch carries forward a work-around from tcm_loop to target core code to explicitly clear control CDB READ paylods in order to avoid bugs in scsi-generic user-space code

Re: [PATCH 0/4] target: Add target_submit_cmd_map_mem and convert tcm_loop+tcm_vhost

2012-10-02 Thread Christoph Hellwig
This should also grow a patch 5 to unexport transport_generic_map_mem_to_cmd and mark it static. -- 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

[PATCH 0/3] virtio-scsi updates for 3.7

2012-10-02 Thread Paolo Bonzini
James, here is a resend of the three pending patches for virtio-scsi, with the bugfix first. Thanks, Paolo Paolo Bonzini (2): virtio-scsi: fix LUNs greater than 255 virtio-scsi: support online resizing of disks Richard W.M. Jones (1): virtio-scsi: initialize scatterlist structure

[PATCH 1/3] virtio-scsi: initialize scatterlist structure

2012-10-02 Thread Paolo Bonzini
From: Richard W.M. Jones rjo...@redhat.com The sg struct is used without being initialized, which breaks when CONFIG_DEBUG_SG is enabled. Cc: sta...@vger.kernel.org Signed-off-by: Richard W.M. Jones rjo...@redhat.com Signed-off-by: Paolo Bonzini pbonz...@redhat.com ---

[PATCH 3/3] virtio-scsi: support online resizing of disks

2012-10-02 Thread Paolo Bonzini
Support the LUN parameter change event. Currently, the host fires this event when the capacity of a disk is changed from the virtual machine monitor. The resize then appears in the kernel log like this: sd 0:0:0:0: [sda] 46137344 512-byte logical blocks: (23.6 GB/22.0 GIb) sda: detected

[PATCH 2/3] virtio-scsi: fix LUNs greater than 255

2012-10-02 Thread Paolo Bonzini
virtio-scsi needs to report LUNs greater than 256 using the flat format. Because the Linux SCSI layer just maps the SCSI LUN to an u32, without any parsing, these end up in the range from 16640 to 32767. Fix max_lun to account for the possibility that logical unit numbers are encoded with the

[PATCH 1/1] Drivers: scsi: storvsc: Account for in-transit packets in the RESET path

2012-10-02 Thread K. Y. Srinivasan
Properly account for I/O in transit before returning from the RESET call. In the absense of this patch, we could have a situation where the host may respond to a command that was issued prior to the issuance of the RESET command at some arbitrary time after responding to the RESET command.

Re: [PATCH 1/6] target/file: Re-enable optional fd_buffered_io=1 operation

2012-10-02 Thread Vladislav Bolkhovitin
Christoph Hellwig, on 10/01/2012 04:46 AM wrote: On Sun, Sep 30, 2012 at 05:58:11AM +, Nicholas A. Bellinger wrote: From: Nicholas Bellingern...@linux-iscsi.org This patch re-adds the ability to optionally run in buffered FILEIO mode (eg: w/o O_DSYNC) for device backends in order to once

Re: [PATCH 1/6] target/file: Re-enable optional fd_buffered_io=1 operation

2012-10-02 Thread Nicholas A. Bellinger
On Mon, 2012-10-01 at 04:46 -0400, Christoph Hellwig wrote: On Sun, Sep 30, 2012 at 05:58:11AM +, Nicholas A. Bellinger wrote: From: Nicholas Bellinger n...@linux-iscsi.org This patch re-adds the ability to optionally run in buffered FILEIO mode (eg: w/o O_DSYNC) for device backends

Re: [patch] target/iscsi: precedence bug in iscsit_set_dataout_sequence_values()

2012-10-02 Thread Nicholas A. Bellinger
On Tue, 2012-10-02 at 11:22 +0300, Dan Carpenter wrote: Clang warns about this bug: drivers/target/iscsi/iscsi_target_erl0.c:52:45: warning: operator '?:' has lower precedence than '+'; '+' will be evaluated first [-Wparentheses] Signed-off-by: Dan Carpenter

Re: [PATCH 1/4] target: Add target_submit_cmd_map_mem for SGL fabric memory passthrough

2012-10-02 Thread Nicholas A. Bellinger
On Tue, 2012-10-02 at 11:17 -0400, Christoph Hellwig wrote: On Tue, Oct 02, 2012 at 07:15:44AM +, Nicholas A. Bellinger wrote: From: Nicholas Bellinger n...@linux-iscsi.org This patch adds a new TARGET_SCF_MAP_MEM flag within __target_submit_cmd() + a target_submit_cmd_map_mem()

[PATCH-v2 0/4] target: Add target_submit_cmd_map_sgls + convert tcm_loop+tcm_vhost

2012-10-02 Thread Nicholas A. Bellinger
From: Nicholas Bellinger n...@linux-iscsi.org Hi folks, Here is a -v2 of the series to allow target_submit_cmd() logic to accept SGL passthrough memory using existing transport_generic_map_mem_to_cmd() code based upon hch's feedback this morning. The changelog from v1 - v2 includes: - Rename

[PATCH-v2 1/4] target: Add target_submit_cmd_map_sgls for SGL fabric memory passthrough

2012-10-02 Thread Nicholas A. Bellinger
From: Nicholas Bellinger n...@linux-iscsi.org This patch adds a new target_submit_cmd_map_sgls() to pass pre-allocated SGL memory using transport_generic_map_mem_to_cmd() logic into the generic target submit I/O codepath. It also adds a target_submit_cmd() wrapper around

[PATCH-v2 2/4] tcm_loop: Convert I/O path to use target_submit_cmd_map_sgls

2012-10-02 Thread Nicholas A. Bellinger
From: Nicholas Bellinger n...@linux-iscsi.org This patch converts tcm_loop to use target_submit_cmd_map_sgls() for I/O submission and mapping of pre-allocated SGL memory from incoming scsi_cmnd - se_cmd descriptors. This includes removing the original open-coded fabric uses of target core

[PATCH-v2 4/4] tcm_vhost: Convert I/O path to use target_submit_cmd_map_sgls

2012-10-02 Thread Nicholas A. Bellinger
From: Nicholas Bellinger n...@linux-iscsi.org This patch converts tcm_vhost to use target_submit_cmd_map_sgls() for I/O submission and mapping of pre-allocated SGL memory from incoming virtio-scsi SGL memory - se_cmd descriptors. This includes removing the original open-coded fabric uses of

Re: [PATCH-v2 1/4] target: Add target_submit_cmd_map_sgls for SGL fabric memory passthrough

2012-10-02 Thread Nicholas A. Bellinger
On Tue, 2012-10-02 at 21:16 +, Nicholas A. Bellinger wrote: From: Nicholas Bellinger n...@linux-iscsi.org This patch adds a new target_submit_cmd_map_sgls() to pass pre-allocated SGL memory using transport_generic_map_mem_to_cmd() logic into the generic target submit I/O codepath. It

Re: [PATCH v2 scsi] Short the path length of scsi_cmd_to_driver()

2012-10-02 Thread Martin K. Petersen
Li == Li Zhong zh...@linux.vnet.ibm.com writes: Li As suggested by James: this patch tries to short the path length of Li scsi_cmd_to_driver(). As only REQ_TYPE_BLOCK_PC commands can be Li submitted without a driver, so we could avoid the related NULL Li checking, as long as we make sure we

Re: [SCSI] mpt2sas T10 DIF fixes

2012-10-02 Thread Martin K. Petersen
Pasi == Pasi Kärkkäinen pa...@iki.fi writes: 2 of the patches are absolutely trivial and should just be applied. However, LSI objects to patch #3 which tweaks an incorrect NVDATA flag from within the driver. Instead LSI has promised to revert to the original behavior in their

RE: [PATCH 07/17] be2iscsi: Fix the kernel panic in blkiopoll disable mode

2012-10-02 Thread John, Sony
-Original Message- From: Michael Christie [mailto:micha...@cs.wisc.edu] Sent: Saturday, September 29, 2012 9:32 AM To: John, Sony Cc: linux-scsi@vger.kernel.org; Kallickal, Jayamohan Subject: Re: [PATCH 07/17] be2iscsi: Fix the kernel panic in blkiopoll disable mode On Sep 28, 2012,

Soft lockup in scsi_remove_target under 3.6 (regression from 3.5)

2012-10-02 Thread Jonathan McDowell
Upgraded to 3.6 today on my dev box and after seeing an FC attached SAN go down and come back up (due to an expected reboot) I started getting the following in my logs. It continues even after the array is back and functioning - I'm seeing: kernel:[109104.348034] BUG: soft lockup - CPU#6 stuck

Re: [PATCH 07/17] be2iscsi: Fix the kernel panic in blkiopoll disable mode

2012-10-02 Thread Mike Christie
On 10/02/2012 06:51 PM, John, Sony wrote: Creating UNBOUND WQ for each EQ in the driver. What is the benefit of doing this vs per hba like before? EQ's are created based on the NUM_CPU in the machine. Notification for task completion comes on an EQ. There could be multiple entries in the EQ

Re: Soft lockup in scsi_remove_target under 3.6 (regression from 3.5)

2012-10-02 Thread Mike Christie
On 10/02/2012 07:43 PM, Jonathan McDowell wrote: Upgraded to 3.6 today on my dev box and after seeing an FC attached SAN go down and come back up (due to an expected reboot) I started getting the following in my logs. It continues even after the array is back and functioning - I'm seeing: