Convert CONFIG_KEEP_SERVERADDR to Kconfig
This converts the following to Kconfig: CONFIG_KEEP_SERVERADDR Drop the preprocessor usage also. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -196,13 +196,12 @@ void arp_receive(struct ethernet_hdr *et, struct ip_udp_hdr *ip, int len)
|
||||
if (!arp_is_waiting())
|
||||
break;
|
||||
|
||||
#ifdef CONFIG_KEEP_SERVERADDR
|
||||
if (net_server_ip.s_addr == net_arp_wait_packet_ip.s_addr) {
|
||||
if (IS_ENABLED(CONFIG_KEEP_SERVERADDR) &&
|
||||
net_server_ip.s_addr == net_arp_wait_packet_ip.s_addr) {
|
||||
char buf[20];
|
||||
sprintf(buf, "%pM", &arp->ar_sha);
|
||||
env_set("serveraddr", buf);
|
||||
}
|
||||
#endif
|
||||
|
||||
reply_ip_addr = net_read_ip(&arp->ar_spa);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user