[PATCH] scsi: Allow activation of scsi-mq per-driver

2016-01-22 Thread Johannes Thumshirn
s a single queue scsi layer and thus can make use of IO schedulers. host:~ # cat /sys/block/sd?/queue/scheduler noop deadline [cfq] none none none none none none none none none none none none none none none none Signed-off-by: Johannes Thumshirn --- drivers/scsi/fnic/fnic_main.c | 10 +

Re: [PATCH] scsi_dh_rdac: always retry MODE SELECT on command lock violation

2016-01-22 Thread Johannes Thumshirn
od > of MODE SELECT command from various HBAs, which will easily trigger > the sense code and exceed the retry count. > > References: bsc#956949 Without the bugzilla refrence Reviewed-by: Johannes Thumshirn > > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/devic

Re: [PATCH] drivers/scsi/emcctd: drivers/scsi/emcctd: Client driver implementation for EMC-Symmetrix GuestOS emulated Cut-Through Device

2016-01-25 Thread Johannes Thumshirn
; [MS>] I actually wanted to understand when this driver was last touched, and > hence this description was added. > > If you insist. > > > +MODULE_VERSION(EMCCTD_MODULE_VERSION); > > > + [...] > > > +#define ctd_dprintk(__m_fmt, ...)\ >

Re: [PATCH] drivers/scsi/emcctd: drivers/scsi/emcctd: Client driver implementation for EMC-Symmetrix GuestOS emulated Cut-Through Device

2016-01-25 Thread Johannes Thumshirn
actually fits logically together... Will > see if it can be factored. Not sure though. Yes please. It's not uber important but short functions and paths are generally favoured when debugging and reviewing code. Thanks, Johannes -- Johannes Thumshirn

Re: [PATCH] drivers/scsi/emcctd: drivers/scsi/emcctd: Client driver implementation for EMC-Symmetrix GuestOS emulated Cut-Through Device

2016-01-25 Thread Johannes Thumshirn
ou do a git format-patch -1 -v 2, this creates a v2-0001-your-patch-name.patch for git send-email which has an updated [PATCH V2] in the subject. At least, the above is the way I do it (i.e. there are more than one ways to do it). -- Johannes Thumshirn

Re: [PATCH] scsi: Allow activation of scsi-mq per-driver

2016-01-25 Thread Johannes Thumshirn
On Mon, Jan 25, 2016 at 02:05:25AM -0800, Christoph Hellwig wrote: > On Fri, Jan 22, 2016 at 02:41:28PM +0100, Johannes Thumshirn wrote: > > Allow the activation of the scsi-mq feature on a per-driver bassis as > > opposed > > to the current stack global (de)activation. >

Re: [PATCH V2 1/2] scsi: storvsc: Install the storvsc specific timeout handler for FC devices

2016-01-28 Thread Johannes Thumshirn
d 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 Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn Storage jthumsh...@suse.de

Re: [PATCH V2 2/2] scsi: storvsc: Use the specified target ID in device lookup

2016-01-28 Thread Johannes Thumshirn
srb->target_id; > INIT_WORK(&wrk->work, process_err_fn); > schedule_work(&wrk->work); > } > -- > 1.7.4.1 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-scsi" in > the body of a message to majord...@vge

Re: [PATCH v2 01/11] qla2xxx: Remove unneeded link offline message.

2016-01-28 Thread Johannes Thumshirn
N); > atomic_set(&vha->loop_down_timer, > -- > 1.7.7 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-scsi" in > the body of a message to majord...@vger.kernel.org > More majordo

Re: [PATCH v2 02/11] qla2xxx: Seed init-cb login timeout from nvram exclusively.

2016-01-28 Thread Johannes Thumshirn
inux-scsi" in > the body of a message to majord...@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html You really should be a bit more verbose in your commit messages... Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn

Re: [PATCH v2 03/11] qla2xxx: Allow fw to hold status before sending ABTS response.

2016-01-28 Thread Johannes Thumshirn
old ABTS."); > + > /* > * SCSI host template entry points > */ > -- > 1.7.7 > > -- > 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://vg

Re: [PATCH v2 05/11] qla2xxx: Add support for buffer to buffer credit value for ISP27XX.

2016-01-28 Thread Johannes Thumshirn
wwn_to_u64(vha->port_name)); > } > } > + > + if (IS_QLA27XX(vha->hw)) > + vha->bbcr = mcp->mb[15]; > } > > return rval; > @@ -3612,6 +3617,9 @@ qla24x

Re: [PATCH v2 04/11] qla2xxx: Add support for online flash update for ISP27XX.

2016-01-28 Thread Johannes Thumshirn
break; > } > } > goto done; > @@ -2989,6 +3021,9 @@ qla24xx_get_flash_version(scsi_qla_host_t *vha, void > *mbuf) > uint8_t code_type, last_image; > int i; > struct qla_hw_data *ha = vha->hw; > + uint32_t faddr =

Re: [PATCH v2 06/11] qla2xxx: Add support for Private link statistics counters.

2016-01-28 Thread Johannes Thumshirn
k_status(scsi_qla_host_t *vha, uint16_t > loop_id, > /* Copy over data -- firmware data is LE. */ > ql_dbg(ql_dbg_mbx + ql_dbg_verbose, vha, 0x1086, > "Done %s.\n", __func__); > -

Re: [PATCH v2 07/11] qla2xxx: Avoid side effects when using endianizer macros.

2016-01-28 Thread Johannes Thumshirn
chksum) { > ql_log(ql_log_fatal, vha, 0x0045, > "Inconsistent FLTL detected: checksum=0x%x.\n", chksum); > @@ -702,8 +702,8 @@ qla2xxx_get_flt_info(scsi_qla_host_t *vha, uint32_t > flt_addr) > } > > cnt = (sizeof(struct qla_flt_

Re: [PATCH v2 08/11] qla2xxx: Provide mbx info in BBCR data after mbx failure

2016-01-28 Thread Johannes Thumshirn
uint8_t reserved[11]; > + uint16_t mbx1; /* Port state */ > + uint8_t reserved[9]; > } __packed; > #endif > -- > 1.7.7 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-scsi" in > the body of a message to

Re: [PATCH v2 09/11] qla2xxx: Enable T10-DIF for ISP27XX

2016-01-28 Thread Johannes Thumshirn
"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 Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn Storage jthumsh...@suse.de

Re: [PATCH v2 11/11] qla2xxx: Update driver version to 8.07.00.33-k

2016-01-28 Thread Johannes Thumshirn
#define QLA2XXX_VERSION "8.07.00.33-k" > > #define QLA_DRIVER_MAJOR_VER 8 > #define QLA_DRIVER_MINOR_VER 7 > -- > 1.7.7 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-scsi" in > the body of a message to majord...@vger.kernel.

Re: [PATCH v2 10/11] qla2xxx: Set relogin flag when we fail to queue login requests.

2016-01-28 Thread Johannes Thumshirn
t; > -- > 1.7.7 > > -- > 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 Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn

Re: [PATCH 01/12] be2iscsi: Remove unused mcc_cq_lock

2016-02-01 Thread Johannes Thumshirn
(&ctrl->mbox_lock); > spin_lock_init(&phba->ctrl.mcc_lock); > - spin_lock_init(&phba->ctrl.mcc_cq_lock); > > return status; > } > -- > 2.5.0 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-scsi"

Re: [PATCH 02/12] be2iscsi: Use macros for MCC WRB and CQE fields

2016-02-01 Thread Johannes Thumshirn
; > sg_copy_from_buffer(job->reply_payload.sg_list, > @@ -5580,7 +5581,7 @@ static void beiscsi_eeh_resume(struct pci_dev *pdev) > for (i = 0; i < MAX_MCC_CMD; i++) { > init_waitqueue_head(&phba->ctrl.mc

Re: [PATCH 03/12] be2iscsi: Remove redundant MCC processing code

2016-02-01 Thread Johannes Thumshirn
16a6fd0..5ded3fa 100644 > --- a/drivers/scsi/be2iscsi/be_main.h > +++ b/drivers/scsi/be2iscsi/be_main.h > @@ -853,6 +853,7 @@ void hwi_ring_cq_db(struct beiscsi_hba *phba, >unsigned char rearm); > > unsigned int beiscsi_process_cq(struct be_eq_obj *pbe_eq

Re: [PATCH 04/12] be2iscsi: Rename MCC and BMBX processing functions

2016-02-01 Thread Johannes Thumshirn
csi_mccq_compl(phba, tag, NULL, NULL); > + rc = beiscsi_mccq_compl_wait(phba, tag, NULL, NULL); > if (rc) { > beiscsi_log(phba, KERN_ERR, > BEISCSI_LOG_INIT | BEISCSI_LOG_CONFIG, > @@ -1503,7 +1503,7 @@

Re: [PATCH 05/12] be2iscsi: Remove be_mbox_notify_wait function

2016-02-01 Thread Johannes Thumshirn
be_cmd_resp_mcc_create *resp = embedded_payload(wrb); > mccq->id = le16_to_cpu(resp->id); > @@ -1381,7 +1310,7 @@ int beiscsi_cmd_reset_function(struct beiscsi_hba > *phba) > be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0); > be_cmd_hdr_prepare(&req->hdr, CMD_SUBSYS

Re: [PATCH 06/12] be2iscsi: Fix be_mcc_compl_poll to use tag_state

2016-02-01 Thread Johannes Thumshirn
int tag) > +{ > + struct be_queue_info *mccq = &phba->ctrl.mcc_obj.q; > + u32 val = 0; > + > + set_bit(MCC_TAG_STATE_RUNNING, &phba->ctrl.ptag_state[tag].tag_state); > + val |= mccq->id & DB_MCCQ_RING_ID_MASK; > + val |= 1 << DB_MCCQ_

Re: [PATCH 07/12] be2iscsi: Cleanup processing of BMBX completion

2016-02-01 Thread Johannes Thumshirn
struct be_dma_mem *tag_mem; > unsigned int tag, wrb_idx; > > - /** > - * Just swap the status to host endian; mcc tag is opaquely copied > - * from mcc_wrb > - */ > be_dws_le_to_cpu(compl, 4); > tag = (compl->tag0 & MCC_Q_CMD

Re: [PATCH 08/12] be2iscsi: Fix MCC WRB leak in open_connection

2016-02-01 Thread Johannes Thumshirn
ddr->sa_family); > - mutex_unlock(&ctrl->mbox_lock); > - free_mcc_tag(&phba->ctrl, tag); > - return -EINVAL; > - > } > req->cid = cid; > i = phba->nxt_cqid++; > -- > 2.5.0 > > -- > To unsubsc

Re: [PATCH 09/12] be2iscsi: Couple MCC tag and WRB alloc and free

2016-02-01 Thread Johannes Thumshirn
ALL_IF_ID, > @@ -974,17 +949,14 @@ static int mgmt_exec_nonemb_cmd(struct beiscsi_hba > *phba, > int rc = 0; > > mutex_lock(&ctrl->mbox_lock); > - tag = alloc_mcc_tag(phba); > - if (!tag) { > + wrb = alloc_mcc_wrb(phba, &tag); > + if (!w

Re: [PATCH 10/12] be2iscsi: Fix ExpStatSn in management tasks

2016-02-01 Thread Johannes Thumshirn
nn = task->conn; > - struct beiscsi_hba *phba = NULL; > - > - phba = ((struct beiscsi_conn *)conn->dd_data)->phba; > beiscsi_log(phba, KERN_ERR, > BEISCSI_LOG_IO | BEISCSI_LOG_ISCSI, > "BM_%

Re: [PATCH 12/12] be2iscsi: Add lock to protect WRB alloc and free

2016-02-01 Thread Johannes Thumshirn
ead wrb_handle_drvr_list; > struct wrb_handle **pwrb_handle_base; > -- > 2.5.0 > > -- > 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.

Re: [PATCH 11/12] be2iscsi: _bh for io_sgl_lock and mgmt_sgl_lock

2016-02-01 Thread Johannes Thumshirn
BEISCSI_LOG_IO | > @@ -4890,15 +4889,11 @@ static int beiscsi_alloc_pdu(struct iscsi_task *task, > uint8_t opcode) > return 0; > > free_io_hndls: > - spin_lock(&phba->io_sgl_lock); > free_io_sgl_handle(phba, io_task->psgl_handle); &g

Re: [PATCH] Separate target visibility from reaped state information

2016-02-02 Thread Johannes Thumshirn
s just > masking a fundamental underlying problem. James' comment suggests that > there is something else going on. > > -- > Martin K. PetersenOracle Linux Engineering -- Johannes Thumshirn Storage jthumsh...@suse.de

Re: [PATCH 5/6] ibmvscsi: Remove unsupported host config MAD and sysfs interface

2016-02-04 Thread Johannes Thumshirn
VIOS, which is no longer supported anywhere. Further, it is > not defined in PAPR or supported by any AIX based VIOS. > > Treating as bit rot and removing the sysfs interface and associated > host config code accordingly. Doesn't removing a sysfs interface potentially break users

Re: [PATCH 1/6] ibmvscsi: Correct values for several viosrp_crq_format enums

2016-02-04 Thread Johannes Thumshirn
> + VIOSRP_INLINE_FORMAT = 0x06 > }; > > enum viosrp_crq_status { > -- > 2.5.0 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-scsi" in > the body of a message to majord...@vger.kernel.org > More maj

Re: [PATCH 2/6] ibmvscsi: Add and use enums for valid CRQ header values

2016-02-04 Thread Johannes Thumshirn
ndex d1044e9..17f2de0 100644 > --- a/drivers/scsi/ibmvscsi/viosrp.h > +++ b/drivers/scsi/ibmvscsi/viosrp.h > @@ -51,6 +51,13 @@ union srp_iu { > u8 reserved[SRP_MAX_IU_LEN]; > }; > > +enum viosrp_crq_headers { > + VIOSRP_CRQ_FREE = 0x00, > + VIOSRP_CRQ_VALID = 0x80,

Re: [PATCH 4/6] ibmvscsi: Use of_root to access OF device tree root node

2016-02-04 Thread Johannes Thumshirn
f_root); > } > > static void set_adapter_info(struct ibmvscsi_host_data *hostdata) > -- > 2.5.0 > > -- > 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 a

Re: [PATCH 3/6] ibmvscsi: Replace magic values in set_adpater_info() with defines

2016-02-04 Thread Johannes Thumshirn
EN 32 > +#define SRP_MAD_VERSION_1 1 > +#define SRP_MAD_OS_LINUX 2 > > union srp_iu { > struct srp_login_req login_req; > -- > 2.5.0 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-scsi" in > the bo

Re: [PATCH 6/6] ibmvscsi: Add endian conversions to sysfs attribute show functions

2016-02-04 Thread Johannes Thumshirn
uot;%d\n", > +be32_to_cpu(hostdata->madapter_info.os_type)); > return len; > } > > -- > 2.5.0 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-scsi" in > the body of a message t

Re: [PATCH V6 07/10] aacraid: Created new mutex for ioctl path

2016-02-04 Thread Johannes Thumshirn
gt; return ret; > } > > @@ -1194,6 +1188,7 @@ static int aac_probe_one(struct pci_dev *pdev, const > struct pci_device_id *id) > goto out_free_host; > spin_lock_init(&aac->fib_lock); > > + mutex_init(&aac->ioctl_mutex); > /*

Re: [PATCH 5/6] ibmvscsi: Remove unsupported host config MAD and sysfs interface

2016-02-05 Thread Johannes Thumshirn
On Thu, Feb 04, 2016 at 09:48:23AM -0800, Tyrel Datwyler wrote: > On 02/04/2016 12:03 AM, Johannes Thumshirn wrote: > > On Wed, Feb 03, 2016 at 05:28:33PM -0600, Tyrel Datwyler wrote: > >> A VIOSRP_HOST_CONFIG_TYPE management datagram (MAD) has existed in > >> the co

Re: [PATCH] be2iscsi: Fix memory leak in beiscsi_alloc_mem()

2016-02-10 Thread Johannes Thumshirn
->init_mem = kcalloc(SE_MEM_MAX, sizeof(*mem_descr), > > GFP_KERNEL); > > > -- > 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 h

Re: [PATCH] Separate target visibility from reaped state information

2016-02-10 Thread Johannes Thumshirn
concurrent scanning and removal from a simple rmmod ... I > > take it this is insmod rmmod in a tight loop? > > I am able to trigger the soft lockup with this test case run once: > > modprobe lpfc > run fio for 10 seconds > rmmod lpfc > > My test setup involves running

Re: [PATCH] Separate target visibility from reaped state information

2016-02-10 Thread Johannes Thumshirn
On Wed, Feb 10, 2016 at 07:34:51AM -0800, James Bottomley wrote: > On Wed, 2016-02-10 at 15:05 +0100, Johannes Thumshirn wrote: > > On Wed, Feb 03, 2016 at 11:38:16PM +0100, Sebastian Herbszt wrote: > > > James Bottomley wrote: > > > > On Mon, 2016-02-01 at 19:4

Re: [PATCH RESEND] scsi: sim710: fix build warning

2016-02-11 Thread Johannes Thumshirn
e function __init > sim710_eisa_probe()" > > sim710_eisa_probe() was having __init but that was being referenced from > sim710_eisa_driver. > > Signed-off-by: Sudip Mukherjee Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn

Re: [PATCH v2 2/7] ibmvscsi: Add and use enums for valid CRQ header values

2016-02-11 Thread Johannes Thumshirn
nsport event (0xFF). Further, initialization responses > have two formats namely initialize (0x01) and initialize complete > (0x02). Define these values as enums and use them in the code in > place of their magic number equivalents. > > Signed-off-by: Tyrel Datwyler Reviewed-by: Johann

Re: [PATCH v2 5/7] ibmvscsi: Remove unsupported host config MAD

2016-02-11 Thread Johannes Thumshirn
mains the same returning nothing. > > Signed-off-by: Tyrel Datwyler Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn Storage jthumsh...@suse.de+49 911 74053 689 SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnber

Re: [PATCH v2 7/7] ibmvscsi: use H_CLOSED instead of magic number

2016-02-11 Thread Johannes Thumshirn
On Wed, Feb 10, 2016 at 07:32:28PM -0600, Tyrel Datwyler wrote: > In a couple places the magic value of 2 is used to check the return > code of hypercalls. This translates to H_CLOSED. > > Signed-off-by: Tyrel Datwyler Reviewed-by: Johannes Thumshirn -- Johann

Re: [PATCH RESEND] scsi: ppa: use new parport device model

2016-02-11 Thread Johannes Thumshirn
On Thu, Feb 11, 2016 at 10:42:49AM +0530, Sudip Mukherjee wrote: > Modify ppa driver to use the new parallel port device model. > > Signed-off-by: Sudip Mukherjee Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn Storage jthumsh..

Re: [PATCH] lpfc: Remove redundant code block in lpfc_scsi_cmd_iocb_cmpl

2016-02-11 Thread Johannes Thumshirn
> On Wed, Feb 10, 2016 at 12:37 PM, Martin K. Petersen < > martin.peter...@oracle.com> wrote: > > >>>>> "Johannes" == Johannes Thumshirn writes: > > Johannes> This removes a redundant code block that will either be > Johannes>

Re: [PATCH] ibmvfc: byteswap scsi_id, wwpn, and node_name prior to logging

2016-02-12 Thread Johannes Thumshirn
teswap these values to host endian prior to logging. > > Signed-off-by: Tyrel Datwyler Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn Storage jthumsh...@suse.de+49 911 74053 689 SUSE LINUX GmbH, Maxfeldstr. 5,

Re: [PATCH] lpfc: fix missing zero termination in debugfs

2016-02-15 Thread Johannes Thumshirn
memset(dstbuf, 0, 32); > + memset(dstbuf, 0, 33); > size = (nbytes < 32) ? nbytes : 32; > if (copy_from_user(dstbuf, buf, size)) > return 0; > Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn Stora

Re: [PATCH] esas2r: Fix array overrun

2016-02-15 Thread Johannes Thumshirn
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 Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn Storage jthumsh...@suse.de

Re: [PATCH] [SCSI] dpt_i2o: fix build warning

2016-02-16 Thread Johannes Thumshirn
gt; > static int adpt_detect(struct scsi_host_template* sht) > -- > 1.9.1 > > -- > 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://vge

Re: [PATCH] scsi: fix soft lockup in scsi_remove_target() on module removal

2016-02-16 Thread Johannes Thumshirn
ping over it. > > Reported-by: Sebastian Herbszt > Tested-by: Sebastian Herbszt > Fixes: 40998193560dab6c3ce8d25f4fa58a23e252ef38 > Cc: sta...@vger.kernel.org > Signed-off-by: James Bottomley Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn

Re: [PATCH v2 3/7] ibmvscsi: Replace magic values in set_adpater_info() with defines

2016-02-17 Thread Johannes Thumshirn
d_adapter_info_data structure around > Tyrel> the fields they apply. > > Johannes: Mind checking this out? I'm sorry I though I already did. Reviewed-by: Johannes Thumshirn > > https://patchwork.kernel.org/patch/8276101/ > > -- > Martin K. PetersenOracle Linux

Re: [PATCH 1/2] mpt3sas: Deallocate resources before trying reallocation of the same in _base_allocate_memory_pools()

2016-02-17 Thread Johannes Thumshirn
pts to check for it (make coccicheck) and it'll spawn patches from people "fixing" it. So please get rid of the checks. Otherwise Reviewed-by: Johannes Thumshirn > if (ioc->chain_lookup) { > for (i = 0; i < ioc->chain_depth; i++) { >

Re: [PATCH 2/2] Modified Maintainers list for MPT FUSION DRIVERS.

2016-02-17 Thread Johannes Thumshirn
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 Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn Storage jthumsh...@sus

Re: [PATCH v2] [SCSI] dpt_i2o: use proper pci driver

2016-02-18 Thread Johannes Thumshirn
* safer in this specific case. > > The original patch is already having NACK from Johannes. So i better leave > this code here. Nah, wasn't a hard NACK. I'm OK with the original code, just was reluctant to the #ifdefs. I agree I didn't know the I

Re: [PATCH v2] fusion-mptbase: handle failed allocation for workqueue

2016-02-18 Thread Johannes Thumshirn
t; + return r; > + > } Please no. Not err1, err2 and err3. err1 could be "goto destroy_fw_event_q", err2 "destroy_reset_workq", err3 goto "free_ioc". > > > /*=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=*/ > -- >

Re: [PATCH v2 1/2] mpt3sas: Free memory pools before retrying to allocate with different value.

2016-02-18 Thread Johannes Thumshirn
> > -- > 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 Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn

Re: [PATCH v3] mptbase: fixup error handling paths in mpt_attach()

2016-02-23 Thread Johannes Thumshirn
). > > Reported-by: Insu Yun > Reviewed-by: Tomas Henzl > Signed-off-by: Ewan D. Milne Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn Storage jthumsh...@suse.de+49 911 74053 689 SUSE LINUX GmbH, Ma

Re: [PATCH] Update scsi host to use ida for host number

2015-09-01 Thread Johannes Thumshirn
PTR_ERR(shost->ehandler)); > - goto fail_kfree; > + goto fail_free_index; > } > > shost->tmf_work_q = alloc_workqueue("scsi_tmf_%d", > @@ -493,6 +516,10 @@ struct Scsi_Host *scsi_host_alloc(struct > scsi_

Re: [PATCH v4] mpt2sas: setpci reset kernel oops fix

2015-09-01 Thread Johannes Thumshirn
spin_unlock(&gioc_lock); > scsi_host_put(shost); > } > > @@ -8142,7 +8147,9 @@ _scsih_probe(struct pci_dev *pdev, const struct > pci_device_id *id) > ioc = shost_priv(shost); > memset(ioc, 0, sizeof(struct MPT2SAS_ADAPTER)); >

Re: [PATCH 1/3] scsi:stex.c Support to Pegasus series.

2015-09-02 Thread Johannes Thumshirn
break; > + default: > + if (hba->cardtype == st_yel) > + hba->supports_pm = 1; > + } > + > sts_offset = scratch_offset = (ci->rq_count+1) * ci->rq_size; > if (hba->cardtype == st_yel) >

Re: [PATCH 3/3] scsi:stex.c Add S3/S4 support

2015-09-02 Thread Johannes Thumshirn
stex_hba_stop(hba, stex_choice_sleep_mic(state)); > + else > + stex_hba_stop(hba, ST_IGNORED); > + return 0; > } > > + > +static int stex_resume(struct pci_dev *pdev) > +{ > + struct st_hba *hba = pci_get_drvdata(pdev); &

Re: [v2 PATCH 2/3] scsi:stex.c Add hotplug support

2015-09-03 Thread Johannes Thumshirn
ccb->cmd->scsi_done(ccb->cmd); > - ccb->cmd = NULL; > - } > - } > - spin_unlock_irqrestore(hba->host->host_lock, flags); > + > + return_abnormal_state(hba, DID_RESET); > > if (stex_handshake(hba) ==

Re: [PATCH 3/3] scsi:stex.c Add S3/S4 support

2015-09-03 Thread Johannes Thumshirn
pdev); > + > + hba->mu_status = MU_STATE_STARTING; > + stex_handshake(hba); > + return 0; > +} > MODULE_DEVICE_TABLE(pci, stex_pci_tbl); > > static struct pci_driver stex_pci_driver = { > @@ -1827,6 +1878,8 @@ static struct pci_driver stex_pci_driver = { > .probe

Re: [v2 PATCH 1/3] scsi:stex.c Support to Pegasus series.

2015-09-03 Thread Johannes Thumshirn
; + hba->supports_pm = 1; > + } > + > sts_offset = scratch_offset = (ci->rq_count+1) * ci->rq_size; > if (hba->cardtype == st_yel) > sts_offset += (ci->sts_count+1) * sizeof(u32); I somehow find that switch() above

Re: [PATCH 0/6] Create ida helpers and use them

2015-09-14 Thread Johannes Thumshirn
ers/base/soc.c| 17 +++- > drivers/block/mtip32xx/mtip32xx.c | 22 > drivers/block/nvme-core.c | 14 ++--- > drivers/block/rsxx/core.c | 16 ++- > drivers/scsi/sd.c | 18 +++-- > include/l

Re: [PATCH V3] fnic: check pci_map_single() return value

2015-09-21 Thread Johannes Thumshirn
ot;, r); + return SCSI_MLQUEUE_HOST_BUSY; + } + int_to_scsilun(sc->device->lun, &fc_lun); /* Enqueue the descriptor in the Copy WQ */ Looks good, Reviewed By: Tomas Henzl Oops forgot this one Reviewed-by: Johannes Thumshirn -- 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

Re: [PATCH] scsi_dh: avoid allowing dh_state to pass format specs when requesting a module

2015-09-24 Thread Johannes Thumshirn
dh = __scsi_dh_lookup(name); > if (!dh) { > - request_module(name); > + request_module("%s", name); > dh = __scsi_dh_lookup(name); > } Good catch. Reviewed-by: Johannes Thumshirn -- Johannes Thums

Re: [PATCH v2] scsi: Export SCSI Inquiry data to sysfs

2015-09-24 Thread Johannes Thumshirn
Ping? -- Johannes Thumshirn Storage jthumsh...@suse.de+49 911 74053 689 SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg GF: Felix Imendörffer, Jane Smithard, Graham Norton HRB 21284 (AG Nürnberg) Key fingerprint = EC38 9CAB

Re: [PATCH] be2iscsi: Fix bad WARN_ON

2015-10-01 Thread Johannes Thumshirn
t; WARN_ON(!virtual_address); > WARN_ON(!physical_address); > - WARN_ON(!length > 0); > + WARN_ON(!(length > 0)); Why aren't you doing WARN_ON(length <= 0); it's much nicer to read IMHO > WARN_ON(!sgl); > > sgl->va =

Re: [PATCH] [SCSI] fnic: use kzalloc in fnic_fcoe_process_vlan_resp

2015-10-02 Thread Johannes Thumshirn
vlan->state = FIP_VLAN_AVAIL; > list_add_tail(&vlan->list, &fnic->vlans); Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn Storage jthumsh...@suse.de+49 911 74053 68

Re: [PATCH v2] be2iscsi: Fix bad WARN_ON

2015-10-02 Thread Johannes Thumshirn
/be_main.c > +++ b/drivers/scsi/be2iscsi/be_main.c > @@ -3184,7 +3184,7 @@ be_sgl_create_contiguous(void *virtual_address, > { > WARN_ON(!virtual_address); > WARN_ON(!physical_address); > - WARN_ON(!length > 0); > + WARN_ON(length <= 0); > WARN_ON(!s

[PATCH] SCSI: Fix hard lockup in scsi_remove_target()

2015-10-02 Thread Johannes Thumshirn
SCSI layer in a lockless manner. This was discovered by a partner in a 24h stress test. Signed-off-by: Johannes Thumshirn --- drivers/scsi/scsi_sysfs.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/scsi/scsi_sysfs.c b/drivers/scsi/scsi_sysfs.c index b89..

Re: [PATCH 3/5] block: nvme-core: simplify ida usage

2015-10-02 Thread Johannes Thumshirn
rn -ENODEV; > > dev->instance = instance; > @@ -2734,7 +2726,7 @@ static int nvme_set_instance(struct nvme_dev *dev) > static void nvme_release_instance(struct nvme_dev *dev) > { > spin_lock(&dev_list_lock); > - ida_remove(&nvme_instance_id

Re: [PATCH 1/5] SCSI: sd: simplify ida usage

2015-10-02 Thread Johannes Thumshirn
d); > out_free: > @@ -3064,9 +3054,7 @@ static void scsi_disk_release(struct device *dev) > struct scsi_disk *sdkp = to_scsi_disk(dev); > struct gendisk *disk = sdkp->disk; > > - spin_lock(&sd_index_lock); > - ida_remove(&

Re: [PATCH 2/5] block: rsxx: core: simplify ida usage

2015-10-02 Thread Johannes Thumshirn
> failed_enable: > - spin_lock(&rsxx_ida_lock); > - ida_remove(&rsxx_disk_ida, card->disk_id); > - spin_unlock(&rsxx_ida_lock); > + ida_simple_remove(&rsxx_disk_ida, card->disk_id); > failed_ida_get: > kfree(card); Reviewed-by: Johannes Thu

Re: [PATCH 5/5] base: soc: siplify ida usage

2015-10-02 Thread Johannes Thumshirn
> + ida_simple_remove(&soc_ida, soc_dev->soc_dev_num); > out2: > kfree(soc_dev); > out1: > @@ -161,7 +150,7 @@ out1: > /* Ensure soc_dev->attr is freed prior to calling soc_device_unregister. */ > void soc_device_unregister(struct soc_device

Re: [PATCH 4/5] block: mtip32xx: simplify ida usage

2015-10-02 Thread Johannes Thumshirn
De-initialize the protocol layer. */ > mtip_hw_exit(dd); > @@ -4092,9 +4080,7 @@ static int mtip_block_shutdown(struct driver_data *dd) > dd->queue = NULL; > } > > - spin_lock(&rssd_index_lock); > - ida_remove(&rssd_index_ida, dd->in

Re: [PATCH] SCSI: Fix hard lockup in scsi_remove_target()

2015-10-02 Thread Johannes Thumshirn
> 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 -- Johannes Thumshirn Storage jthumsh...@su

Re: [PATCH -resend_2 1/1] cxgbi: fix build with EXTRA_CFLAGS

2015-10-06 Thread Johannes Thumshirn
t; index 8290cdaa4652..37458643749b 100644 > --- a/drivers/scsi/cxgbi/cxgb4i/Kbuild > +++ b/drivers/scsi/cxgbi/cxgb4i/Kbuild > @@ -1,3 +1,3 @@ > -EXTRA_CFLAGS += -I$(srctree)/drivers/net/ethernet/chelsio/cxgb4 > +ccflags-y += -I$(srctree)/drivers/net/ethernet/chelsio

Re: [PATCH -resend 1/1] fcoe: use continue instead of goto+label

2015-10-06 Thread Johannes Thumshirn
continue; > } > > spin_unlock_bh(&p->fcoe_rx_list.lock); Reviewed-by: Johannes Thumshirn -- Johannes Thumshirn Storage jthumsh...@suse.de+49 911 74053 689

Re: dm-multipath test scripts

2015-10-07 Thread Johannes Thumshirn
On Wed, 2015-10-07 at 05:39 +, Junichi Nomura wrote: > This is a set of scripts for kernel-side dm-multipath testing. > Current > set of scripts are stress testing of extreme situation and its > coverage > is limited. But recently found dm-mpath regressions should be > detectable > with this. I

Re: [PATCHv4 1/1] SCSI: hosts: update to use ida_simple for host_no management

2015-10-14 Thread Johannes Thumshirn
ost_alloc(struct > scsi_host_template *sht, int privsize) > > fail_kthread: > kthread_stop(shost->ehandler); > + fail_index_remove: > + ida_simple_remove(&host_index_ida, shost->host_no); > fail_kfree: > kfree(shost); > return NULL; > @@ -588,6

[PATCH 1/3] SCSI: Introduce device_lock and target_lock in Scsi_Host

2015-10-14 Thread Johannes Thumshirn
Introduce target_lock and device_lock to untangle the __devices and __targets lists from the host_lock. Signed-off-by: Johannes Thumshirn --- drivers/scsi/53c700.c | 3 +++ drivers/scsi/hosts.c | 2 ++ drivers/scsi/scsi.c | 8 drivers/scsi/scsi_scan.c | 10

[PATCH 3/3] SCSI: Rework list handling in __scsi_target_remove

2015-10-14 Thread Johannes Thumshirn
Rework the list handling in __scsi_target_remove(). The new version introduces a reap list for devices. Devices that shall be removed are placed on the reap list and can then be removed later on. Signed-off-by: Johannes Thumshirn --- drivers/scsi/scsi_sysfs.c | 10 +++--- 1 file changed, 7

[PATCH 2/3] SCSI: Rework list handling in scsi_target_remove

2015-10-14 Thread Johannes Thumshirn
Rework the list handling in scsi_target_remove(). The new version introduces a reap list for targets. Targets that shall be removed are placed on the reap list and can then be reaped later on. Signed-off-by: Johannes Thumshirn --- drivers/scsi/scsi_sysfs.c | 19 --- 1 file

[PATCH 0/3] SCSI: Fix hard lockup in scsi_remove_target()

2015-10-14 Thread Johannes Thumshirn
rmmod $module; modprobe $module; mount $mountpoint; done This is a follow up of the patch proposed here: http://marc.info/?l=linux-scsi&m=144377409311774&w=2 incorporating Christoph's comment Johannes Thumshirn (3): SCSI: Introduce device_lock and target_lock in Scsi_Host S

Re: [PATCH 0/3] SCSI: Fix hard lockup in scsi_remove_target()

2015-10-14 Thread Johannes Thumshirn
On Wed, 2015-10-14 at 07:30 -0700, James Bottomley wrote: > On Wed, 2015-10-14 at 15:50 +0200, Johannes Thumshirn wrote: > > Removing a SCSI target via scsi_remove_target() suspected to be > > racy. When a > > sibling get's removed from the list it can occassionly

Re: [PATCH 0/3] SCSI: Fix hard lockup in scsi_remove_target()

2015-10-14 Thread Johannes Thumshirn
Zitat von Christoph Hellwig : On Wed, Oct 14, 2015 at 04:39:07PM +0200, Johannes Thumshirn wrote: removal. This is what my initial proposal did as well. Christoph wanted me to decouple the whole process from the host_lock though and this is what this patches do as well now. I think we&#x

Re: [PATCH 0/3] SCSI: Fix hard lockup in scsi_remove_target()

2015-10-14 Thread Johannes Thumshirn
Zitat von James Bottomley : On Wed, 2015-10-14 at 16:39 +0200, Johannes Thumshirn wrote: On Wed, 2015-10-14 at 07:30 -0700, James Bottomley wrote: > On Wed, 2015-10-14 at 15:50 +0200, Johannes Thumshirn wrote: > > Removing a SCSI target via scsi_remove_target() suspected to be > &g

Re: [PATCH 0/3] SCSI: Fix hard lockup in scsi_remove_target()

2015-10-15 Thread Johannes Thumshirn
On Wed, 2015-10-14 at 16:22 -0400, Ewan Milne wrote: > On Wed, 2015-10-14 at 07:30 -0700, James Bottomley wrote: > > On Wed, 2015-10-14 at 15:50 +0200, Johannes Thumshirn wrote: > > > Removing a SCSI target via scsi_remove_target() suspected to be > > > racy. When a

Re: [PATCH 0/3] SCSI: Fix hard lockup in scsi_remove_target()

2015-10-16 Thread Johannes Thumshirn
On Wed, 2015-10-14 at 11:18 -0700, Christoph Hellwig wrote: > On Wed, Oct 14, 2015 at 08:45:56AM -0700, James Bottomley wrote: > > OK, so I really need you to separate the problems. Fixing the bug [..] > > Johannes, can you test the patch below? I've tested your patch and it doesn't show the l

Re: [PATCH] scsi: mvsas: fix misleading indentation

2015-10-20 Thread Johannes Thumshirn
gt;sas_addr)); >   > - rc = SAS_PHY_DOWN; > - return rc; > + rc = SAS_PHY_DOWN; > + return rc; >   } >   tei.port = dev->port->lldd_port; >   if (tei.port && !tei.port->port_attac

Re: [PATCH] SCSI: mvsas: Fix NULL pointer dereference in mvs_slot_task_free

2015-10-21 Thread Johannes Thumshirn
!slot) > > +   return; > > if (!slot->task) > > return; > > if (!sas_protocol_ata(task->task_proto)) > > -- > > 2.5.0 > > > > Can this get merged? > So far since august it have saved me from several ker

Re: [PATCH] SCSI: mvsas: Fix NULL pointer dereference in mvs_slot_task_free

2015-10-21 Thread Johannes Thumshirn
On Wed, 2015-10-21 at 16:18 +0300, Dāvis Mosāns wrote: > 2015-10-21 10:33 GMT+03:00 Johannes Thumshirn : > > On Tue, 2015-10-20 at 20:41 +0300, Dāvis Mosāns wrote: > > > 2015-08-21 7:29 GMT+03:00 Dāvis Mosāns : > > > > When pci_pool_alloc fails in mvs_task_prep then

Re: [PATCH] SCSI: mvsas: Fix NULL pointer dereference in mvs_slot_task_free

2015-10-21 Thread Johannes Thumshirn
On Wed, 2015-10-21 at 17:26 +0300, Dāvis Mosāns wrote: > 2015-10-21 16:47 GMT+03:00 Johannes Thumshirn : > > On Wed, 2015-10-21 at 16:18 +0300, Dāvis Mosāns wrote: > > > 2015-10-21 10:33 GMT+03:00 Johannes Thumshirn > > >: > > > > On Tue, 2015-1

Re: [PATCH] scsi: wd719x: Remove use of macro DEFINE_PCI_DEVICE_TABLE

2015-10-22 Thread Johannes Thumshirn
uct pci_dev > *pdev) >   scsi_host_put(sh); >  } >   > -static DEFINE_PCI_DEVICE_TABLE(wd719x_pci_table) = { > +static const struct pci_device_id wd719x_pci_table[] = { >   { PCI_DEVICE(PCI_VENDOR_ID_WD, 0x3296) }, >   {} >  }; Reviewed-by: Johannes Thumshir

<    2   3   4   5   6   7   8   9   10   11   >