net: kirkwood_egiga.c: fixed build warning
authorPrafulla Wadaskar <prafulla@marvell.com>
Wed, 9 Sep 2009 10:29:19 +0000 (15:59 +0530)
committerBen Warren <biggerbadderben@gmail.com>
Mon, 5 Oct 2009 05:55:02 +0000 (22:55 -0700)
if link up detection code is disabled through config option, it gives build warning.
This patch fixes the same

Signed-off-by: Prafulla Wadaskar <prafulla@marvell.com>
Signed-off-by: Ben Warren <biggerbadderben@gmail.com>
drivers/net/kirkwood_egiga.c

index 479035d552052b7e8a0e1f168063eb45a6dd2a3b..07a86cd6f71be477e3b0069325594e2cdc4646b6 100644 (file)
@@ -400,8 +400,10 @@ static int kwgbe_init(struct eth_device *dev)
 {
        struct kwgbe_device *dkwgbe = to_dkwgbe(dev);
        struct kwgbe_registers *regs = dkwgbe->regs;
+#if (defined (CONFIG_MII) || defined (CONFIG_CMD_MII)) \
+        && defined (CONFIG_SYS_FAULT_ECHO_LINK_DOWN)
        int i;
-
+#endif
        /* setup RX rings */
        kwgbe_init_rx_desc_ring(dkwgbe);