Commit 5d766d55 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull SCSI fixes from James Bottomley:
 "One core fix for an oops which can occur if the error handling thread
  fails to start for some reason and the driver is removed.

  The other fixes are all minor ones in drivers"

* tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
  scsi: ufs: core: Add missing host_lock in ufshcd_vops_setup_xfer_req()
  scsi: mpi3mr: Fix W=1 compilation warnings
  scsi: pm8001: Clean up kernel-doc and comments
  scsi: zfcp: Report port fc_security as unknown early during remote cable pull
  scsi: core: Fix bad pointer dereference when ehandler kthread is invalid
  scsi: fas216: Fix a build error
  scsi: core: Fix the documentation of the scsi_execute() time parameter
parents 44cb60b4 053c16ac
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -487,6 +487,7 @@ static ssize_t zfcp_sysfs_port_fc_security_show(struct device *dev,
	if (0 == (status & ZFCP_STATUS_COMMON_OPEN) ||
	    0 == (status & ZFCP_STATUS_COMMON_UNBLOCKED) ||
	    0 == (status & ZFCP_STATUS_PORT_PHYS_OPEN) ||
	    0 != (status & ZFCP_STATUS_PORT_LINK_TEST) ||
	    0 != (status & ZFCP_STATUS_COMMON_ERP_FAILED) ||
	    0 != (status & ZFCP_STATUS_COMMON_ACCESS_BOXED))
		i = sprintf(buf, "unknown\n");
+1 −1
Original line number Diff line number Diff line
@@ -2010,7 +2010,7 @@ static void fas216_rq_sns_done(FAS216_Info *info, struct scsi_cmnd *SCpnt,
		   "request sense complete, result=0x%04x%02x%02x",
		   result, SCpnt->SCp.Message, SCpnt->SCp.Status);

	if (result != DID_OK || SCpnt->SCp.Status != GOOD)
	if (result != DID_OK || SCpnt->SCp.Status != SAM_STAT_GOOD)
		/*
		 * Something went wrong.  Make sure that we don't
		 * have valid data in the sense buffer that could
+1 −0
Original line number Diff line number Diff line
@@ -488,6 +488,7 @@ struct Scsi_Host *scsi_host_alloc(struct scsi_host_template *sht, int privsize)
		shost_printk(KERN_WARNING, shost,
			"error handler thread failed to spawn, error = %ld\n",
			PTR_ERR(shost->ehandler));
		shost->ehandler = NULL;
		goto fail;
	}

+7 −8
Original line number Diff line number Diff line
@@ -2607,14 +2607,13 @@ static int mpi3mr_issue_iocinit(struct mpi3mr_ioc *mrioc)
		goto out;
	}
	drv_info->information_length = cpu_to_le32(data_len);
	strncpy(drv_info->driver_signature, "Broadcom", sizeof(drv_info->driver_signature));
	strncpy(drv_info->os_name, utsname()->sysname, sizeof(drv_info->os_name));
	drv_info->os_name[sizeof(drv_info->os_name) - 1] = 0;
	strncpy(drv_info->os_version, utsname()->release, sizeof(drv_info->os_version));
	drv_info->os_version[sizeof(drv_info->os_version) - 1] = 0;
	strncpy(drv_info->driver_name, MPI3MR_DRIVER_NAME, sizeof(drv_info->driver_name));
	strncpy(drv_info->driver_version, MPI3MR_DRIVER_VERSION, sizeof(drv_info->driver_version));
	strncpy(drv_info->driver_release_date, MPI3MR_DRIVER_RELDATE, sizeof(drv_info->driver_release_date));
	strscpy(drv_info->driver_signature, "Broadcom", sizeof(drv_info->driver_signature));
	strscpy(drv_info->os_name, utsname()->sysname, sizeof(drv_info->os_name));
	strscpy(drv_info->os_version, utsname()->release, sizeof(drv_info->os_version));
	strscpy(drv_info->driver_name, MPI3MR_DRIVER_NAME, sizeof(drv_info->driver_name));
	strscpy(drv_info->driver_version, MPI3MR_DRIVER_VERSION, sizeof(drv_info->driver_version));
	strscpy(drv_info->driver_release_date, MPI3MR_DRIVER_RELDATE,
	    sizeof(drv_info->driver_release_date));
	drv_info->driver_capabilities = 0;
	memcpy((u8 *)&mrioc->driver_info, (u8 *)drv_info,
	    sizeof(mrioc->driver_info));
+26 −22
Original line number Diff line number Diff line
@@ -77,7 +77,7 @@ DEVICE_ATTR(interface_rev, S_IRUGO, pm8001_ctl_mpi_interface_rev_show, NULL);
 * @attr: device attribute (unused)
 * @buf: the buffer returned
 *
 * A sysfs 'read only' shost attribute.
 * A sysfs 'read-only' shost attribute.
 */
static ssize_t controller_fatal_error_show(struct device *cdev,
		struct device_attribute *attr, char *buf)
@@ -149,7 +149,7 @@ static ssize_t pm8001_ctl_ila_version_show(struct device *cdev,
static DEVICE_ATTR(ila_version, 0444, pm8001_ctl_ila_version_show, NULL);

/**
 * pm8001_ctl_inactive_fw_version_show - Inacative firmware version number
 * pm8001_ctl_inactive_fw_version_show - Inactive firmware version number
 * @cdev: pointer to embedded class device
 * @attr: device attribute (unused)
 * @buf: the buffer returned
@@ -396,6 +396,7 @@ static DEVICE_ATTR(aap_log, S_IRUGO, pm8001_ctl_aap_log_show, NULL);
 * @cdev:pointer to embedded class device
 * @attr: device attribute (unused)
 * @buf: the buffer returned
 *
 * A sysfs 'read-only' shost attribute.
 */
static ssize_t pm8001_ctl_ib_queue_log_show(struct device *cdev,
@@ -430,6 +431,7 @@ static DEVICE_ATTR(ib_log, S_IRUGO, pm8001_ctl_ib_queue_log_show, NULL);
 * @cdev:pointer to embedded class device
 * @attr: device attribute (unused)
 * @buf: the buffer returned
 *
 * A sysfs 'read-only' shost attribute.
 */

@@ -464,6 +466,7 @@ static DEVICE_ATTR(ob_log, S_IRUGO, pm8001_ctl_ob_queue_log_show, NULL);
 * @cdev:pointer to embedded class device
 * @attr: device attribute (unused)
 * @buf:the buffer returned
 *
 * A sysfs 'read-only' shost attribute.
 */
static ssize_t pm8001_ctl_bios_version_show(struct device *cdev,
@@ -555,13 +558,13 @@ static ssize_t pm8001_ctl_iop_log_show(struct device *cdev,
static DEVICE_ATTR(iop_log, S_IRUGO, pm8001_ctl_iop_log_show, NULL);

/**
 ** pm8001_ctl_fatal_log_show - fatal error logging
 ** @cdev:pointer to embedded class device
 ** @attr: device attribute
 ** @buf: the buffer returned
 **
 ** A sysfs 'read-only' shost attribute.
 **/
 * pm8001_ctl_fatal_log_show - fatal error logging
 * @cdev:pointer to embedded class device
 * @attr: device attribute
 * @buf: the buffer returned
 *
 * A sysfs 'read-only' shost attribute.
 */

static ssize_t pm8001_ctl_fatal_log_show(struct device *cdev,
	struct device_attribute *attr, char *buf)
@@ -575,13 +578,13 @@ static ssize_t pm8001_ctl_fatal_log_show(struct device *cdev,
static DEVICE_ATTR(fatal_log, S_IRUGO, pm8001_ctl_fatal_log_show, NULL);

/**
 ** non_fatal_log_show - non fatal error logging
 ** @cdev:pointer to embedded class device
 ** @attr: device attribute
 ** @buf: the buffer returned
 **
 ** A sysfs 'read-only' shost attribute.
 **/
 * non_fatal_log_show - non fatal error logging
 * @cdev:pointer to embedded class device
 * @attr: device attribute
 * @buf: the buffer returned
 *
 * A sysfs 'read-only' shost attribute.
 */
static ssize_t non_fatal_log_show(struct device *cdev,
	struct device_attribute *attr, char *buf)
{
@@ -620,12 +623,13 @@ static ssize_t non_fatal_count_store(struct device *cdev,
static DEVICE_ATTR_RW(non_fatal_count);

/**
 ** pm8001_ctl_gsm_log_show - gsm dump collection
 ** @cdev:pointer to embedded class device
 ** @attr: device attribute (unused)
 ** @buf: the buffer returned
 ** A sysfs 'read-only' shost attribute.
 **/
 * pm8001_ctl_gsm_log_show - gsm dump collection
 * @cdev:pointer to embedded class device
 * @attr: device attribute (unused)
 * @buf: the buffer returned
 *
 * A sysfs 'read-only' shost attribute.
 */
static ssize_t pm8001_ctl_gsm_log_show(struct device *cdev,
	struct device_attribute *attr, char *buf)
{
Loading