{"id":2225745,"url":"http://patchwork.ozlabs.org/api/1.1/patches/2225745/?format=json","web_url":"http://patchwork.ozlabs.org/project/uboot/patch/20260421-mmc-mtk-sd-fixes-v1-3-5b840c546af2@baylibre.com/","project":{"id":18,"url":"http://patchwork.ozlabs.org/api/1.1/projects/18/?format=json","name":"U-Boot","link_name":"uboot","list_id":"u-boot.lists.denx.de","list_email":"u-boot@lists.denx.de","web_url":null,"scm_url":null,"webscm_url":null},"msgid":"<20260421-mmc-mtk-sd-fixes-v1-3-5b840c546af2@baylibre.com>","date":"2026-04-21T14:24:06","name":"[3/3] mmc: mtk-sd: fix msdc cmd ready check","commit_ref":null,"pull_url":null,"state":"new","archived":false,"hash":"5b94c52fc16b411eb7effc6b59310902b551bddb","submitter":{"id":87228,"url":"http://patchwork.ozlabs.org/api/1.1/people/87228/?format=json","name":"David Lechner","email":"dlechner@baylibre.com"},"delegate":{"id":161331,"url":"http://patchwork.ozlabs.org/api/1.1/users/161331/?format=json","username":"dlech","first_name":"David","last_name":"Lechner","email":"dlechner@baylibre.com"},"mbox":"http://patchwork.ozlabs.org/project/uboot/patch/20260421-mmc-mtk-sd-fixes-v1-3-5b840c546af2@baylibre.com/mbox/","series":[{"id":500819,"url":"http://patchwork.ozlabs.org/api/1.1/series/500819/?format=json","web_url":"http://patchwork.ozlabs.org/project/uboot/list/?series=500819","date":"2026-04-21T14:24:03","name":"mmc: mtk-sd: fix HS200 mode writes on mt8189","version":1,"mbox":"http://patchwork.ozlabs.org/series/500819/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/patches/2225745/comments/","check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/2225745/checks/","tags":{},"headers":{"Return-Path":"<u-boot-bounces@lists.denx.de>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@legolas.ozlabs.org","Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=baylibre-com.20251104.gappssmtp.com\n header.i=@baylibre-com.20251104.gappssmtp.com header.a=rsa-sha256\n header.s=20251104 header.b=EkSXCp55;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de\n (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de;\n envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org)","phobos.denx.de;\n dmarc=none (p=none dis=none) header.from=baylibre.com","phobos.denx.de;\n spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de","phobos.denx.de;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=baylibre-com.20251104.gappssmtp.com\n header.i=@baylibre-com.20251104.gappssmtp.com header.b=\"EkSXCp55\";\n\tdkim-atps=neutral","phobos.denx.de;\n dmarc=none (p=none dis=none) header.from=baylibre.com","phobos.denx.de;\n spf=pass smtp.mailfrom=dlechner@baylibre.com"],"Received":["from phobos.denx.de (phobos.denx.de\n [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4g0Pl8424yz1yCv\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 22 Apr 2026 00:25:08 +1000 (AEST)","from h2850616.stratoserver.net (localhost [IPv6:::1])\n\tby phobos.denx.de (Postfix) with ESMTP id 278108412A;\n\tTue, 21 Apr 2026 16:24:46 +0200 (CEST)","by phobos.denx.de (Postfix, from userid 109)\n id 13A25839D5; Tue, 21 Apr 2026 16:24:44 +0200 (CEST)","from mail-oi1-x22d.google.com (mail-oi1-x22d.google.com\n [IPv6:2607:f8b0:4864:20::22d])\n (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits))\n (No client certificate requested)\n by phobos.denx.de (Postfix) with ESMTPS id BEB98840A9\n for <u-boot@lists.denx.de>; Tue, 21 Apr 2026 16:24:41 +0200 (CEST)","by mail-oi1-x22d.google.com with SMTP id\n 5614622812f47-4756e74f8edso2979345b6e.1\n for <u-boot@lists.denx.de>; Tue, 21 Apr 2026 07:24:41 -0700 (PDT)","from [127.0.1.1] ([2600:8803:e7e4:500:dc5a:64e5:1cd3:94d5])\n by smtp.gmail.com with ESMTPSA id\n 5614622812f47-4799fead505sm9217965b6e.2.2026.04.21.07.24.39\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Tue, 21 Apr 2026 07:24:39 -0700 (PDT)"],"X-Spam-Checker-Version":"SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de","X-Spam-Level":"","X-Spam-Status":"No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED,\n DKIM_VALID,RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS autolearn=ham\n autolearn_force=no version=3.4.2","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=baylibre-com.20251104.gappssmtp.com; s=20251104; t=1776781480;\n x=1777386280;\n darn=lists.denx.de;\n h=cc:to:in-reply-to:references:message-id:content-transfer-encoding\n :mime-version:subject:date:from:from:to:cc:subject:date:message-id\n :reply-to; bh=hxbQRkOOCXvr4sD1tYy+uI8xaUQfCRFh5rNjQ373bxE=;\n b=EkSXCp55wrnWn7yG6hF6QjD+hEnBwEemj2uWnaFobeyN4CEXUpV8rxhLA10Sej4xgZ\n xhWdEQb6Su3tV7lzkwOAebfKzCG7mxx0AtEJkSslCivWITq3j/n+trolH9lAsufYjpPJ\n sJ3Bw9xoI6jk80pNacsWkNunLeq9qz5AiTokjvS7WFSjApkhYaAI8TRbb+mMhqDphdcO\n XgK4iXKGWtZB37uXcnQc5Zsz6Gvx8CM5soBAtLI8a90bXzcZnWk+jfmUItM79IkqBhQD\n S/oI2s3W1hoIlaT2+putf6vrCNbwvQD00MgoM0H6JzvhWuffLQoLf/dr0PzODL+qvHSx\n Kfxg==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1776781480; x=1777386280;\n h=cc:to:in-reply-to:references:message-id:content-transfer-encoding\n :mime-version:subject:date:from:x-gm-gg:x-gm-message-state:from:to\n :cc:subject:date:message-id:reply-to;\n bh=hxbQRkOOCXvr4sD1tYy+uI8xaUQfCRFh5rNjQ373bxE=;\n b=EkbqO5ia6u7DwQU4pa3Vr8BqV+k/XAbtB1ZxCWIbCU6Ay4AlqSleOqDbwqtSJ0iMr4\n EB4NI8LwyDIdkMzogrQweyqorCVGJ5i9112F25iYv9ryMvPDTf65XHAeoLj8vzEySUNf\n FwnXdKc8eAAQItRjQwM9OlG9oarm8u+0Yc0sNCRppLSbogpiQAy/VeSwyVojqbiXCdBS\n aGOW026yBKSbGDdbmPb4LXTHSeZftinqOqbBMehkCMAcf5MQmbUukj64pxD6Tvl6MLE7\n rGbDhLbs5qcPgUQ3g8Mx+V5Dl1AbJtzFEqQvYyv0fhR3FVBXosCMnMTkSLwdGpDfm+9x\n 071Q==","X-Forwarded-Encrypted":"i=1;\n AFNElJ+ejsbg7g4I4U34mBh+AUwP/QXSZV7Q+L4YsUsypADVAiP2zawvZ4uUpqJukKX40DJKoQbzjTs=@lists.denx.de","X-Gm-Message-State":"AOJu0YxtyICWUVKllx5+u/t547lVaRzBkzdsc9lGZzcyS9dmiIxXmcoH\n 23ZfRFhH8PpD/FhM//m4TRDj+q/r+V60uB7D5qemOiBEYgv/aTpTb+Wl6mXeWKJ/KX4=","X-Gm-Gg":"AeBDievxrskDUkSMIvJcwQj3NvB6CPiJjS+recYzGKMVH0nINSM6qkJb4eEGNczXAZh\n FV9HoM0bQUS9UKAkAQANxZ7wnmeG9hy0qRdY5lK+2UZ4m1/z52IAlSGlqT38iuHm+9olcXfTa7B\n ULIfsn2UUy/UnERUjA7dhE2G/24U0/7v6B4MwimZfo2EhWC5S5GmXKj3c+kuSX/LPltml4S0CI1\n bM22XjMYd4LuE9XMyWM2dhHEWTnOoOWA06SLLgZQezw8BQ9PyskKTUvQs06O2onOPGXGQXfh+5E\n W7v5qeSnlEEoJvfBYH7dpEryZ4RoHo2q4YoMwEPQCAuhdI4v+mx7yCKI5aJhWmgsWSuIdvCmq0F\n mNJMV/MfEI9WSqw63HXBoaPuqjNolEXizsoc8ij/yTh95mQ3csyHzz4yxV1FHRE1Y802cPVUd8n\n ncDV3tnP4yWEanu8qekrHp9pkbXA5t9cIl1ejlQOE=","X-Received":"by 2002:a05:6808:1a03:b0:467:1e7b:72cd with SMTP id\n 5614622812f47-4799c917c5dmr9803301b6e.1.1776781480412;\n Tue, 21 Apr 2026 07:24:40 -0700 (PDT)","From":"David Lechner <dlechner@baylibre.com>","Date":"Tue, 21 Apr 2026 09:24:06 -0500","Subject":"[PATCH 3/3] mmc: mtk-sd: fix msdc cmd ready check","MIME-Version":"1.0","Content-Type":"text/plain; charset=\"utf-8\"","Content-Transfer-Encoding":"7bit","Message-Id":"<20260421-mmc-mtk-sd-fixes-v1-3-5b840c546af2@baylibre.com>","References":"<20260421-mmc-mtk-sd-fixes-v1-0-5b840c546af2@baylibre.com>","In-Reply-To":"<20260421-mmc-mtk-sd-fixes-v1-0-5b840c546af2@baylibre.com>","To":"\"ht.lin\" <ht.lin@mediatek.com>, Ryder Lee <ryder.lee@mediatek.com>,\n Weijie Gao <weijie.gao@mediatek.com>,\n Chunfeng Yun <chunfeng.yun@mediatek.com>,\n Igor Belwon <igor.belwon@mentallysanemainliners.org>,\n GSS_MTK_Uboot_upstream <GSS_MTK_Uboot_upstream@mediatek.com>,\n Peng Fan <peng.fan@nxp.com>, Jaehoon Chung <jh80.chung@samsung.com>,\n Tom Rini <trini@konsulko.com>, Simon Glass <sjg@chromium.org>","Cc":"=?utf-8?b?TWFjcGF1bCBMaW4gKOael+aZuuaWjCk=?= <Macpaul.Lin@mediatek.com>,\n\t=?utf-8?b?V2VpamllIEdhbyAo6auY5oOf5p2wKQ==?= <Weijie.Gao@mediatek.com>,\n  Julien Stephan <jstephan@baylibre.com>, u-boot@lists.denx.de,\n  David Lechner <dlechner@baylibre.com>","X-Mailer":"b4 0.16-dev","X-Developer-Signature":"v=1; a=openpgp-sha256; l=921; i=dlechner@baylibre.com;\n h=from:subject:message-id;\n bh=VuR/VR8ychxBXmBAty3m1A9ta/OTMzMUF3tEYQzSxG8=;\n b=owEBhAF7/pANAwAKAcLMIAH/AY/AAcsmYgBp54idfKrQFWytVMRN8ukWK/QT2x0WndadGdbdE\n Ep3rVaOYfKJAUoEAAEKADQWIQTsGNmeYg6D1pzYaJjCzCAB/wGPwAUCaeeInRYcZGxlY2huZXJA\n YmF5bGlicmUuY29tAAoJEMLMIAH/AY/AczAIAI8WsddFatPyZkChb+4U7JH9MCN/DYvXWPdNBWA\n ukmeD9TdmxzWX2H5qgqbCbhDUbRhmDM9tAELFwtBnoKMcc5+t+SC7xHs8U9P+tWFX4gII83dpQq\n JkIzFYNIcUj2bAQbIQh/WgPNBMhQaa6Z9b8/3xvn1msmdhu8VGmuVn+ayGlEf4MxpDYvbybXPZU\n sOYBDOhQJmNbz3mljzhs6KRySVuATdGu7tqPvrcvFlJRxibJCtwI+0z55AYT/Ucro6EXzOYE76A\n LqR9IfNQ91rAg7SoaI9fgZQOnWGQjAiFIRakQR4kdK3sstzKcqqqQhrR4tjSlDF1DIk5EVqPGsl\n jElc=","X-Developer-Key":"i=dlechner@baylibre.com; a=openpgp;\n fpr=8A73D82A6A1F509907F373881F8AF88C82F77C03","X-BeenThere":"u-boot@lists.denx.de","X-Mailman-Version":"2.1.39","Precedence":"list","List-Id":"U-Boot discussion <u-boot.lists.denx.de>","List-Unsubscribe":"<https://lists.denx.de/options/u-boot>,\n <mailto:u-boot-request@lists.denx.de?subject=unsubscribe>","List-Archive":"<https://lists.denx.de/pipermail/u-boot/>","List-Post":"<mailto:u-boot@lists.denx.de>","List-Help":"<mailto:u-boot-request@lists.denx.de?subject=help>","List-Subscribe":"<https://lists.denx.de/listinfo/u-boot>,\n <mailto:u-boot-request@lists.denx.de?subject=subscribe>","Errors-To":"u-boot-bounces@lists.denx.de","Sender":"\"U-Boot\" <u-boot-bounces@lists.denx.de>","X-Virus-Scanned":"clamav-milter 0.103.8 at phobos.denx.de","X-Virus-Status":"Clean"},"content":"From: \"ht.lin\" <ht.lin@mediatek.com>\n\nCorrect the check condition in msdc_cmd_is_ready() for MSDC_PS_DAT0\npolling. Without this change, it may not be able to detect if the SD\ncontroller is busy correctly for issuing the command.\n\nFixes: d24b69395949 (\"mmc: mtk-sd: add SD/MMC host controller driver for MT7623 SoC\")\nSigned-off-by: ht.lin <ht.lin@mediatek.com>\n---\n drivers/mmc/mtk-sd.c | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)","diff":"diff --git a/drivers/mmc/mtk-sd.c b/drivers/mmc/mtk-sd.c\nindex 616cf3f360f..51c9c0a3fad 100644\n--- a/drivers/mmc/mtk-sd.c\n+++ b/drivers/mmc/mtk-sd.c\n@@ -539,7 +539,7 @@ static bool msdc_cmd_is_ready(struct msdc_host *host)\n \t\treturn false;\n \t}\n \n-\tif (host->last_resp_type == MMC_RSP_R1b && host->last_data_write) {\n+\tif (host->last_resp_type == MMC_RSP_R1b || host->last_data_write) {\n \t\tret = readl_poll_timeout(&host->base->msdc_ps, reg,\n \t\t\t\t\t reg & MSDC_PS_DAT0, 1000000);\n \n","prefixes":["3/3"]}