Commit 9b8b84879d4a ("block: Increase BLK_DEF_MAX_SECTORS_CAP") increased the default max_sectors_kb from 1280 KiB to 4096 KiB. INTEL SSDSC2KB480G8 with FW rev XCV10120 times out when sending I/Os of size 4096 KiB: ata1.00: exception Emask 0x0 SAct 0x7fdcf806 SErr 0x0 action 0x6 frozen ata1.00: failed command: READ FPDMA QUEUED ata1.00: cmd 60/00:08:00:70:5c/20:00:01:00:00/40 tag 1 ncq dma 4194304 in res ... Emask 0x4 (timeout) ata1: hard resetting link INTEL SSDSC2KG480G8 with the same FW rev has the same problem, and is already quirked with ATA_QUIRK_MAX_SEC, with value 8191 (sectors). Instead of adding new entries, extend the existing SSDSC2KG480G8 entries to also match the SSDSC2KB480G8. The SSDSC2KB480G8 keeps ATA_QUIRK_ZERO_AFTER_TRIM, which it previously got from the "INTEL*SSD*" entry. Reported-by: keyborad hero Closes: https://lore.kernel.org/linux-ide/CA+Yw5V+C-Ok0OHWV-9AfbSf+EejH54Z=0aSQgmmcGKjie5KM6w@mail.gmail.com/ Fixes: 9b8b84879d4a ("block: Increase BLK_DEF_MAX_SECTORS_CAP") Cc: stable@vger.kernel.org Signed-off-by: Niklas Cassel --- drivers/ata/libata-core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index d234c83e0463..cf574da88c7d 100644 --- a/drivers/ata/libata-core.c +++ b/drivers/ata/libata-core.c @@ -4203,7 +4203,7 @@ static const struct ata_dev_quirk_value __ata_dev_max_sec_quirks[] = { { "LITEON CX1-JB*-HP", NULL, 1024 }, { "LITEON EP1-*", NULL, 1024 }, { "DELLBOSS VD", "MV.R00-0", 8191 }, - { "INTEL SSDSC2KG480G8", "XCV10120", 8191 }, + { "INTEL SSDSC2K[BG]480G8", "XCV10120", 8191 }, { "INTEL SSDSCKKB240G8", "XC311102", 8191 }, { }, }; @@ -4472,7 +4472,7 @@ static const struct ata_dev_quirks_entry __ata_dev_quirks[] = { { "Micron*", NULL, ATA_QUIRK_ZERO_AFTER_TRIM }, { "Crucial*", NULL, ATA_QUIRK_ZERO_AFTER_TRIM }, - { "INTEL SSDSC2KG480G8", "XCV10120", ATA_QUIRK_ZERO_AFTER_TRIM | + { "INTEL SSDSC2K[BG]480G8", "XCV10120", ATA_QUIRK_ZERO_AFTER_TRIM | ATA_QUIRK_MAX_SEC }, { "INTEL*SSDSC2CT*", NULL, ATA_QUIRK_ZERO_AFTER_TRIM | ATA_QUIRK_NO_FUA }, -- 2.56.1