Skip to content

Commit

Permalink
Merge tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/gi…
Browse files Browse the repository at this point in the history
…t/jejb/scsi

Pull SCSI updates from James Bottomley:
 "Updates to the usual drivers (scsi_debug, ufs, lpfc, st, fnic, mpi3mr,
  mpt3sas) and the removal of cxlflash.

  The only non-trivial core change is an addition to unit attention
  handling to recognize UAs for power on/reset and new media so the tape
  driver can use it"

* tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: (107 commits)
  scsi: st: Tighten the page format heuristics with MODE SELECT
  scsi: st: ERASE does not change tape location
  scsi: st: Fix array overflow in st_setup()
  scsi: target: tcm_loop: Fix wrong abort tag
  scsi: lpfc: Restore clearing of NLP_UNREG_INP in ndlp->nlp_flag
  scsi: hisi_sas: Fixed failure to issue vendor specific commands
  scsi: fnic: Remove unnecessary NUL-terminations
  scsi: fnic: Remove redundant flush_workqueue() calls
  scsi: core: Use a switch statement when attaching VPD pages
  scsi: ufs: renesas: Add initialization code for R-Car S4-8 ES1.2
  scsi: ufs: renesas: Add reusable functions
  scsi: ufs: renesas: Refactor 0x10ad/0x10af PHY settings
  scsi: ufs: renesas: Remove register control helper function
  scsi: ufs: renesas: Add register read to remove save/set/restore
  scsi: ufs: renesas: Replace init data by init code
  scsi: ufs: dt-bindings: renesas,ufs: Add calibration data
  scsi: mpi3mr: Task Abort EH Support
  scsi: storvsc: Don't report the host packet status as the hv status
  scsi: isci: Make most module parameters static
  scsi: megaraid_sas: Make most module parameters static
  ...
  • Loading branch information
Linus Torvalds committed Mar 27, 2025
2 parents 2209399 + 8db816c commit 2e3fcbc
Show file tree
Hide file tree
Showing 126 changed files with 3,510 additions and 12,679 deletions.
45 changes: 45 additions & 0 deletions Documentation/ABI/testing/sysfs-driver-ufs
Original file line number Diff line number Diff line change
Expand Up @@ -1559,3 +1559,48 @@ Description:
Symbol - HCMID. This file shows the UFSHCD manufacturer id.
The Manufacturer ID is defined by JEDEC in JEDEC-JEP106.
The file is read only.

What: /sys/bus/platform/drivers/ufshcd/*/critical_health
What: /sys/bus/platform/devices/*.ufs/critical_health
Date: February 2025
Contact: Avri Altman <avri.altman@wdc.com>
Description: Report the number of times a critical health event has been
reported by a UFS device. Further insight into the specific
issue can be gained by reading one of: bPreEOLInfo,
bDeviceLifeTimeEstA, bDeviceLifeTimeEstB,
bWriteBoosterBufferLifeTimeEst, and bRPMBLifeTimeEst.

The file is read only.

What: /sys/bus/platform/drivers/ufshcd/*/clkscale_enable
What: /sys/bus/platform/devices/*.ufs/clkscale_enable
Date: January 2025
Contact: Ziqi Chen <quic_ziqichen@quicinc.com>
Description:
This attribute shows whether the UFS clock scaling is enabled or not.
And it can be used to enable/disable the clock scaling by writing
1 or 0 to this attribute.

The attribute is read/write.

What: /sys/bus/platform/drivers/ufshcd/*/clkgate_enable
What: /sys/bus/platform/devices/*.ufs/clkgate_enable
Date: January 2025
Contact: Ziqi Chen <quic_ziqichen@quicinc.com>
Description:
This attribute shows whether the UFS clock gating is enabled or not.
And it can be used to enable/disable the clock gating by writing
1 or 0 to this attribute.

The attribute is read/write.

What: /sys/bus/platform/drivers/ufshcd/*/clkgate_delay_ms
What: /sys/bus/platform/devices/*.ufs/clkgate_delay_ms
Date: January 2025
Contact: Ziqi Chen <quic_ziqichen@quicinc.com>
Description:
This attribute shows and sets the number of milliseconds of idle time
before the UFS driver starts to perform clock gating. This can
prevent the UFS from frequently performing clock gating/ungating.

The attribute is read/write.
433 changes: 0 additions & 433 deletions Documentation/arch/powerpc/cxlflash.rst

This file was deleted.

1 change: 0 additions & 1 deletion Documentation/arch/powerpc/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ powerpc
cpu_families
cpu_features
cxl
cxlflash
dawr-power9
dexcr
dscr
Expand Down
12 changes: 12 additions & 0 deletions Documentation/devicetree/bindings/ufs/renesas,ufs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,16 @@ properties:
resets:
maxItems: 1

nvmem-cells:
maxItems: 1

nvmem-cell-names:
items:
- const: calibration

dependencies:
nvmem-cells: [ nvmem-cell-names ]

required:
- compatible
- reg
Expand All @@ -58,4 +68,6 @@ examples:
freq-table-hz = <200000000 200000000>, <38400000 38400000>;
power-domains = <&sysc R8A779F0_PD_ALWAYS_ON>;
resets = <&cpg 1514>;
nvmem-cells = <&ufs_tune>;
nvmem-cell-names = "calibration";
};
105 changes: 105 additions & 0 deletions Documentation/devicetree/bindings/ufs/rockchip,rk3576-ufshc.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/ufs/rockchip,rk3576-ufshc.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Rockchip UFS Host Controller

maintainers:
- Shawn Lin <shawn.lin@rock-chips.com>

allOf:
- $ref: ufs-common.yaml

properties:
compatible:
const: rockchip,rk3576-ufshc

reg:
maxItems: 5

reg-names:
items:
- const: hci
- const: mphy
- const: hci_grf
- const: mphy_grf
- const: hci_apb

clocks:
maxItems: 4

clock-names:
items:
- const: core
- const: pclk
- const: pclk_mphy
- const: ref_out

power-domains:
maxItems: 1

resets:
maxItems: 4

reset-names:
items:
- const: biu
- const: sys
- const: ufs
- const: grf

reset-gpios:
maxItems: 1
description: |
GPIO specifiers for host to reset the whole UFS device including PHY and
memory. This gpio is active low and should choose the one whose high output
voltage is lower than 1.5V based on the UFS spec.
required:
- compatible
- reg
- reg-names
- clocks
- clock-names
- interrupts
- power-domains
- resets
- reset-names
- reset-gpios

unevaluatedProperties: false

examples:
- |
#include <dt-bindings/clock/rockchip,rk3576-cru.h>
#include <dt-bindings/reset/rockchip,rk3576-cru.h>
#include <dt-bindings/interrupt-controller/arm-gic.h>
#include <dt-bindings/power/rockchip,rk3576-power.h>
#include <dt-bindings/pinctrl/rockchip.h>
#include <dt-bindings/gpio/gpio.h>
soc {
#address-cells = <2>;
#size-cells = <2>;
ufshc: ufshc@2a2d0000 {
compatible = "rockchip,rk3576-ufshc";
reg = <0x0 0x2a2d0000 0x0 0x10000>,
<0x0 0x2b040000 0x0 0x10000>,
<0x0 0x2601f000 0x0 0x1000>,
<0x0 0x2603c000 0x0 0x1000>,
<0x0 0x2a2e0000 0x0 0x10000>;
reg-names = "hci", "mphy", "hci_grf", "mphy_grf", "hci_apb";
clocks = <&cru ACLK_UFS_SYS>, <&cru PCLK_USB_ROOT>, <&cru PCLK_MPHY>,
<&cru CLK_REF_UFS_CLKOUT>;
clock-names = "core", "pclk", "pclk_mphy", "ref_out";
interrupts = <GIC_SPI 361 IRQ_TYPE_LEVEL_HIGH>;
power-domains = <&power RK3576_PD_USB>;
resets = <&cru SRST_A_UFS_BIU>, <&cru SRST_A_UFS_SYS>, <&cru SRST_A_UFS>,
<&cru SRST_P_UFS_GRF>;
reset-names = "biu", "sys", "ufs", "grf";
reset-gpios = <&gpio4 RK_PD0 GPIO_ACTIVE_LOW>;
};
};
5 changes: 5 additions & 0 deletions Documentation/scsi/st.rst
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,11 @@ enabled driver and mode options. The value in the file is a bit mask where the
bit definitions are the same as those used with MTSETDRVBUFFER in setting the
options.

Each directory contains the entry 'position_lost_in_reset'. If this value is
one, reading and writing to the device is blocked after device reset. Most
devices rewind the tape after reset and the writes/read don't access the
tape position the user expects.

A link named 'tape' is made from the SCSI device directory to the class
directory corresponding to the mode 0 auto-rewind device (e.g., st0).

Expand Down
2 changes: 1 addition & 1 deletion Documentation/userspace-api/ioctl/ioctl-number.rst
Original file line number Diff line number Diff line change
Expand Up @@ -377,7 +377,7 @@ Code Seq# Include File Comments
0xC0 00-0F linux/usb/iowarrior.h
0xCA 00-0F uapi/misc/cxl.h
0xCA 10-2F uapi/misc/ocxl.h
0xCA 80-BF uapi/scsi/cxlflash_ioctl.h
0xCA 80-BF uapi/scsi/cxlflash_ioctl.h Dead since 6.14
0xCB 00-1F CBM serial IEC bus in development:
<mailto:michael.klein@puffin.lb.shuttle.de>
0xCC 00-0F drivers/misc/ibmvmc.h pseries VMC driver
Expand Down
9 changes: 0 additions & 9 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -6354,15 +6354,6 @@ F: drivers/misc/cxl/
F: include/misc/cxl*
F: include/uapi/misc/cxl.h

CXLFLASH (IBM Coherent Accelerator Processor Interface CAPI Flash) SCSI DRIVER
M: Manoj N. Kumar <manoj@linux.ibm.com>
M: Uma Krishnan <ukrishn@linux.ibm.com>
L: linux-scsi@vger.kernel.org
S: Obsolete
F: Documentation/arch/powerpc/cxlflash.rst
F: drivers/scsi/cxlflash/
F: include/uapi/scsi/cxlflash_ioctl.h

CYBERPRO FB DRIVER
M: Russell King <linux@armlinux.org.uk>
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
Expand Down
24 changes: 24 additions & 0 deletions arch/arm64/boot/dts/rockchip/rk3576.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -1221,6 +1221,30 @@
};
};

ufshc: ufshc@2a2d0000 {
compatible = "rockchip,rk3576-ufshc";
reg = <0x0 0x2a2d0000 0x0 0x10000>,
<0x0 0x2b040000 0x0 0x10000>,
<0x0 0x2601f000 0x0 0x1000>,
<0x0 0x2603c000 0x0 0x1000>,
<0x0 0x2a2e0000 0x0 0x10000>;
reg-names = "hci", "mphy", "hci_grf", "mphy_grf", "hci_apb";
clocks = <&cru ACLK_UFS_SYS>, <&cru PCLK_USB_ROOT>, <&cru PCLK_MPHY>,
<&cru CLK_REF_UFS_CLKOUT>;
clock-names = "core", "pclk", "pclk_mphy", "ref_out";
assigned-clocks = <&cru CLK_REF_OSC_MPHY>;
assigned-clock-parents = <&cru CLK_REF_MPHY_26M>;
interrupts = <GIC_SPI 361 IRQ_TYPE_LEVEL_HIGH>;
power-domains = <&power RK3576_PD_USB>;
pinctrl-0 = <&ufs_refclk>;
pinctrl-names = "default";
resets = <&cru SRST_A_UFS_BIU>, <&cru SRST_A_UFS_SYS>,
<&cru SRST_A_UFS>, <&cru SRST_P_UFS_GRF>;
reset-names = "biu", "sys", "ufs", "grf";
reset-gpios = <&gpio4 RK_PD0 GPIO_ACTIVE_LOW>;
status = "disabled";
};

sdmmc: mmc@2a310000 {
compatible = "rockchip,rk3576-dw-mshc";
reg = <0x0 0x2a310000 0x0 0x4000>;
Expand Down
64 changes: 2 additions & 62 deletions drivers/message/fusion/mptscsih.c
Original file line number Diff line number Diff line change
Expand Up @@ -1843,65 +1843,6 @@ mptscsih_dev_reset(struct scsi_cmnd * SCpnt)
return FAILED;
}

/*=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=*/
/**
* mptscsih_target_reset - Perform a SCSI TARGET_RESET!
* @SCpnt: Pointer to scsi_cmnd structure, IO which reset is due to
*
* (linux scsi_host_template.eh_target_reset_handler routine)
*
* Returns SUCCESS or FAILED.
**/
int
mptscsih_target_reset(struct scsi_cmnd * SCpnt)
{
MPT_SCSI_HOST *hd;
int retval;
VirtDevice *vdevice;
MPT_ADAPTER *ioc;

/* If we can't locate our host adapter structure, return FAILED status.
*/
if ((hd = shost_priv(SCpnt->device->host)) == NULL){
printk(KERN_ERR MYNAM ": target reset: "
"Can't locate host! (sc=%p)\n", SCpnt);
return FAILED;
}

ioc = hd->ioc;
printk(MYIOC_s_INFO_FMT "attempting target reset! (sc=%p)\n",
ioc->name, SCpnt);
scsi_print_command(SCpnt);

vdevice = SCpnt->device->hostdata;
if (!vdevice || !vdevice->vtarget) {
retval = 0;
goto out;
}

/* Target reset to hidden raid component is not supported
*/
if (vdevice->vtarget->tflags & MPT_TARGET_FLAGS_RAID_COMPONENT) {
retval = FAILED;
goto out;
}

retval = mptscsih_IssueTaskMgmt(hd,
MPI_SCSITASKMGMT_TASKTYPE_TARGET_RESET,
vdevice->vtarget->channel,
vdevice->vtarget->id, 0, 0,
mptscsih_get_tm_timeout(ioc));

out:
printk (MYIOC_s_INFO_FMT "target reset: %s (sc=%p)\n",
ioc->name, ((retval == 0) ? "SUCCESS" : "FAILED" ), SCpnt);

if (retval == 0)
return SUCCESS;
else
return FAILED;
}


/*=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=*/
/**
Expand Down Expand Up @@ -2915,14 +2856,14 @@ mptscsih_do_cmd(MPT_SCSI_HOST *hd, INTERNAL_CMD *io)
timeout = 10;
break;

case RESERVE:
case RESERVE_6:
cmdLen = 6;
dir = MPI_SCSIIO_CONTROL_READ;
CDB[0] = cmd;
timeout = 10;
break;

case RELEASE:
case RELEASE_6:
cmdLen = 6;
dir = MPI_SCSIIO_CONTROL_READ;
CDB[0] = cmd;
Expand Down Expand Up @@ -3306,7 +3247,6 @@ EXPORT_SYMBOL(mptscsih_sdev_destroy);
EXPORT_SYMBOL(mptscsih_sdev_configure);
EXPORT_SYMBOL(mptscsih_abort);
EXPORT_SYMBOL(mptscsih_dev_reset);
EXPORT_SYMBOL(mptscsih_target_reset);
EXPORT_SYMBOL(mptscsih_bus_reset);
EXPORT_SYMBOL(mptscsih_host_reset);
EXPORT_SYMBOL(mptscsih_bios_param);
Expand Down
1 change: 0 additions & 1 deletion drivers/message/fusion/mptscsih.h
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,6 @@ extern int mptscsih_sdev_configure(struct scsi_device *device,
struct queue_limits *lim);
extern int mptscsih_abort(struct scsi_cmnd * SCpnt);
extern int mptscsih_dev_reset(struct scsi_cmnd * SCpnt);
extern int mptscsih_target_reset(struct scsi_cmnd * SCpnt);
extern int mptscsih_bus_reset(struct scsi_cmnd * SCpnt);
extern int mptscsih_host_reset(struct scsi_cmnd *SCpnt);
extern int mptscsih_bios_param(struct scsi_device * sdev, struct block_device *bdev, sector_t capacity, int geom[]);
Expand Down
3 changes: 1 addition & 2 deletions drivers/scsi/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -303,9 +303,9 @@ if SCSI_LOWLEVEL && SCSI
config ISCSI_TCP
tristate "iSCSI Initiator over TCP/IP"
depends on SCSI && INET
select CRC32
select CRYPTO
select CRYPTO_MD5
select CRYPTO_CRC32C
select SCSI_ISCSI_ATTRS
help
The iSCSI Driver provides a host with the ability to access storage
Expand Down Expand Up @@ -336,7 +336,6 @@ source "drivers/scsi/cxgbi/Kconfig"
source "drivers/scsi/bnx2i/Kconfig"
source "drivers/scsi/bnx2fc/Kconfig"
source "drivers/scsi/be2iscsi/Kconfig"
source "drivers/scsi/cxlflash/Kconfig"

config SGIWD93_SCSI
tristate "SGI WD93C93 SCSI Driver"
Expand Down
1 change: 0 additions & 1 deletion drivers/scsi/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ obj-$(CONFIG_SCSI_SYM53C8XX_2) += sym53c8xx_2/
obj-$(CONFIG_SCSI_ZALON) += zalon7xx.o
obj-$(CONFIG_SCSI_DC395x) += dc395x.o
obj-$(CONFIG_SCSI_AM53C974) += esp_scsi.o am53c974.o
obj-$(CONFIG_CXLFLASH) += cxlflash/
obj-$(CONFIG_MEGARAID_LEGACY) += megaraid.o
obj-$(CONFIG_MEGARAID_NEWGEN) += megaraid/
obj-$(CONFIG_MEGARAID_SAS) += megaraid/
Expand Down
4 changes: 2 additions & 2 deletions drivers/scsi/aacraid/aachba.c
Original file line number Diff line number Diff line change
Expand Up @@ -3221,8 +3221,8 @@ int aac_scsi_cmd(struct scsi_cmnd * scsicmd)
break;
}
fallthrough;
case RESERVE:
case RELEASE:
case RESERVE_6:
case RELEASE_6:
case REZERO_UNIT:
case REASSIGN_BLOCKS:
case SEEK_10:
Expand Down
Loading

0 comments on commit 2e3fcbc

Please sign in to comment.