Index: sys/boot/common/dev_net.c =================================================================== --- sys/boot/common/dev_net.c +++ sys/boot/common/dev_net.c @@ -264,8 +264,29 @@ * be initialized. If any remain uninitialized, we will * use RARP and RPC/bootparam (the Sun way) to get them. */ - if (try_bootp) + if (try_bootp) { +#ifdef SKIP_BOOTP_REQUEST + if (bootp_response != NULL) { + int rc; + + rc = dhcp_try_rfc1048(bootp_response->bp_vend, + bootp_response_size - + offsetof(struct bootp, bp_vend)); + + if (rootip.s_addr == 0) + rootip = bootp_response->bp_siaddr; + if (gateip.s_addr == 0) + gateip = bootp_response->bp_giaddr; + if (myip.s_addr == 0) + myip = bootp_response->bp_yiaddr; + + if (rc < 0) + bootp(sock); + } +#else bootp(sock); +#endif + } if (myip.s_addr != 0) goto exit; #ifdef NETIF_DEBUG Index: sys/boot/i386/loader/Makefile =================================================================== --- sys/boot/i386/loader/Makefile +++ sys/boot/i386/loader/Makefile @@ -12,6 +12,7 @@ LOADER_NET_SUPPORT?= yes LOADER_NFS_SUPPORT?= yes LOADER_TFTP_SUPPORT?= yes +SKIP_BOOTP_REQUEST?= no # architecture-specific loader code SRCS= main.c conf.c vers.c @@ -39,6 +40,10 @@ CFLAGS+= -DLOADER_NFS_SUPPORT .endif +.if ${SKIP_BOOTP_REQUEST} == "yes" +CFLAGS+= -DSKIP_BOOTP_REQUEST +.endif + # Include bcache code. HAVE_BCACHE= yes