U-Boot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mmc: mediatek: set b_max according CONFIG_SYS_MMC_MAX_BLK_COUNT
@ 2023-12-04 13:41 Julien Masson
  2023-12-19 17:46 ` Tom Rini
  0 siblings, 1 reply; 2+ messages in thread
From: Julien Masson @ 2023-12-04 13:41 UTC (permalink / raw)
  To: u-boot
  Cc: GSS_MTK_Uboot_upstream, Jaehoon Chung, Peng Fan, Chunfeng Yun,
	Weijie Gao, Ryder Lee

The block count limit on MMC based devices should be set according to
CONFIG_SYS_MMC_MAX_BLK_COUNT instead of hardcoding value.

Signed-off-by: Julien Masson <jmasson@baylibre.com>
---
 drivers/mmc/mtk-sd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/mtk-sd.c b/drivers/mmc/mtk-sd.c
index d21a30c954..5a0c61daed 100644
--- a/drivers/mmc/mtk-sd.c
+++ b/drivers/mmc/mtk-sd.c
@@ -1665,7 +1665,7 @@ static int msdc_drv_probe(struct udevice *dev)
 	if (cfg->f_max < cfg->f_min || cfg->f_max > host->src_clk_freq)
 		cfg->f_max = host->src_clk_freq;
 
-	cfg->b_max = 1024;
+	cfg->b_max = CONFIG_SYS_MMC_MAX_BLK_COUNT;
 	cfg->voltages = MMC_VDD_32_33 | MMC_VDD_33_34;
 
 	host->mmc = &plat->mmc;
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] mmc: mediatek: set b_max according CONFIG_SYS_MMC_MAX_BLK_COUNT
  2023-12-04 13:41 [PATCH] mmc: mediatek: set b_max according CONFIG_SYS_MMC_MAX_BLK_COUNT Julien Masson
@ 2023-12-19 17:46 ` Tom Rini
  0 siblings, 0 replies; 2+ messages in thread
From: Tom Rini @ 2023-12-19 17:46 UTC (permalink / raw)
  To: Julien Masson
  Cc: u-boot, GSS_MTK_Uboot_upstream, Jaehoon Chung, Peng Fan,
	Chunfeng Yun, Weijie Gao, Ryder Lee

[-- Attachment #1: Type: text/plain, Size: 306 bytes --]

On Mon, Dec 04, 2023 at 02:41:45PM +0100, Julien Masson wrote:

> The block count limit on MMC based devices should be set according to
> CONFIG_SYS_MMC_MAX_BLK_COUNT instead of hardcoding value.
> 
> Signed-off-by: Julien Masson <jmasson@baylibre.com>

Applied to u-boot/next, thanks!

-- 
Tom

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-12-19 17:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-12-04 13:41 [PATCH] mmc: mediatek: set b_max according CONFIG_SYS_MMC_MAX_BLK_COUNT Julien Masson
2023-12-19 17:46 ` Tom Rini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox