sam3x tcp_server: use the correct input function in netif
authorlottaviano <lottaviano@38d2e660-2303-0410-9eaa-f027e97ec537>
Tue, 24 May 2011 13:47:50 +0000 (13:47 +0000)
committerlottaviano <lottaviano@38d2e660-2303-0410-9eaa-f027e97ec537>
Tue, 24 May 2011 13:47:50 +0000 (13:47 +0000)
git-svn-id: https://src.develer.com/svnoss/bertos/trunk@4928 38d2e660-2303-0410-9eaa-f027e97ec537

boards/sam3x-ek/examples/sam3x-ek_tcp_server/main.c

index 991a0811e82d84e4087edb5d78556e0bf9c49541..8079fc58ae6cbe210a81dd387e134891b6a1a0d6 100644 (file)
@@ -79,7 +79,7 @@ static void init(void)
        tcpip_init(NULL, NULL);
 
        /* Bring up the network interface */
-       netif_add(&netif, &ipaddr, &netmask, &gw, NULL, ethernetif_init, ip_input);
+       netif_add(&netif, &ipaddr, &netmask, &gw, NULL, ethernetif_init, tcpip_input);
        netif_set_default(&netif);
        netif_set_up(&netif);
 }
@@ -110,10 +110,7 @@ int main(void)
 
        dhcp_start(&netif);
        while (!netif.ip_addr.addr)
-       {
-               dhcp_fine_tmr();
                timer_delay(DHCP_FINE_TIMER_MSECS);
-       }
        kprintf(">>> dhcp ok: ip = %d.%d.%d.%d (kernel %s)\n",
                (int)(netif.ip_addr.addr >>  0 & 0xff),
                (int)(netif.ip_addr.addr >>  8 & 0xff),