mirror of
https://git.savannah.nongnu.org/git/lwip.git
synced 2026-05-18 14:16:55 +08:00
patch #8361 "Add support for NTP option in DHCP" (slighly modified)
This commit is contained in:
@@ -202,6 +202,7 @@ void dhcp_fine_tmr(void);
|
||||
#define DHCP_OPTION_MTU 26
|
||||
#define DHCP_OPTION_BROADCAST 28
|
||||
#define DHCP_OPTION_TCP_TTL 37
|
||||
#define DHCP_OPTION_NTP 42
|
||||
#define DHCP_OPTION_END 255
|
||||
|
||||
/** DHCP options */
|
||||
|
||||
@@ -768,6 +768,22 @@
|
||||
#define LWIP_DHCP_BOOTP_FILE 0
|
||||
#endif
|
||||
|
||||
/**
|
||||
* LWIP_DHCP_GETS_NTP==1: Request NTP servers with discover/select. For each
|
||||
* response packet, an callback is called, which has to be provided by the port:
|
||||
* void dhcp_set_ntp_servers(u8_t num_ntp_servers, ip_addr_t* ntp_server_addrs);
|
||||
*/
|
||||
#ifndef LWIP_DHCP_GET_NTP_SRV
|
||||
#define LWIP_DHCP_GET_NTP_SRV 0
|
||||
#endif
|
||||
|
||||
/**
|
||||
* The maximum of NTP servers requested
|
||||
*/
|
||||
#ifndef LWIP_DHCP_MAX_NTP_SERVERS
|
||||
#define LWIP_DHCP_MAX_NTP_SERVERS 1
|
||||
#endif
|
||||
|
||||
/*
|
||||
------------------------------------
|
||||
---------- AUTOIP options ----------
|
||||
|
||||
Reference in New Issue
Block a user