[PATCH 09/41] fec_mxc: Remove CONFIG_FEC_FIXED_SPEED support

Tom Rini
2022-12-02T21:44:49Z

This option is only used on one platform currently. However, with PHYLIB
enabled, which this platform also does, this option is not checked and
the functional use case is handled. Remove this code.

Signed-off-by: Tom Rini <trini@konsulko.com>
---
doc/README.fec_mxc | 6 ------
drivers/net/fec_mxc.c | 4 ----
include/configs/brppt2.h | 3 ---
3 files changed, 13 deletions(-)

diff --git a/doc/README.fec_mxc b/doc/README.fec_mxc
index d17dfb676f79..4e890d348f47 100644
--- a/doc/README.fec_mxc
+++ b/doc/README.fec_mxc
@@ -22,12 +22,6 @@ CONFIG_FEC_MXC_PHYADDR
Optional, selects the exact phy address that should be connected
and function fecmxc_initialize will try to initialize it.

-CONFIG_FEC_FIXED_SPEED
- Optional, selects a fixed speed on the MAC interface without asking some
- phy. This is usefull if there is a direct MAC <-> MAC connection, for
- example if the CPU is connected directly via the RGMII interface to a
- ethernet-switch.
-
Reading the ethaddr from the SoC eFuses:
if CONFIG_FEC_MXC is defined and the U-Boot environment does not contain the
ethaddr variable, then its value gets read from the corresponding eFuses in
diff --git a/drivers/net/fec_mxc.c b/drivers/net/fec_mxc.c
index a61a1fc75738..9cb235ad5e37 100644
--- a/drivers/net/fec_mxc.c
+++ b/drivers/net/fec_mxc.c
@@ -268,7 +268,6 @@ static int miiphy_restart_aneg(struct eth_device *dev)
return ret;
}

-#ifndef CONFIG_FEC_FIXED_SPEED
static int miiphy_wait_aneg(struct eth_device *dev)
{
uint32_t start;
@@ -294,7 +293,6 @@ static int miiphy_wait_aneg(struct eth_device *dev)

return 0;
}
-#endif /* CONFIG_FEC_FIXED_SPEED */
#endif

static int fec_rx_task_enable(struct fec_priv *fec)
@@ -536,8 +534,6 @@ static int fec_open(struct udevice *dev)
}
speed = fec->phydev->speed;
}
-#elif CONFIG_FEC_FIXED_SPEED
- speed = CONFIG_FEC_FIXED_SPEED;
#else
miiphy_wait_aneg(edev);
speed = miiphy_speed(edev->name, fec->phy_id);
diff --git a/include/configs/brppt2.h b/include/configs/brppt2.h
index 80104b2d3193..984602c2cf7c 100644
--- a/include/configs/brppt2.h
+++ b/include/configs/brppt2.h
@@ -78,9 +78,6 @@ BUR_COMMON_ENV \
#define CFG_SYS_INIT_RAM_ADDR IRAM_BASE_ADDR
#define CFG_SYS_INIT_RAM_SIZE IRAM_SIZE

-/* Ethernet */
-#define CONFIG_FEC_FIXED_SPEED _1000BASET
-
/* USB Configs */
#define CONFIG_MXC_USB_PORTSC (PORT_PTS_UTMI | PORT_PTS_PTW)

--
2.25.1