[PATCH 09/16] net: stmmac: Disable MMC IRQs in the generic IRQs disable method

From: Serge Semin
Date: Mon Feb 08 2021 - 09:35:12 EST


MMC IRQs aren't handled by the main ISR, so for the sake of the code
coherency let's move the MMC IRQs disabling procedure to the generic IRQs
de-activating method. By doing so we've finally finished filling the
generic IRQs enable/disable functions up with the individual
MAC/MTL/DMA/etc interrupt control methods.

Signed-off-by: Serge Semin <Sergey.Semin@xxxxxxxxxxxxxxxxxxxx>
---
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
index ddcd82d02c27..fcd59a647b02 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
@@ -2274,8 +2274,6 @@ static void stmmac_mmc_setup(struct stmmac_priv *priv)
unsigned int mode = MMC_CNTRL_RESET_ON_READ | MMC_CNTRL_COUNTER_RESET |
MMC_CNTRL_PRESET | MMC_CNTRL_FULL_HALF_PRESET;

- stmmac_mmc_intr_all_mask(priv, priv->mmcaddr);
-
if (priv->dma_cap.rmon) {
stmmac_mmc_ctrl(priv, priv->mmcaddr, mode);
memset(&priv->mmc, 0, sizeof(struct stmmac_counters));
@@ -4182,6 +4180,8 @@ static void stmmac_disable_irq(struct stmmac_priv *priv)
if (priv->dma_cap.asp)
stmmac_disable_safety_feat_irq(priv, priv->ioaddr);

+ stmmac_mmc_intr_all_mask(priv, priv->mmcaddr);
+
enable_irq(priv->dev->irq);
}

--
2.29.2