Skip to contentSkip to conversation

ata fixes for 7.4-rc2

GIT PULL Merged Niklas Cassel 2 participants 2 messages Nov 8 libata

lore
Share & tools
lore

Niklas Cassel

author maintainer
#0 lore raw

Linus,

The following changes since commit 6628e7d4c6b25c8d18f1345e3a20d21829aae7e4:

Linux 7.4-rc1 (2026-11-01 13:26:31 -0800)

are available in the Git repository at:

git://git.kernel.org/pub/scm/linux/kernel/git/libata/linux tags/ata-7.4-rc2

for you to fetch changes up to a4845f077415ef32fe672c841e2fc58ae9e28273:

ata: libata-scsi: reject data-in commands with a data-out buffer (2026-11-07 14:35:25 +0100)

----------------------------------------------------------------
ata fixes for 7.4-rc2

- Allow re-enabling NCQ, after EH disabled it, by writing the current queue depth to the queue_depth sysfs attribute (Igor)

- Retry failed non-NCQ commands when their sense data asks for a retry, as is already done for NCQ commands. Previously, such non-NCQ commands were never retried (me)

- Only check the power mode of ATA and ZAC devices before putting them in standby mode (on suspend, shutdown or device removal). libata never puts other devices, such as ATAPI devices, in standby mode, and some ATAPI devices reject the CHECK POWER MODE command (Giuseppe)

- Fix several bugs in the MODE SELECT translation.

Reject parameter lists with data after the mode page before the mode page is handled. Previously, a rejected command could leave the CDL enabled state tracked by libata out of sync with the device, and data after the control mode page was silently ignored.

Reject mode pages with SUBPAGE CODE FFh, and mode pages with the SPF bit set but SUBPAGE CODE 00h, which were incorrectly accepted.

The commit that passes the whole mode page to the MODE SELECT handlers might look like a cleanup, but it is a fix, and thus has a Fixes tag: the FIELD POINTER pointed 2 bytes (page_0 format) or 4 bytes (sub_page format) before the invalid byte in the mode page (me, Shao)

- Disable the enclosure management (SEMB) port of the Marvell 88SM9705 port multiplier. The port never answers SRST, and the resulting EH retries delayed disk discovery by minutes (Marco)

- Reject data-in commands, e.g. INQUIRY, submitted via SG_IO with a data-out buffer, whose pages may be pinned without write access. Writing a reply to such a buffer could oops the kernel (Zhao)

----------------------------------------------------------------
Giuseppe Piscitelli (1):
ata: libata-core: Check device support before querying power state

Igor Pylypiv (1):
ata: libata-sata: allow re-enabling NCQ with the same queue_depth

Marco Ziliani (1):
ata: libata-pmp: disable the SEMB port on Marvell 88SM9705

Niklas Cassel (7):
ata: libata-eh: Retry non-NCQ commands when their sense data asks for it
ata: libata-scsi: fix MODE SELECT handling of data after the mode page
ata: libata-scsi: do not accept subpage code FFh in MODE SELECT
ata: libata-scsi: reject MODE SELECT mode pages with a wrong SPF bit
ata: libata-scsi: fix MODE SELECT field pointer for unsupported subpages
ata: libata-scsi: fix MODE SELECT field pointer for block descriptor length
ata: libata-scsi: pass the whole mode page to the MODE SELECT handlers

Shao Mingyin (1):
ata: libata-scsi: set the field pointer when rejecting CDL

Zhao Gongyi (1):
ata: libata-scsi: reject data-in commands with a data-out buffer

 drivers/ata/libata-core.c |   8 +-
 drivers/ata/libata-eh.c   |  16 +++-
 drivers/ata/libata-pmp.c  |  14 ++++
 drivers/ata/libata-sata.c |   2 +-
 drivers/ata/libata-scsi.c | 206 ++++++++++++++++++++++++++++++----------------
 5 files changed, 168 insertions(+), 78 deletions(-)