diff options
author | Dave Barach <dave@barachs.net> | 2020-04-13 16:44:09 -0400 |
---|---|---|
committer | Dave Barach <dave@barachs.net> | 2020-04-13 16:44:42 -0400 |
commit | fd0834262c517ea3a420fdba05fb95bc4141762b (patch) | |
tree | d4c5b72fd2734cc81120c7f4a1f6b98f9f06560e /src/vnet/dhcp/dhcp4_packet.h | |
parent | 5e62c84bb7058b58d9f0fa3b5eff9af93c073274 (diff) |
dhcp: fix unicast pkts, clean up state machine
Nominally a bug-fix cherry-pick, but completely manual. Closer to a
full feature backport minus binary api changes.
Send dhcp unicast packets to ip4-lookup. Otherwise, these packets
won't reach a dhcp server on a different subnet.
Do an immediate client scan after processing wakeup events.
Calculate the next process wakeup time by scanning all
clients.
Increase maximum (idle, no-clients-configured) timeout to 1000
seconds.
Reduce log spew.
Type: fix
Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: I3d10cd4c353298ed0b19e7e30887dc1d8d07b19e
(cherry picked from commit c54162981cdd41d65ed283df36955007552ddffe)
Diffstat (limited to 'src/vnet/dhcp/dhcp4_packet.h')
-rw-r--r-- | src/vnet/dhcp/dhcp4_packet.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/vnet/dhcp/dhcp4_packet.h b/src/vnet/dhcp/dhcp4_packet.h index 3076dd9529d..abd60127d6c 100644 --- a/src/vnet/dhcp/dhcp4_packet.h +++ b/src/vnet/dhcp/dhcp4_packet.h @@ -51,6 +51,8 @@ typedef struct dhcp_option_t options[0]; } dhcp_header_t; +extern u8 *format_dhcp_header (u8 * s, va_list * args); + typedef enum { DHCP_PACKET_DISCOVER = 1, @@ -60,6 +62,8 @@ typedef enum DHCP_PACKET_NAK, } dhcp_packet_type_t; +extern u8 *format_dhcp_packet_type (u8 * s, va_list * args); + typedef enum dhcp_packet_option_t_ { DHCP_PACKET_OPTION_MSG_TYPE = 53, |