Merge branch 'master' of /home/wd/git/u-boot/custodians
[platform/kernel/u-boot.git] / board / xilinx / xilinx_enet / emac_adapter.c
index b30e897..0b100d2 100644 (file)
@@ -37,9 +37,9 @@
 *
 ******************************************************************************/
 
+#include <config.h>
 #include <common.h>
 #include <net.h>
-#include "xparameters.h"
 #include "xemac.h"
 
 #if defined(XPAR_EMAC_0_DEVICE_ID)
@@ -56,7 +56,7 @@ static XEmac Emac;
 static char etherrxbuff[PKTSIZE_ALIGN];        /* Receive buffer */
 
 /* hardcoded MAC address for the Xilinx EMAC Core when env is nowhere*/
-#ifdef CFG_ENV_IS_NOWHERE
+#ifdef CONFIG_ENV_IS_NOWHERE
 static u8 EMACAddr[ENET_ADDR_LENGTH] = { 0x00, 0x0a, 0x35, 0x00, 0x22, 0x01 };
 #endif
 
@@ -87,7 +87,7 @@ eth_init(bd_t * bis)
        /* make sure the Emac is stopped before it is started */
        (void) XEmac_Stop(&Emac);
 
-#ifdef CFG_ENV_IS_NOWHERE
+#ifdef CONFIG_ENV_IS_NOWHERE
        memcpy(bis->bi_enetaddr, EMACAddr, 6);
 #endif
 
@@ -147,7 +147,11 @@ eth_rx(void)
        RecvFrameLength = PKTSIZE;
        Result = XEmac_PollRecv(&Emac, (u8 *) etherrxbuff, &RecvFrameLength);
        if (Result == XST_SUCCESS) {
+#ifndef CONFIG_EMACLITE
                NetReceive((uchar *)etherrxbuff, RecvFrameLength);
+#else
+               NetReceive(etherrxbuff, RecvFrameLength);
+#endif
                return (1);
        } else {
                return (0);