[PATCH] scsi: libiscsi: Fix an error handling path in 'iscsi_session_setup()'

2017-09-13 Thread Christophe JAILLET
All error handling paths in this function go through 'iscsi_host_dec_session_cnt()' except this one. Fix it and properly decrement the number of active sessions in such a case. Signed-off-by: Christophe JAILLET --- drivers/scsi/libiscsi.c | 2 +- 1 file changed, 1

Re: [PATCH 01/10] arch:powerpc: return -ENOMEM on failed allocation

2017-09-13 Thread Allen
> I think the changelog for this series of conversions > should show that you've validated the change by > inspecting the return call chain at each modified line. > > Also, it seems you've cc'd the same mailing lists for > all of the patches modified by this series. > > It would be better to

Re: [PATCH V4 08/10] block: allow to allocate req with RQF_PREEMPT when queue is preempt frozen

2017-09-13 Thread Ming Lei
On Wed, Sep 13, 2017 at 07:07:53PM +, Bart Van Assche wrote: > On Thu, 2017-09-14 at 01:48 +0800, Ming Lei wrote: > > No, that patch only changes blk_insert_cloned_request() which is used > > by dm-rq(mpath) only, nothing to do with the reported issue during > > suspend and sending SCSI Domain

Re: [Patch v2 2/2] libiscsi: Remove iscsi_destroy_session

2017-09-13 Thread Lee Duncan
On 07/13/2017 09:11 AM, Khazhismel Kumykov wrote: > iscsi_session_teardown was the only user of this function. Function > currently is just short for iscsi_remove_session + iscsi_free_session. > > Signed-off-by: Khazhismel Kumykov Why is this needed? I dislike changes that

Re: [PATCH V2 00/12] scsi-mq support for ZBC disks

2017-09-13 Thread Damien Le Moal
Christoph, On 9/14/17 05:17, Christoph Hellwig wrote: > On Tue, Sep 12, 2017 at 05:38:05PM +0900, Damien Le Moal wrote: >> struct blk_zoned { >> unsigned int nr_zones; >> unsigned long *seq_zones; >> }; >> >> struct request_queue { >> ... >> #ifdef CONFIG_BLK_DEV_ZONED >>

Re: [PATCH V2 00/12] scsi-mq support for ZBC disks

2017-09-13 Thread Christoph Hellwig
On Tue, Sep 12, 2017 at 05:38:05PM +0900, Damien Le Moal wrote: > struct blk_zoned { > unsigned int nr_zones; > unsigned long *seq_zones; > }; > > struct request_queue { > ... > #ifdef CONFIG_BLK_DEV_ZONED > struct blk_zoned zoned; > #endif > ... Do we even need a

Re: [PATCH V4 08/10] block: allow to allocate req with RQF_PREEMPT when queue is preempt frozen

2017-09-13 Thread Bart Van Assche
On Thu, 2017-09-14 at 01:48 +0800, Ming Lei wrote: > No, that patch only changes blk_insert_cloned_request() which is used > by dm-rq(mpath) only, nothing to do with the reported issue during > suspend and sending SCSI Domain validation. There may be other ways to fix the SCSI domain validation

Re: [PATCH V4 08/10] block: allow to allocate req with RQF_PREEMPT when queue is preempt frozen

2017-09-13 Thread Ming Lei
On Wed, Sep 13, 2017 at 05:28:24PM +, Bart Van Assche wrote: > On Thu, 2017-09-14 at 00:48 +0800, Ming Lei wrote: > > Could you please let me know if your concern about race between > > preempt freeze and blk_cleanup_queue() is addressed in my last > > reply? > > Shouldn't we wait until

Re: [PATCH] scsi: Remove unnecessary condition in sd_read_block_limits()

2017-09-13 Thread Bart Van Assche
On Wed, 2017-09-13 at 16:29 +0200, Lukas Czerner wrote: > After series of changes around WRITE_SAME and UNMAP setup we ended up > with leftover unnecessary condition. Remove it. A similar patch was sitting in my tree and waiting to be posted. But since you posted this first: Reviewed-by: Bart

Re: [PATCH V4 08/10] block: allow to allocate req with RQF_PREEMPT when queue is preempt frozen

2017-09-13 Thread Bart Van Assche
On Thu, 2017-09-14 at 00:48 +0800, Ming Lei wrote: > Could you please let me know if your concern about race between > preempt freeze and blk_cleanup_queue() is addressed in my last > reply? Shouldn't we wait until v4.13-rc1 has been released before spending more energy on this? Certain patches

Re: [PATCH V4 08/10] block: allow to allocate req with RQF_PREEMPT when queue is preempt frozen

2017-09-13 Thread Ming Lei
On Tue, Sep 12, 2017 at 11:40:57AM +0800, Ming Lei wrote: > On Mon, Sep 11, 2017 at 04:03:55PM +, Bart Van Assche wrote: > > On Mon, 2017-09-11 at 19:10 +0800, Ming Lei wrote: > > > @@ -787,6 +787,35 @@ int blk_queue_enter(struct request_queue *q, > > > unsigned flags) > > > if

Re: [PATCH 06/10] drivers:ethernet: return -ENOMEM on allocation failure.

2017-09-13 Thread David Miller
From: Allen Pais Date: Wed, 13 Sep 2017 13:02:15 +0530 > Signed-off-by: Allen Pais This is quite pointless as the caller doesn't do anything with the value, it just tests whether a negative value is returned or not.

Re: [PATCH] scsi: fix the issue that iscsi_if_rx doesn't parse nlmsg properly

2017-09-13 Thread Chris Leech
Acked-by: Chris Leech On Sun, Aug 27, 2017 at 08:25:26PM +0800, Xin Long wrote: > ChunYu found a kernel crash by syzkaller: > > [ 651.617875] kasan: CONFIG_KASAN_INLINE enabled > [ 651.618217] kasan: GPF could be caused by NULL-ptr deref or user memory > access > [

Re: [PATCH 10/10] fs:btrfs: return -ENOMEM on allocation failure.

2017-09-13 Thread David Sterba
On Wed, Sep 13, 2017 at 01:02:19PM +0530, Allen Pais wrote: > Signed-off-by: Allen Pais > --- > fs/btrfs/check-integrity.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/fs/btrfs/check-integrity.c b/fs/btrfs/check-integrity.c > index

Re: [PATCH 01/10] arch:powerpc: return -ENOMEM on failed allocation

2017-09-13 Thread Joe Perches
On Wed, 2017-09-13 at 13:02 +0530, Allen Pais wrote: > Signed-off-by: Allen Pais I think the changelog for this series of conversions should show that you've validated the change by inspecting the return call chain at each modified line. Also, it seems you've cc'd the same

[PATCH] scsi: Remove unnecessary condition in sd_read_block_limits()

2017-09-13 Thread Lukas Czerner
After series of changes around WRITE_SAME and UNMAP setup we ended up with leftover unnecessary condition. Remove it. Signed-off-by: Lukas Czerner --- drivers/scsi/sd.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c index

[GIT PULL] final round of SCSI updates for the 4.13+ merge window

2017-09-13 Thread James Bottomley
A tiny update: one patch corrects a Kconfig problem with the shift of the SAS SMP code to BSG and the other removes a vestige of user space target mode. The patch is available here: git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi.git scsi-misc The short changelog is: Arnd Bergmann (1):

RE: system hung up when offlining CPUs

2017-09-13 Thread Thomas Gleixner
On Wed, 13 Sep 2017, Kashyap Desai wrote: > > On 09/12/2017 08:15 PM, YASUAKI ISHIMATSU wrote: > > > + linux-scsi and maintainers of megasas > > >> In my server, IRQ#66-89 are sent to CPU#24-29. And if I offline > > >> CPU#24-29, I/O does not work, showing the following messages. > > This

Re: [PATCH V2 5/9] pm80xx : cleanup in pm8001_abort_task function.

2017-09-13 Thread Jinpu Wang
On Wed, Feb 18, 2015 at 12:36 AM, Viswas G wrote: > Signed-off-by: Deepak Ukey > Signed-off-by: Viswas G > --- > drivers/scsi/pm8001/pm8001_sas.c | 49 > +++- > 1 file changed, 13

Re: [PATCH 05/10] drivers:net: return -ENOMEM on allocation failure.

2017-09-13 Thread Allen
> propagates the -1. That is only called by bond_open() with: > > if (bond_alb_initialize(bond, (BOND_MODE(bond) == BOND_MODE_ALB))) > return -ENOMEM; > > So you might want to also modify this code, to return the return > value, rather than use the hard coded ENOMEM. >

Re: [PATCH 06/10] drivers:ethernet: return -ENOMEM on allocation failure.

2017-09-13 Thread Allen
> > static int cas_alloc_rxds(struct cas *cp) > { > int i; > > for (i = 0; i < N_RX_DESC_RINGS; i++) { > if (cas_alloc_rx_desc(cp, i) < 0) { > cas_free_rxds(cp); > return -1; > } > } >

Re: [PATCH 06/10] drivers:ethernet: return -ENOMEM on allocation failure.

2017-09-13 Thread Andrew Lunn
On Wed, Sep 13, 2017 at 01:02:15PM +0530, Allen Pais wrote: > Signed-off-by: Allen Pais > --- > drivers/net/ethernet/sun/cassini.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/net/ethernet/sun/cassini.c >

Re: [PATCH 05/10] drivers:net: return -ENOMEM on allocation failure.

2017-09-13 Thread Andrew Lunn
On Wed, Sep 13, 2017 at 01:02:14PM +0530, Allen Pais wrote: > Signed-off-by: Allen Pais Hi Allen Although correct, if you look higher up the call chain, this appears to be not so useful. rlb_initialize() is only called by bond_alb_initialize(), and it propagates the -1.

RE: system hung up when offlining CPUs

2017-09-13 Thread Kashyap Desai
> > On 09/12/2017 08:15 PM, YASUAKI ISHIMATSU wrote: > > + linux-scsi and maintainers of megasas > > > > When offlining CPU, I/O stops. Do you have any ideas? > > > > On 09/07/2017 04:23 PM, YASUAKI ISHIMATSU wrote: > >> Hi Mark and Christoph, > >> > >> Sorry for the late reply. I appreciated that

Re: system hung up when offlining CPUs

2017-09-13 Thread Hannes Reinecke
On 09/12/2017 08:15 PM, YASUAKI ISHIMATSU wrote: > + linux-scsi and maintainers of megasas > > When offlining CPU, I/O stops. Do you have any ideas? > > On 09/07/2017 04:23 PM, YASUAKI ISHIMATSU wrote: >> Hi Mark and Christoph, >> >> Sorry for the late reply. I appreciated that you fixed the

Re: [PATCH V2 8/9] pm80xx : panic on ncq error cleaning up the read log.

2017-09-13 Thread Jinpu Wang
On Wed, Feb 18, 2015 at 12:36 AM, Viswas G wrote: > when there's an error in 'ncq mode' the host has to read the ncq > error log (10h) to clear the error state. however, the ccb that > is setup for doing this doesn't setup the ccb so that the > previous state is cleared.

Re: [PATCH V2 7/9] pm80xx : corrected SATA abort handling sequence.

2017-09-13 Thread Jinpu Wang
On Wed, Feb 18, 2015 at 12:36 AM, Viswas G wrote: > Modified SATA abort handling with following steps: > 1) Set device state as recovery. > 2) Send phy reset. > 3) Wait for reset completion. > 4) After successful reset, abort all IO's to the device. > 5) After aborting all

Re: [PATCH V2 6/9] pm80xx : modified port reset timer value for PM8006 card

2017-09-13 Thread Jinpu Wang
On Wed, Feb 18, 2015 at 12:36 AM, Viswas G wrote: > Added port reset timer value as 2000ms for PM8006 sata controller. > > Signed-off-by: Deepak Ukey > Signed-off-by: Viswas G > --- > drivers/scsi/pm8001/pm80xx_hwi.c |

Re: [PATCH V2 4/9] pm80xx : tag allocation for phy control request.

2017-09-13 Thread Jinpu Wang
On Wed, Feb 18, 2015 at 12:36 AM, Viswas G wrote: > tag is taken from the tag pool instead of using the hardcoded > tag value(1). > > Signed-off-by: Deepak Ukey > Signed-off-by: Viswas G > --- >

Re: [PATCH V2 1/9] pm80xx : redefine sas_identify_frame structure

2017-09-13 Thread Jinpu Wang
On Wed, Feb 18, 2015 at 12:36 AM, Viswas G wrote: > sas_identify structure defined by pm80xx doesn't have CRC field. > So added a new sas_identify structure without CRC. > > v2: > - Since the structure changes is applicable for only pm80xx, >

[PATCH V2 4/9] pm80xx : tag allocation for phy control request.

2017-09-13 Thread Viswas G
tag is taken from the tag pool instead of using the hardcoded tag value(1). Signed-off-by: Deepak Ukey Signed-off-by: Viswas G --- drivers/scsi/pm8001/pm8001_hwi.c | 3 +++ drivers/scsi/pm8001/pm80xx_hwi.c | 10 +++--- 2 files changed, 10

[PATCH V2 1/9] pm80xx : redefine sas_identify_frame structure

2017-09-13 Thread Viswas G
sas_identify structure defined by pm80xx doesn't have CRC field. So added a new sas_identify structure without CRC. v2: - Since the structure changes is applicable for only pm80xx, sas_identify_frame_local structure moved to pm80xx_hwi.h. Signed-off-by: Raj Dinesh

[PATCH V2 3/9] pm80xx : Different SAS addresses for phys.

2017-09-13 Thread Viswas G
Different SAS addresses are assigned for each set of phys. Signed-off-by: Viswas G Acked-by: Jack Wang --- drivers/scsi/pm8001/pm8001_init.c | 13 + drivers/scsi/pm8001/pm80xx_hwi.c | 3 +-- 2 files changed, 10 insertions(+), 6

[PATCH V2 6/9] pm80xx : modified port reset timer value for PM8006 card

2017-09-13 Thread Viswas G
Added port reset timer value as 2000ms for PM8006 sata controller. Signed-off-by: Deepak Ukey Signed-off-by: Viswas G --- drivers/scsi/pm8001/pm80xx_hwi.c | 6 ++ 1 file changed, 6 insertions(+) diff --git

[PATCH V2 9/9] pm80xx : corrected linkrate value.

2017-09-13 Thread Viswas G
Corrected the value defined for LINKRATE_60 (6 Gig). Signed-off-by: Raj Dinesh Signed-off-by: Viswas G Acked-by: Jack Wang --- drivers/scsi/pm8001/pm80xx_hwi.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

[PATCH V2 2/9] pm80xx : ILA and inactive firmware version through sysfs

2017-09-13 Thread Viswas G
Added support to read ILA version and inactive firmware version from MPI configuration table and export through sysfs. Signed-off-by: Deepak Ukey Signed-off-by: Viswas G Acked-by: Jack Wang ---

[PATCH V2 8/9] pm80xx : panic on ncq error cleaning up the read log.

2017-09-13 Thread Viswas G
when there's an error in 'ncq mode' the host has to read the ncq error log (10h) to clear the error state. however, the ccb that is setup for doing this doesn't setup the ccb so that the previous state is cleared. if the ccb was previously used for an IO n_elems is set and pm8001_ccb_task_free()

[PATCH V2 0/9] pm80xx updates

2017-09-13 Thread Viswas G
This patch set include some bug fixes and enhancement for pm80xx driver. Changes from V1: - sas_identify_frame_local structure moved to pm80xx_hwi.h - sata abort handling patch split to four patches. - tag allocation for phy control request. -

[PATCH V2 7/9] pm80xx : corrected SATA abort handling sequence.

2017-09-13 Thread Viswas G
Modified SATA abort handling with following steps: 1) Set device state as recovery. 2) Send phy reset. 3) Wait for reset completion. 4) After successful reset, abort all IO's to the device. 5) After aborting all IO's to device, set device state as operational. Signed-off-by: Deepak Ukey

[PATCH V2 5/9] pm80xx : cleanup in pm8001_abort_task function.

2017-09-13 Thread Viswas G
Signed-off-by: Deepak Ukey Signed-off-by: Viswas G --- drivers/scsi/pm8001/pm8001_sas.c | 49 +++- 1 file changed, 13 insertions(+), 36 deletions(-) diff --git a/drivers/scsi/pm8001/pm8001_sas.c

[PATCH V3 3/3] scsi: Align queue to ARCH_DMA_MINALIGN in non-coherent DMA mode

2017-09-13 Thread Huacai Chen
In non-coherent DMA mode, kernel uses cache flushing operations to maintain I/O coherency, so scsi's block queue should be aligned to ARCH_DMA_MINALIGN. Cc: sta...@vger.kernel.org Signed-off-by: Huacai Chen --- drivers/scsi/scsi_lib.c | 9 ++--- 1 file changed, 6

[bug report] [SCSI] lpfc: NPIV: add NPIV support on top of SLI-3

2017-09-13 Thread Dan Carpenter
[ Really old patch... :/ - dan ] Hello James Smart, The patch 92d7f7b0cde3: "[SCSI] lpfc: NPIV: add NPIV support on top of SLI-3" from Jun 17, 2007, leads to the following static checker warning: drivers/scsi/lpfc/lpfc_els.c:6148 lpfc_els_rcv_rscn() error: buffer underflow

[PATCH] scsi: aacraid: error: testing array offset 'bus' after use

2017-09-13 Thread Nikola Pajkovsky
Fix possible indexing array of bound for >hba_map[bus][cid], where bus and cid boundary check happens later. Fixes: 0d643ff3c353 ("scsi: aacraid: use aac_tmf_callback for reset fib") Signed-off-by: Nikola Pajkovsky --- drivers/scsi/aacraid/linit.c | 20

[PATCH 03/10] driver:gpu: return -ENOMEM on allocation failure.

2017-09-13 Thread Allen Pais
Signed-off-by: Allen Pais --- drivers/gpu/drm/gma500/mid_bios.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/gma500/mid_bios.c b/drivers/gpu/drm/gma500/mid_bios.c index d75ecb3..1fa1633 100644 --- a/drivers/gpu/drm/gma500/mid_bios.c

[PATCH 02/10] drivers:crypto: return -ENOMEM on allocation failure.

2017-09-13 Thread Allen Pais
Signed-off-by: Allen Pais --- drivers/crypto/omap-aes-gcm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/crypto/omap-aes-gcm.c b/drivers/crypto/omap-aes-gcm.c index 7d4f8a4..2542224 100644 --- a/drivers/crypto/omap-aes-gcm.c +++

[PATCH 05/10] drivers:net: return -ENOMEM on allocation failure.

2017-09-13 Thread Allen Pais
Signed-off-by: Allen Pais --- drivers/net/bonding/bond_alb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/bonding/bond_alb.c b/drivers/net/bonding/bond_alb.c index c02cc81..89df377 100644 --- a/drivers/net/bonding/bond_alb.c +++

[PATCH 06/10] drivers:ethernet: return -ENOMEM on allocation failure.

2017-09-13 Thread Allen Pais
Signed-off-by: Allen Pais --- drivers/net/ethernet/sun/cassini.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/sun/cassini.c b/drivers/net/ethernet/sun/cassini.c index 382993c..fc0ea3a 100644 ---

[PATCH 04/10] drivers:mpt: return -ENOMEM on allocation failure.

2017-09-13 Thread Allen Pais
Signed-off-by: Allen Pais --- drivers/message/fusion/mptbase.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/message/fusion/mptbase.c b/drivers/message/fusion/mptbase.c index 84eab28..7920b2b 100644 ---

[PATCH 08/10] driver:cxgbit: return -NOMEM on allocation failure.

2017-09-13 Thread Allen Pais
Signed-off-by: Allen Pais --- drivers/target/iscsi/cxgbit/cxgbit_target.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/target/iscsi/cxgbit/cxgbit_target.c b/drivers/target/iscsi/cxgbit/cxgbit_target.c index 514986b..47127d6 100644 ---

[PATCH 07/10] driver:megaraid: return -ENOMEM on allocation failure.

2017-09-13 Thread Allen Pais
Signed-off-by: Allen Pais --- drivers/scsi/megaraid/megaraid_mbox.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/megaraid/megaraid_mbox.c b/drivers/scsi/megaraid/megaraid_mbox.c index ec3c438..b09a0a6 100644 ---

[PATCH 10/10] fs:btrfs: return -ENOMEM on allocation failure.

2017-09-13 Thread Allen Pais
Signed-off-by: Allen Pais --- fs/btrfs/check-integrity.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/btrfs/check-integrity.c b/fs/btrfs/check-integrity.c index 7d5a9b5..efa4c23 100644 --- a/fs/btrfs/check-integrity.c +++

[PATCH 09/10] driver:video: return -ENOMEM on allocation failure.

2017-09-13 Thread Allen Pais
Signed-off-by: Allen Pais --- drivers/video/fbdev/matrox/matroxfb_base.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/video/fbdev/matrox/matroxfb_base.c b/drivers/video/fbdev/matrox/matroxfb_base.c index f6a0b9a..5cd238d 100644 ---

[PATCH 01/10] arch:powerpc: return -ENOMEM on failed allocation

2017-09-13 Thread Allen Pais
Signed-off-by: Allen Pais --- arch/powerpc/platforms/cell/spider-pci.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/platforms/cell/spider-pci.c b/arch/powerpc/platforms/cell/spider-pci.c index d1e61e2..82aa3f7 100644 ---

Re: [PATCH v4 00/14] mpt3sas driver NVMe support:

2017-09-13 Thread Suganath Prabu Subramani
Hi Martin, Is there any update on the submitted mpt3sas patches. Thanks, Suganath Prabu S On Fri, Sep 1, 2017 at 2:09 PM, Suganath Prabu Subramani wrote: > Hi Martin, > > On Fri, Sep 1, 2017 at 8:52 AM, Martin K. Petersen >