diff --git a/drivers/net/netconsole.c b/drivers/net/netconsole.c
index 87cea7a..55f383f 100644
--- a/drivers/net/netconsole.c
+++ b/drivers/net/netconsole.c
@@ -23,7 +23,7 @@
 static int output_recursion;
 static int net_timeout;
 static uchar nc_ether[6]; /* server enet address */
-static IPaddr_t nc_ip; /* server ip */
+static struct in_addr nc_ip; /* server ip */
 static short nc_out_port; /* target output port */
 static short nc_in_port; /* source input port */
 static const char *output_packet; /* used by first send udp */
@@ -35,14 +35,14 @@
 enum proto_t net_loop_last_protocol = BOOTP;
 
 static void nc_wait_arp_handler(uchar *pkt, unsigned dest,
-				 IPaddr_t sip, unsigned src,
+				 struct in_addr sip, unsigned src,
 				 unsigned len)
 {
 	net_set_state(NETLOOP_SUCCESS); /* got arp reply - quit net loop */
 }
 
-static void nc_handler(uchar *pkt, unsigned dest, IPaddr_t sip, unsigned src,
-			unsigned len)
+static void nc_handler(uchar *pkt, unsigned dest, struct in_addr sip,
+		       unsigned src, unsigned len)
 {
 	if (input_size)
 		net_set_state(NETLOOP_SUCCESS); /* got input - quit net loop */
@@ -53,24 +53,25 @@
 	net_set_state(NETLOOP_SUCCESS);
 }
 
-static int is_broadcast(IPaddr_t ip)
+static int is_broadcast(struct in_addr ip)
 {
-	static IPaddr_t netmask;
-	static IPaddr_t our_ip;
+	static struct in_addr netmask;
+	static struct in_addr our_ip;
 	static int env_changed_id;
 	int env_id = get_env_id();
 
 	/* update only when the environment has changed */
 	if (env_changed_id != env_id) {
-		netmask = getenv_IPaddr("netmask");
-		our_ip = getenv_IPaddr("ipaddr");
+		netmask = getenv_ip("netmask");
+		our_ip = getenv_ip("ipaddr");
 
 		env_changed_id = env_id;
 	}
 
-	return (ip == ~0 ||				/* 255.255.255.255 */
-	    ((netmask & our_ip) == (netmask & ip) &&	/* on the same net */
-	    (netmask | ip) == ~0));		/* broadcast to our net */
+	return (ip.s_addr == ~0 || /* 255.255.255.255 (global bcast) */
+		((netmask.s_addr & our_ip.s_addr) ==
+		 (netmask.s_addr & ip.s_addr) && /* on the same net and */
+		 (netmask.s_addr | ip.s_addr) == ~0)); /* bcast to our net */
 }
 
 static int refresh_settings_from_env(void)
@@ -82,8 +83,8 @@
 	/* update only when the environment has changed */
 	if (env_changed_id != env_id) {
 		if (getenv("ncip")) {
-			nc_ip = getenv_IPaddr("ncip");
-			if (!nc_ip)
+			nc_ip = getenv_ip("ncip");
+			if (!nc_ip.s_addr)
 				return -1;	/* ncip is 0.0.0.0 */
 			p = strchr(getenv("ncip"), ':');
 			if (p != NULL) {
@@ -91,7 +92,7 @@
 				nc_in_port = nc_out_port;
 			}
 		} else
-			nc_ip = ~0; /* ncip is not set, so broadcast */
+			nc_ip.s_addr = ~0; /* ncip is not set, so broadcast */
 
 		p = getenv("ncoutport");
 		if (p != NULL)
@@ -131,7 +132,7 @@
 	}
 }
 
-int nc_input_packet(uchar *pkt, IPaddr_t src_ip, unsigned dest_port,
+int nc_input_packet(uchar *pkt, struct in_addr src_ip, unsigned dest_port,
 	unsigned src_port, unsigned len)
 {
 	int end, chunk;
@@ -139,7 +140,7 @@
 	if (dest_port != nc_in_port || !len)
 		return 0; /* not for us */
 
-	if (src_ip != nc_ip && !is_broadcast(nc_ip))
+	if (src_ip.s_addr != nc_ip.s_addr && !is_broadcast(nc_ip))
 		return 0; /* not from our client */
 
 	debug_cond(DEBUG_DEV_PKT, "input: \"%*.*s\"\n", len, len, pkt);
@@ -171,7 +172,7 @@
 	int inited = 0;
 	uchar *pkt;
 	uchar *ether;
-	IPaddr_t ip;
+	struct in_addr ip;
 
 	debug_cond(DEBUG_DEV_PKT, "output: \"%*.*s\"\n", len, len, buf);
 
diff --git a/drivers/net/sandbox-raw.c b/drivers/net/sandbox-raw.c
index 91da5f5..45c3b18 100644
--- a/drivers/net/sandbox-raw.c
+++ b/drivers/net/sandbox-raw.c
@@ -16,7 +16,7 @@
 DECLARE_GLOBAL_DATA_PTR;
 
 static int reply_arp;
-static IPaddr_t arp_ip;
+static struct in_addr arp_ip;
 
 static int sb_eth_raw_start(struct udevice *dev)
 {
@@ -55,7 +55,7 @@
 			 * localhost works on a higher-level API in Linux than
 			 * ARP packets, so fake it
 			 */
-			arp_ip = NetReadIP(&arp->ar_tpa);
+			arp_ip = net_read_ip(&arp->ar_tpa);
 			reply_arp = 1;
 			return 0;
 		}
@@ -93,9 +93,9 @@
 		/* Any non-zero MAC address will work */
 		memset(&arp->ar_sha, 0x01, ARP_HLEN);
 		/* Use whatever IP we were looking for (always 127.0.0.1?) */
-		NetWriteIP(&arp->ar_spa, arp_ip);
+		net_write_ip(&arp->ar_spa, arp_ip);
 		memcpy(&arp->ar_tha, pdata->enetaddr, ARP_HLEN);
-		NetWriteIP(&arp->ar_tpa, NetOurIP);
+		net_write_ip(&arp->ar_tpa, net_ip);
 		length = ARP_HDR_SIZE;
 	} else {
 		/* If local, the Ethernet header won't be included; skip it */
diff --git a/drivers/net/sandbox.c b/drivers/net/sandbox.c
index db115d0..e239ff4 100644
--- a/drivers/net/sandbox.c
+++ b/drivers/net/sandbox.c
@@ -24,7 +24,7 @@
  */
 struct eth_sandbox_priv {
 	uchar fake_host_hwaddr[ARP_HLEN];
-	IPaddr_t fake_host_ipaddr;
+	struct in_addr fake_host_ipaddr;
 	uchar *recv_packet_buffer;
 	int recv_packet_length;
 };
@@ -73,7 +73,7 @@
 			struct arp_hdr *arp_recv;
 
 			/* store this as the assumed IP of the fake host */
-			priv->fake_host_ipaddr = NetReadIP(&arp->ar_tpa);
+			priv->fake_host_ipaddr = net_read_ip(&arp->ar_tpa);
 			/* Formulate a fake response */
 			eth_recv = (void *)priv->recv_packet_buffer;
 			memcpy(eth_recv->et_dest, eth->et_src, ARP_HLEN);
@@ -90,9 +90,9 @@
 			arp_recv->ar_op = htons(ARPOP_REPLY);
 			memcpy(&arp_recv->ar_sha, priv->fake_host_hwaddr,
 			       ARP_HLEN);
-			NetWriteIP(&arp_recv->ar_spa, priv->fake_host_ipaddr);
+			net_write_ip(&arp_recv->ar_spa, priv->fake_host_ipaddr);
 			memcpy(&arp_recv->ar_tha, &arp->ar_sha, ARP_HLEN);
-			NetCopyIP(&arp_recv->ar_tpa, &arp->ar_spa);
+			net_copy_ip(&arp_recv->ar_tpa, &arp->ar_spa);
 
 			priv->recv_packet_length = ETHER_HDR_SIZE +
 				ARP_HDR_SIZE;
@@ -121,9 +121,9 @@
 				       ARP_HLEN);
 				ipr->ip_sum = 0;
 				ipr->ip_off = 0;
-				NetCopyIP((void *)&ipr->ip_dst, &ip->ip_src);
-				NetWriteIP((void *)&ipr->ip_src,
-					   priv->fake_host_ipaddr);
+				net_copy_ip((void *)&ipr->ip_dst, &ip->ip_src);
+				net_write_ip((void *)&ipr->ip_src,
+					     priv->fake_host_ipaddr);
 				ipr->ip_sum = compute_ip_checksum(ipr,
 					IP_HDR_SIZE);
 
