Commit 07c4b9e9 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull SCSI fixes from James Bottomley:
 "24 fixes, all in drivers. The lion's share (16) are qla2xxx and the
  rest are iscsi (3), ufs (2), smarpqi, lpfc and libsas"

* tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: (24 commits)
  scsi: iscsi: Avoid potential deadlock in iscsi_if_rx func
  scsi: iscsi: Fix a potential deadlock in the timeout handler
  scsi: smartpqi: Update attribute name to `driver_version`
  scsi: libsas: stop discovering if oob mode is disconnected
  scsi: ufs: Disable autohibern8 feature in Cadence UFS
  scsi: iscsi: qla4xxx: fix double free in probe
  scsi: ufs: Give an unique ID to each ufs-bsg
  scsi: qla2xxx: Add debug dump of LOGO payload and ELS IOCB
  scsi: qla2xxx: Ignore PORT UPDATE after N2N PLOGI
  scsi: qla2xxx: Don't defer relogin unconditonally
  scsi: qla2xxx: Send Notify ACK after N2N PLOGI
  scsi: qla2xxx: Configure local loop for N2N target
  scsi: qla2xxx: Fix PLOGI payload and ELS IOCB dump length
  scsi: qla2xxx: Don't call qlt_async_event twice
  scsi: qla2xxx: Allow PLOGI in target mode
  scsi: qla2xxx: Change discovery state before PLOGI
  scsi: qla2xxx: Drop superfluous INIT_WORK of del_work
  scsi: qla2xxx: Initialize free_work before flushing it
  scsi: qla2xxx: Use explicit LOGO in target mode
  scsi: qla2xxx: Ignore NULL pointer in tcm_qla2xxx_free_mcmd
  ...
parents f61cf8de bba340c7
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -29,7 +29,7 @@ smartpqi specific entries in /sys
  smartpqi host attributes:
  -------------------------
  /sys/class/scsi_host/host*/rescan
  /sys/class/scsi_host/host*/version
  /sys/class/scsi_host/host*/driver_version

  The host rescan attribute is a write only attribute. Writing to this
  attribute will trigger the driver to scan for new, changed, or removed
+2 −2
Original line number Diff line number Diff line
@@ -1945,7 +1945,7 @@ enum blk_eh_timer_return iscsi_eh_cmd_timed_out(struct scsi_cmnd *sc)

	ISCSI_DBG_EH(session, "scsi cmd %p timedout\n", sc);

	spin_lock(&session->frwd_lock);
	spin_lock_bh(&session->frwd_lock);
	task = (struct iscsi_task *)sc->SCp.ptr;
	if (!task) {
		/*
@@ -2072,7 +2072,7 @@ enum blk_eh_timer_return iscsi_eh_cmd_timed_out(struct scsi_cmnd *sc)
done:
	if (task)
		task->last_timeout = jiffies;
	spin_unlock(&session->frwd_lock);
	spin_unlock_bh(&session->frwd_lock);
	ISCSI_DBG_EH(session, "return %s\n", rc == BLK_EH_RESET_TIMER ?
		     "timer reset" : "shutdown or nh");
	return rc;
+10 −1
Original line number Diff line number Diff line
@@ -81,12 +81,21 @@ static int sas_get_port_device(struct asd_sas_port *port)
		else
			dev->dev_type = SAS_SATA_DEV;
		dev->tproto = SAS_PROTOCOL_SATA;
	} else {
	} else if (port->oob_mode == SAS_OOB_MODE) {
		struct sas_identify_frame *id =
			(struct sas_identify_frame *) dev->frame_rcvd;
		dev->dev_type = id->dev_type;
		dev->iproto = id->initiator_bits;
		dev->tproto = id->target_bits;
	} else {
		/* If the oob mode is OOB_NOT_CONNECTED, the port is
		 * disconnected due to race with PHY down. We cannot
		 * continue to discover this port
		 */
		sas_put_device(dev);
		pr_warn("Port %016llx is disconnected when discovering\n",
			SAS_ADDR(port->attached_sas_addr));
		return -ENODEV;
	}

	sas_init_dev(dev);
+9 −6
Original line number Diff line number Diff line
@@ -4489,12 +4489,6 @@ lpfc_bsg_write_ebuf_set(struct lpfc_hba *phba, struct bsg_job *job,
	phba->mbox_ext_buf_ctx.seqNum++;
	nemb_tp = phba->mbox_ext_buf_ctx.nembType;

	dd_data = kmalloc(sizeof(struct bsg_job_data), GFP_KERNEL);
	if (!dd_data) {
		rc = -ENOMEM;
		goto job_error;
	}

	pbuf = (uint8_t *)dmabuf->virt;
	size = job->request_payload.payload_len;
	sg_copy_to_buffer(job->request_payload.sg_list,
@@ -4531,6 +4525,13 @@ lpfc_bsg_write_ebuf_set(struct lpfc_hba *phba, struct bsg_job *job,
				"2968 SLI_CONFIG ext-buffer wr all %d "
				"ebuffers received\n",
				phba->mbox_ext_buf_ctx.numBuf);

		dd_data = kmalloc(sizeof(struct bsg_job_data), GFP_KERNEL);
		if (!dd_data) {
			rc = -ENOMEM;
			goto job_error;
		}

		/* mailbox command structure for base driver */
		pmboxq = mempool_alloc(phba->mbox_mem_pool, GFP_KERNEL);
		if (!pmboxq) {
@@ -4579,6 +4580,8 @@ lpfc_bsg_write_ebuf_set(struct lpfc_hba *phba, struct bsg_job *job,
	return SLI_CONFIG_HANDLED;

job_error:
	if (pmboxq)
		mempool_free(pmboxq, phba->mbox_mem_pool);
	lpfc_bsg_dma_page_free(phba, dmabuf);
	kfree(dd_data);

+1 −0
Original line number Diff line number Diff line
@@ -178,6 +178,7 @@ qla2x00_sysfs_read_nvram(struct file *filp, struct kobject *kobj,

	faddr = ha->flt_region_nvram;
	if (IS_QLA28XX(ha)) {
		qla28xx_get_aux_images(vha, &active_regions);
		if (active_regions.aux.vpd_nvram == QLA27XX_SECONDARY_IMAGE)
			faddr = ha->flt_region_nvram_sec;
	}
Loading