lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250324192116.1756281-1-erick.shepherd@ni.com>
Date: Mon, 24 Mar 2025 14:21:16 -0500
From: Erick Shepherd <erick.shepherd@...com>
To: <ulf.hansson@...aro.org>
CC: <adrian.hunter@...el.com>, <andy-ld.lu@...iatek.com>,
        <avri.altman@....com>, <dsimic@...jaro.org>, <erick.shepherd@...com>,
        <jason.lai@...esyslogic.com.tw>, <jeff.johnson@....qualcomm.com>,
        <jonathan@...pberrypi.com>, <keita.aihara@...y.com>,
        <linux-kernel@...r.kernel.org>, <linux-mmc@...r.kernel.org>,
        <victor.shih@...esyslogic.com.tw>, <wsa+renesas@...g-engineering.com>
Subject: Re: [PATCH] mmc: Add quirk to disable DDR50 tuning

> Please move this to mmc_sd_init_uhs_card() instead. Moreover, please
> add a helper in drivers/mmc/core/card.h for
> MMC_QUIRK_NO_UHS_DDR50_TUNING, similar to other quirks.

Sorry for the late response, how does this look? I can change the
MMC_QUIRK_NO_UHS_DDR50_TUNING check to be before the tuning
if-statement instead of within it if that seems more appropriate.

--- a/drivers/mmc/core/card.h
+++ b/drivers/mmc/core/card.h
@@ -89,6 +89,7 @@ struct mmc_fixup {
 #define CID_MANFID_MICRON       0x13
 #define CID_MANFID_SAMSUNG      0x15
 #define CID_MANFID_APACER       0x27
+#define CID_MANFID_SWISSBIT     0x5D
 #define CID_MANFID_KINGSTON     0x70
 #define CID_MANFID_HYNIX	0x90
 #define CID_MANFID_KINGSTON_SD	0x9F
@@ -294,4 +295,9 @@ static inline int mmc_card_broken_sd_poweroff_notify(const struct mmc_card *c)
 	return c->quirks & MMC_QUIRK_BROKEN_SD_POWEROFF_NOTIFY;
 }
 
+static inline int mmc_card_no_uhs_ddr50_tuning(const struct mmc_card *c)
+{
+	return c->quirks & MMC_QUIRK_NO_UHS_DDR50_TUNING;
+}
+

--- a/drivers/mmc/core/sd.c
+++ b/drivers/mmc/core/sd.c
@@ -664,6 +664,10 @@ static int mmc_sd_init_uhs_card(struct mmc_card *card)
	if (!mmc_host_is_spi(card->host) &&
 		(card->host->ios.timing == MMC_TIMING_UHS_SDR50 ||
 		 card->host->ios.timing == MMC_TIMING_UHS_DDR50 ||
 		 card->host->ios.timing == MMC_TIMING_UHS_SDR104)) {
+		if ((card->quirks & MMC_QUIRK_NO_UHS_DDR50_TUNING) &&
+		    card->host->ios.timing == MMC_TIMING_UHS_DDR50)
+			goto out;
+
 		err = mmc_execute_tuning(card);
 
 		/*

Regards,
Erick

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ