[U-Boot,v5,7/8] NET: mvgbe: avoid unused variable warning when used without phylib support

Submitted by Sascha Silbe on June 25, 2013, 9:27 p.m.

Details

Message ID 1372195668-25496-8-git-send-email-t-uboot@infra-silbe.de
State Deferred
Delegated to: Stefan Roese
Headers show

Commit Message

Sascha Silbe June 25, 2013, 9:27 p.m.
Avoid a recently introduced unused variable warning for boards that
use mvgbe but not phylib.

Signed-off-by: Sascha Silbe <t-uboot@infra-silbe.de>
---
 v4->v5: Most of the original patch ("NET: mvgbe: add phylib support")
         was merged to master, only this clean-up remains.

 drivers/net/mvgbe.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

Patch hide | download patch | download mbox

diff --git a/drivers/net/mvgbe.c b/drivers/net/mvgbe.c
index 319fe8a..e19696a 100644
--- a/drivers/net/mvgbe.c
+++ b/drivers/net/mvgbe.c
@@ -436,8 +436,9 @@  static int mvgbe_init(struct eth_device *dev)
 {
 	struct mvgbe_device *dmvgbe = to_mvgbe(dev);
 	struct mvgbe_registers *regs = dmvgbe->regs;
-#if (defined (CONFIG_MII) || defined (CONFIG_CMD_MII)) \
-	 && defined (CONFIG_SYS_FAULT_ECHO_LINK_DOWN)
+#if (defined(CONFIG_MII) || defined(CONFIG_CMD_MII)) &&  \
+	!defined(CONFIG_PHYLIB) &&			 \
+	defined(CONFIG_SYS_FAULT_ECHO_LINK_DOWN)
 	int i;
 #endif
 	/* setup RX rings */