From f89b81fbb45853ce8eb6f67e2f0167ba3deee72a Mon Sep 17 00:00:00 2001 From: David Wu Date: Wed, 23 Mar 2022 20:08:06 +0800 Subject: [PATCH] Revert "net: ethernet: stmmac: Add STMMAC_MMC config option" This reverts commit 41888ca1af0071429cfe15e0385a5e4be61c9e1d. Change-Id: Id96f85b1afd049343dc32119c71cdee9048caa97 Signed-off-by: David Wu --- drivers/net/ethernet/stmicro/stmmac/Kconfig | 6 ------ drivers/net/ethernet/stmicro/stmmac/Makefile | 3 +-- drivers/net/ethernet/stmicro/stmmac/hwif.c | 21 -------------------- 3 files changed, 1 insertion(+), 29 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/Kconfig b/drivers/net/ethernet/stmicro/stmmac/Kconfig index 9bffdb70f73f..b8bcb59b33fa 100644 --- a/drivers/net/ethernet/stmicro/stmmac/Kconfig +++ b/drivers/net/ethernet/stmicro/stmmac/Kconfig @@ -38,12 +38,6 @@ config STMMAC_FULL This selects the full function, default is Y, full-featured version includes 4.10 and other versions, if it is N, only 4.10 core working. -config STMMAC_MMC - bool "Support mmc core for STMMAC" - default STMMAC_ETH if !ROCKCHIP_MINI_KERNEL - help - This selects the stmmac mmc function, default is Y. - config STMMAC_PTP bool "PTP feature for STMMAC" default STMMAC_ETH if !ROCKCHIP_MINI_KERNEL diff --git a/drivers/net/ethernet/stmicro/stmmac/Makefile b/drivers/net/ethernet/stmicro/stmmac/Makefile index 83f69ae77bec..0244b5985309 100644 --- a/drivers/net/ethernet/stmicro/stmmac/Makefile +++ b/drivers/net/ethernet/stmicro/stmmac/Makefile @@ -2,7 +2,7 @@ obj-$(CONFIG_STMMAC_ETH) += stmmac.o stmmac-objs:= stmmac_main.o stmmac_mdio.o dwmac_lib.o \ - dwmac4_descs.o dwmac4_dma.o \ + mmc_core.o dwmac4_descs.o dwmac4_dma.o \ dwmac4_lib.o dwmac4_core.o hwif.o \ $(stmmac-y) @@ -11,7 +11,6 @@ stmmac-$(CONFIG_STMMAC_FULL) += ring_mode.o chain_mode.o dwmac1000_core.o \ enh_desc.o norm_desc.o dwmac5.o stmmac_tc.o \ dwxgmac2_core.o dwxgmac2_dma.o dwxgmac2_descs.o -stmmac-$(CONFIG_STMMAC_MMC) +=mmc_core.o stmmac-$(CONFIG_STMMAC_SELFTESTS) += stmmac_selftests.o stmmac-$(CONFIG_STMMAC_ETHTOOL) += stmmac_ethtool.o diff --git a/drivers/net/ethernet/stmicro/stmmac/hwif.c b/drivers/net/ethernet/stmicro/stmmac/hwif.c index da9772facf4e..704b60ec57f9 100644 --- a/drivers/net/ethernet/stmicro/stmmac/hwif.c +++ b/drivers/net/ethernet/stmicro/stmmac/hwif.c @@ -104,9 +104,7 @@ static const struct stmmac_hwif_entry { #endif const void *mode; const void *tc; -#ifdef CONFIG_STMMAC_MMC const void *mmc; -#endif int (*setup)(struct stmmac_priv *priv); int (*quirks)(struct stmmac_priv *priv); } stmmac_hw[] = { @@ -129,9 +127,7 @@ static const struct stmmac_hwif_entry { #endif .mode = NULL, .tc = NULL, -#ifdef CONFIG_STMMAC_MMC .mmc = &dwmac_mmc_ops, -#endif .setup = dwmac100_setup, .quirks = stmmac_dwmac1_quirks, }, { @@ -151,9 +147,7 @@ static const struct stmmac_hwif_entry { #endif .mode = NULL, .tc = NULL, -#ifdef CONFIG_STMMAC_MMC .mmc = &dwmac_mmc_ops, -#endif .setup = dwmac1000_setup, .quirks = stmmac_dwmac1_quirks, }, { @@ -173,9 +167,7 @@ static const struct stmmac_hwif_entry { #endif .mode = NULL, .tc = &dwmac510_tc_ops, -#ifdef CONFIG_STMMAC_MMC .mmc = &dwmac_mmc_ops, -#endif .setup = dwmac4_setup, .quirks = stmmac_dwmac4_quirks, }, { @@ -195,9 +187,7 @@ static const struct stmmac_hwif_entry { #endif .mode = &dwmac4_ring_mode_ops, .tc = &dwmac510_tc_ops, -#ifdef CONFIG_STMMAC_MMC .mmc = &dwmac_mmc_ops, -#endif .setup = dwmac4_setup, .quirks = NULL, }, @@ -221,10 +211,7 @@ static const struct stmmac_hwif_entry { #ifdef CONFIG_STMMAC_FULL .tc = &dwmac510_tc_ops, #endif - -#ifdef CONFIG_STMMAC_MMC .mmc = &dwmac_mmc_ops, -#endif .setup = dwmac4_setup, .quirks = NULL, }, @@ -246,9 +233,7 @@ static const struct stmmac_hwif_entry { #endif .mode = &dwmac4_ring_mode_ops, .tc = &dwmac510_tc_ops, -#ifdef CONFIG_STMMAC_MMC .mmc = &dwmac_mmc_ops, -#endif .setup = dwmac4_setup, .quirks = NULL, }, { @@ -269,9 +254,7 @@ static const struct stmmac_hwif_entry { #endif .mode = NULL, .tc = &dwmac510_tc_ops, -#ifdef CONFIG_STMMAC_MMC .mmc = &dwxgmac_mmc_ops, -#endif .setup = dwxgmac2_setup, .quirks = NULL, }, { @@ -292,9 +275,7 @@ static const struct stmmac_hwif_entry { #endif .mode = NULL, .tc = &dwmac510_tc_ops, -#ifdef CONFIG_STMMAC_MMC .mmc = &dwxgmac_mmc_ops, -#endif .setup = dwxlgmac2_setup, .quirks = stmmac_dwxlgmac_quirks, }, @@ -367,9 +348,7 @@ int stmmac_hwif_init(struct stmmac_priv *priv) #endif mac->mode = mac->mode ? : entry->mode; mac->tc = mac->tc ? : entry->tc; -#ifdef CONFIG_STMMAC_MMC mac->mmc = mac->mmc ? : entry->mmc; -#endif priv->hw = mac; priv->ptpaddr = priv->ioaddr + entry->regs.ptp_off;