Revert "ARM64: zynqmp: Added broken-tuning property to SD, eMMC nodes"
[oweals/u-boot.git] / drivers / net / fec_mxc.c
index 360f8e44d1017d9538a25496975727a645b8f6cc..84021ea5bec553fba2469be9867ecf1af7abbcb7 100644 (file)
@@ -20,7 +20,7 @@
 #include <asm/arch/imx-regs.h>
 #include <asm/imx-common/sys_proto.h>
 #include <asm/io.h>
-#include <asm/errno.h>
+#include <linux/errno.h>
 #include <linux/compiler.h>
 
 DECLARE_GLOBAL_DATA_PTR;
@@ -233,6 +233,7 @@ 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;
@@ -260,6 +261,7 @@ 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)
@@ -502,6 +504,8 @@ static int fec_open(struct eth_device *edev)
                }
                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);
@@ -1020,7 +1024,7 @@ static int fec_probe(bd_t *bd, int dev_id, uint32_t base_addr,
        start = get_timer(0);
        while (readl(&fec->eth->ecntrl) & FEC_ECNTRL_RESET) {
                if (get_timer(start) > (CONFIG_SYS_HZ * 5)) {
-                       printf("FEC MXC: Timeout reseting chip\n");
+                       printf("FEC MXC: Timeout resetting chip\n");
                        goto err4;
                }
                udelay(10);