]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
mmc: host: tmio: Add .sdio_irq()
authorYoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Tue, 10 Jun 2025 07:25:44 +0000 (16:25 +0900)
committerUlf Hansson <ulf.hansson@linaro.org>
Tue, 24 Jun 2025 10:43:26 +0000 (12:43 +0200)
Renesas SDHI controller requires vender specific handling when
an SDIO irq occurs. So, add .sdio_irq() to the tmio core.

Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Reviewed-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Tested-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Link: https://lore.kernel.org/r/20250610072545.2001435-2-yoshihiro.shimoda.uh@renesas.com
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
drivers/mmc/host/tmio_mmc.h
drivers/mmc/host/tmio_mmc_core.c

index 23b0be8e6d7d08afe88f7cab3a44abfd23527816..d730b7633ae1aa3a8b47fdaba820c1fb292a4e70 100644 (file)
@@ -193,6 +193,7 @@ struct tmio_mmc_host {
        bool (*check_retune)(struct tmio_mmc_host *host, struct mmc_request *mrq);
        void (*fixup_request)(struct tmio_mmc_host *host, struct mmc_request *mrq);
        unsigned int (*get_timeout_cycles)(struct tmio_mmc_host *host);
+       void (*sdio_irq)(struct tmio_mmc_host *host);
 
        const struct tmio_mmc_dma_ops *dma_ops;
 };
index c25c5fec3d77c9043979c8fff69a3b6d664874f2..2cec463b5e00a7575109312375f567e4ee537fab 100644 (file)
@@ -696,8 +696,11 @@ static bool __tmio_mmc_sdio_irq(struct tmio_mmc_host *host)
 
        sd_ctrl_write16(host, CTL_SDIO_STATUS, sdio_status);
 
-       if (mmc->caps & MMC_CAP_SDIO_IRQ && ireg & TMIO_SDIO_STAT_IOIRQ)
+       if (mmc->caps & MMC_CAP_SDIO_IRQ && ireg & TMIO_SDIO_STAT_IOIRQ) {
+               if (host->sdio_irq)
+                       host->sdio_irq(host);
                mmc_signal_sdio_irq(mmc);
+       }
 
        return ireg;
 }