net: lwip: add dns command

Add CMD_DNS when NET_LWIP is enabled to provide the dns command using
lwIP.

Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org>
Acked-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
This commit is contained in:
Jerome Forissier
2024-10-16 12:04:07 +02:00
committed by Tom Rini
parent 7a5e00d5c3
commit aedcfec9ed
5 changed files with 143 additions and 5 deletions

View File

@@ -2027,11 +2027,6 @@ config CMD_SNTP
help
Synchronize RTC via network
config CMD_DNS
bool "dns"
help
Lookup the IP of a hostname
config CMD_LINK_LOCAL
bool "linklocal"
select LIB_RAND
@@ -2079,6 +2074,12 @@ config CMD_DHCP
help
Boot image via network using DHCP/TFTP protocol
config CMD_DNS
bool "dns"
select PROT_DNS_LWIP if NET_LWIP
help
Lookup the IP of a hostname
config CMD_MII
bool "mii"
imply CMD_MDIO

View File

@@ -27,3 +27,11 @@ U_BOOT_CMD(
"[loadAddress] [[hostIPaddr:]bootfilename]"
);
#endif
#if defined(CONFIG_CMD_DNS)
U_BOOT_CMD(
dns, 3, 1, do_dns,
"lookup the IP of a hostname",
"hostname [envvar]"
);
#endif