summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Roese <sr@denx.de>2008-09-05 14:11:40 +0200
committerStefan Roese <sr@denx.de>2008-09-08 10:27:51 +0200
commit6ca8646c1860bba74326bf916a5a3389a5c0d3b5 (patch)
tree5c390c65da5ce3e8e7ea5dadaaf58372bb87f5db
parent725b53ac61f4df3026b8f6489ef0080fd27d3816 (diff)
downloadu-boot-imx-6ca8646c1860bba74326bf916a5a3389a5c0d3b5.zip
u-boot-imx-6ca8646c1860bba74326bf916a5a3389a5c0d3b5.tar.gz
u-boot-imx-6ca8646c1860bba74326bf916a5a3389a5c0d3b5.tar.bz2
ppc4xx: Fix compilation warning for PIP405
This patch fixes a compilation warning for the PIP405 board. It moves the #ifndef CONFIG_CS8952_PHY define a little so that the warning doesn't occur anymore. I am a little unsure if this #ifdef is at the correct place now or if it could be removed completely. This needs to get tested on the PIP405 board. Signed-off-by: Stefan Roese <sr@denx.de>
-rw-r--r--cpu/ppc4xx/4xx_enet.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/cpu/ppc4xx/4xx_enet.c b/cpu/ppc4xx/4xx_enet.c
index 071ac0a..52486fd 100644
--- a/cpu/ppc4xx/4xx_enet.c
+++ b/cpu/ppc4xx/4xx_enet.c
@@ -1061,7 +1061,6 @@ static int ppc_4xx_eth_init (struct eth_device *dev, bd_t * bis)
/* wait for PHY to complete auto negotiation */
reg_short = 0;
-#ifndef CONFIG_CS8952_PHY
switch (devnum) {
case 0:
reg = CONFIG_PHY_ADDR;
@@ -1160,7 +1159,7 @@ static int ppc_4xx_eth_init (struct eth_device *dev, bd_t * bis)
miiphy_write (dev->name, reg, 0x1f, 0x0000);
/* end Vitesse/Cicada errata */
}
-#endif
+#endif /* defined(CONFIG_CIS8201_PHY) */
#if defined(CONFIG_ET1011C_PHY)
/*
@@ -1179,15 +1178,16 @@ static int ppc_4xx_eth_init (struct eth_device *dev, bd_t * bis)
miiphy_write(dev->name, reg, 0x1c, 0x74f0);
}
-#endif
+#endif /* defined(CONFIG_ET1011C_PHY) */
-#endif
+#endif /* defined(CONFIG_440GX) ... */
/* Start/Restart autonegotiation */
phy_setup_aneg (dev->name, reg);
udelay (1000);
}
#endif /* defined(CONFIG_PHY_RESET) */
+#if !defined(CONFIG_CS8952_PHY)
miiphy_read (dev->name, reg, PHY_BMSR, &reg_short);
/*
@@ -1211,12 +1211,11 @@ static int ppc_4xx_eth_init (struct eth_device *dev, bd_t * bis)
}
udelay (1000); /* 1 ms */
miiphy_read (dev->name, reg, PHY_BMSR, &reg_short);
-
}
puts (" done\n");
udelay (500000); /* another 500 ms (results in faster booting) */
}
-#endif /* #ifndef CONFIG_CS8952_PHY */
+#endif /* !defined(CONFIG_CS8952_PHY) */
get_speed:
if (reg == CONFIG_FIXED_PHY) {