X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=net%2Flink_local.c;h=31cdef4083a2e7afc183159f9552e9a00564193b;hb=4e899d868d68de5faf3cd3091f052d7a4c3a7f38;hp=ea5b4f4332b7b3e443741d524b6b76f4d85b44fe;hpb=8e7ff6773a12473690b58208c73d4fe19eab6fba;p=u-boot diff --git a/net/link_local.c b/net/link_local.c index ea5b4f4332..31cdef4083 100644 --- a/net/link_local.c +++ b/net/link_local.c @@ -99,19 +99,19 @@ static void configure_wait(void) debug_cond(DEBUG_DEV_PKT, "...wait %d %s nprobes=%u, nclaims=%u\n", timeout_ms, eth_get_name(), nprobes, nclaims); - NetSetTimeout(timeout_ms, link_local_timeout); + net_set_timeout_handler(timeout_ms, link_local_timeout); } void link_local_start(void) { - ip = getenv_ip("llipaddr"); + ip = env_get_ip("llipaddr"); if (ip.s_addr != 0 && (ntohl(ip.s_addr) & IN_CLASSB_NET) != LINKLOCAL_ADDR) { puts("invalid link address"); net_set_state(NETLOOP_FAIL); return; } - net_netmask.s_addr = IN_CLASSB_NET; + net_netmask.s_addr = htonl(IN_CLASSB_NET); seed = seed_mac(); if (ip.s_addr == 0) @@ -182,7 +182,7 @@ static void link_local_timeout(void) conflicts = 0; timeout_ms = -1; /* Never timeout in the monitor state */ - NetSetTimeout(0, NULL); + net_set_timeout_handler(0, NULL); /* NOTE: all other exit paths should deconfig ... */ net_set_state(NETLOOP_SUCCESS);