[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#1006149: linux-image-5.16.0-1-686: Fails to boot on T41 Thinkpads



On 4/4/22 14:24, Damien Le Moal wrote:
On 4/4/22 14:13, Damien Le Moal wrote:
On 4/4/22 14:09, Axel Beckert wrote:
Hi Damien,

Damien Le Moal wrote:
My hunch is that this drive simply reacts badly to read log commands
and should be marked with a horkage to blacklist that command for
it.

Hrm, do really mean drive or controller? If you really mean "drive",
shall all who are affected by this send in all the affected HDD's
details? (Taking Petra back into Cc for that.)

I mean drive. Nothing new here. There are plenty of drives like that :)

Actually, there is a possibility that this is the controller that needs to have ATA_FLAG_NO_LOG_PAGE flag set. This is rare though. Only one controller has this flag today (sata_fsl).

Your tests using the sg_sat_read_gplog command showed that the drive or adapter definitely does not support READ LOG DMA EXT, so we can already add ATA_HORKAGE_NO_DMA_LOG for the "SAMSUNG HM160HC" drive.

If that is not enough, then we will need to add ATA_HORKAGE_NO_LOG_DIR which will disable all READ LOG EXT commands, or ATA_FLAG_NO_LOG_PAGE for the adapter. However, since running sg_sat_read_gplog did not seem to have locked up the adapter, I suspect the adapter itself is fine.

Can you try the attached patch please ?


--
Damien Le Moal
Western Digital Research
From 6cdebc7ed7c9db6b4ccc6ac164f0acf4da298bec Mon Sep 17 00:00:00 2001
From: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Date: Mon, 4 Apr 2022 14:33:04 +0900
Subject: [PATCH] ata: libata-core: Disable log page access with SAMSUNG
 HM160HC drives

Samsung HM160HC drives seem to react badly to log page accesses during
boot device scan. Disable all log page access using the
ATA_HORKAGE_NO_LOG_DIR horkage flag. This does not have any effect on
functionallities as this drive does not support any log page beside the
general log directory page.

Signed-off-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>
---
 drivers/ata/libata-core.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index cceedde51126..cc3c9fbb4c1f 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -4082,6 +4082,13 @@ static const struct ata_blacklist_entry ata_device_blacklist [] = {
 	 */
 	{ "SATADOM-ML 3ME",		NULL,	ATA_HORKAGE_NO_LOG_DIR },
 
+	/*
+	 * Other drives that react badly to accessing the log directory or log
+	 * pages. For these, disable all accesses to the the log directory page.
+	 * This also disables accesses to all log pages of the device.
+	 */
+	{ "SAMSUNG*HM160HC*",		NULL,	ATA_HORKAGE_NO_LOG_DIR },
+
 	/* End Marker */
 	{ }
 };
-- 
2.35.1


Reply to: