Commit dfdf16ec authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull SCSI updates from James Bottomley:
 "This consists of the usual driver updates (ufs, qla2xxx, tcmu, lpfc,
  hpsa, zfcp, scsi_debug) and minor bug fixes.

  We also have a huge docbook fix update like most other subsystems and
  no major update to the core (the few non trivial updates are either
  minor fixes or removing an unused feature [scsi_sdb_cache])"

* tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: (307 commits)
  scsi: scsi_transport_srp: Sanitize scsi_target_block/unblock sequences
  scsi: ufs-mediatek: Apply DELAY_AFTER_LPM quirk to Micron devices
  scsi: ufs: Introduce device quirk "DELAY_AFTER_LPM"
  scsi: virtio-scsi: Correctly handle the case where all LUNs are unplugged
  scsi: scsi_debug: Implement tur_ms_to_ready parameter
  scsi: scsi_debug: Fix request sense
  scsi: lpfc: Fix typo in comment for ULP
  scsi: ufs-mediatek: Prevent LPM operation on undeclared VCC
  scsi: iscsi: Do not put host in iscsi_set_flashnode_param()
  scsi: hpsa: Correct ctrl queue depth
  scsi: target: tcmu: Make TMR notification optional
  scsi: target: tcmu: Implement tmr_notify callback
  scsi: target: tcmu: Fix and simplify timeout handling
  scsi: target: tcmu: Factor out new helper ring_insert_padding
  scsi: target: tcmu: Do not queue aborted commands
  scsi: target: tcmu: Use priv pointer in se_cmd
  scsi: target: Add tmr_notify backend function
  scsi: target: Modify core_tmr_abort_task()
  scsi: target: iscsi: Fix inconsistent debug message
  scsi: target: iscsi: Fix login error when receiving
  ...
parents d7806bbd bf1a28f9
Loading
Loading
Loading
Loading
+136 −0
Original line number Diff line number Diff line
@@ -883,3 +883,139 @@ Contact: Subhash Jadavani <subhashj@codeaurora.org>
Description:	This entry shows the target state of an UFS UIC link
		for the chosen system power management level.
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/device_descriptor/wb_presv_us_en
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows if preserve user-space was configured
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/device_descriptor/wb_shared_alloc_units
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows the shared allocated units of WB buffer
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/device_descriptor/wb_type
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows the configured WB type.
		0x1 for shared buffer mode. 0x0 for dedicated buffer mode.
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/geometry_descriptor/wb_buff_cap_adj
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows the total user-space decrease in shared
		buffer mode.
		The value of this parameter is 3 for TLC NAND when SLC mode
		is used as WriteBooster Buffer. 2 for MLC NAND.
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/geometry_descriptor/wb_max_alloc_units
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows the Maximum total WriteBooster Buffer size
		which is supported by the entire device.
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/geometry_descriptor/wb_max_wb_luns
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows the maximum number of luns that can support
		WriteBooster.
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/geometry_descriptor/wb_sup_red_type
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	The supportability of user space reduction mode
		and preserve user space mode.
		00h: WriteBooster Buffer can be configured only in
		user space reduction type.
		01h: WriteBooster Buffer can be configured only in
		preserve user space type.
		02h: Device can be configured in either user space
		reduction type or preserve user space type.
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/geometry_descriptor/wb_sup_wb_type
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	The supportability of WriteBooster Buffer type.
		00h: LU based WriteBooster Buffer configuration
		01h: Single shared WriteBooster Buffer
		configuration
		02h: Supporting both LU based WriteBooster
		Buffer and Single shared WriteBooster Buffer
		configuration
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/flags/wb_enable
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows the status of WriteBooster.
		0: WriteBooster is not enabled.
		1: WriteBooster is enabled
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/flags/wb_flush_en
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows if flush is enabled.
		0: Flush operation is not performed.
		1: Flush operation is performed.
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/flags/wb_flush_during_h8
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	Flush WriteBooster Buffer during hibernate state.
		0: Device is not allowed to flush the
		WriteBooster Buffer during link hibernate
		state.
		1: Device is allowed to flush the
		WriteBooster Buffer during link hibernate
		state
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/attributes/wb_avail_buf
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows the amount of unused WriteBooster buffer
		available.
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/attributes/wb_cur_buf
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows the amount of unused current buffer.
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/attributes/wb_flush_status
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows the flush operation status.
		00h: idle
		01h: Flush operation in progress
		02h: Flush operation stopped prematurely.
		03h: Flush operation completed successfully
		04h: Flush operation general failure
		The file is read only.

What:		/sys/bus/platform/drivers/ufshcd/*/attributes/wb_life_time_est
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows an indication of the WriteBooster Buffer
		lifetime based on the amount of performed program/erase cycles
		01h: 0% - 10% WriteBooster Buffer life time used
		...
		0Ah: 90% - 100% WriteBooster Buffer life time used
		The file is read only.

What:		/sys/class/scsi_device/*/device/unit_descriptor/wb_buf_alloc_units
Date:		June 2020
Contact:	Asutosh Das <asutoshd@codeaurora.org>
Description:	This entry shows the configured size of WriteBooster buffer.
		0400h corresponds to 4GB.
		The file is read only.
+1 −1
Original line number Diff line number Diff line
@@ -125,7 +125,7 @@ The following constants can be defined in the source file.
   c. klogd is started with the appropriate -c parameter
      (e.g. klogd -c 8)

   This will cause printk() messages to be be displayed on the
   This will cause printk() messages to be displayed on the
   current console. Refer to the klogd(8) and syslogd(8) man pages
   for details.

+1 −1
Original line number Diff line number Diff line
@@ -94,7 +94,7 @@ parameters may be changed at runtime by the command
			(/proc/sys/dev/scsi/logging_level).
			There is also a nice 'scsi_logging_level' script in the
			S390-tools package, available for download at
			http://www-128.ibm.com/developerworks/linux/linux390/s390-tools-1.5.4.html
			https://github.com/ibm-s390-tools/s390-tools/blob/master/scripts/scsi_logging_level

	scsi_mod.scan=	[SCSI] sync (default) scans SCSI busses as they are
			discovered.  async scans them in kernel threads,
+1 −1
Original line number Diff line number Diff line
@@ -2309,7 +2309,7 @@ F: drivers/pci/controller/dwc/pcie-qcom.c
F:	drivers/phy/qualcomm/
F:	drivers/power/*/msm*
F:	drivers/reset/reset-qcom-*
F:	drivers/scsi/ufs/ufs-qcom.*
F:	drivers/scsi/ufs/ufs-qcom*
F:	drivers/spi/spi-geni-qcom.c
F:	drivers/spi/spi-qcom-qspi.c
F:	drivers/spi/spi-qup.c
+22 −19
Original line number Diff line number Diff line
@@ -164,9 +164,8 @@ EXPORT_SYMBOL(blk_pre_runtime_resume);
 *
 * Description:
 *    Update the queue's runtime status according to the return value of the
 *    device's runtime_resume function. If it is successfully resumed, process
 *    the requests that are queued into the device's queue when it is resuming
 *    and then mark last busy and initiate autosuspend for it.
 *    device's runtime_resume function. If the resume was successful, call
 *    blk_set_runtime_active() to do the real work of restarting the queue.
 *
 *    This function should be called near the end of the device's
 *    runtime_resume callback.
@@ -175,19 +174,13 @@ void blk_post_runtime_resume(struct request_queue *q, int err)
{
	if (!q->dev)
		return;

	spin_lock_irq(&q->queue_lock);
	if (!err) {
		q->rpm_status = RPM_ACTIVE;
		pm_runtime_mark_last_busy(q->dev);
		pm_request_autosuspend(q->dev);
		blk_set_runtime_active(q);
	} else {
		spin_lock_irq(&q->queue_lock);
		q->rpm_status = RPM_SUSPENDED;
	}
		spin_unlock_irq(&q->queue_lock);

	if (!err)
		blk_clear_pm_only(q);
	}
}
EXPORT_SYMBOL(blk_post_runtime_resume);

@@ -204,15 +197,25 @@ EXPORT_SYMBOL(blk_post_runtime_resume);
 * This function can be used in driver's resume hook to correct queue
 * runtime PM status and re-enable peeking requests from the queue. It
 * should be called before first request is added to the queue.
 *
 * This function is also called by blk_post_runtime_resume() for successful
 * runtime resumes.  It does everything necessary to restart the queue.
 */
void blk_set_runtime_active(struct request_queue *q)
{
	if (q->dev) {
	int old_status;

	if (!q->dev)
		return;

	spin_lock_irq(&q->queue_lock);
	old_status = q->rpm_status;
	q->rpm_status = RPM_ACTIVE;
	pm_runtime_mark_last_busy(q->dev);
	pm_request_autosuspend(q->dev);
	spin_unlock_irq(&q->queue_lock);
	}

	if (old_status != RPM_ACTIVE)
		blk_clear_pm_only(q);
}
EXPORT_SYMBOL(blk_set_runtime_active);
Loading