summaryrefslogtreecommitdiff
path: root/core/fs/pxe/bios.c
diff options
context:
space:
mode:
Diffstat (limited to 'core/fs/pxe/bios.c')
-rw-r--r--core/fs/pxe/bios.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/core/fs/pxe/bios.c b/core/fs/pxe/bios.c
index 6d514df2..6eb37626 100644
--- a/core/fs/pxe/bios.c
+++ b/core/fs/pxe/bios.c
@@ -5,6 +5,7 @@
#include <net.h>
#include <minmax.h>
#include <bios.h>
+#include <dprintf.h>
static uint16_t real_base_mem; /* Amount of DOS memory after freeing */
@@ -385,6 +386,9 @@ cant_free:
return;
}
+extern const char bdhcp_data[], adhcp_data[];
+extern const uint32_t bdhcp_len, adhcp_len;
+
void net_parse_dhcp(void)
{
int pkt_len;
@@ -400,11 +404,18 @@ void net_parse_dhcp(void)
*LocalDomain = 0; /* No LocalDomain received */
/*
+ * Parse any "before" hardcoded options
+ */
+ dprintf("DHCP: bdhcp_len = %d\n", bdhcp_len);
+ parse_dhcp_options(bdhcp_data, bdhcp_len, 0);
+
+ /*
* Get the DHCP client identifiers (query info 1)
*/
ddprintf("Getting cached packet ");
pkt_len = pxe_get_cached_info(1, bp, dhcp_max_packet);
parse_dhcp(bp, pkt_len);
+
/*
* We don't use flags from the request packet, so
* this is a good time to initialize DHCPMagic...
@@ -439,5 +450,11 @@ void net_parse_dhcp(void)
parse_dhcp(bp, pkt_len);
ddprintf("\n");
+ /*
+ * Parse any "after" hardcoded options
+ */
+ dprintf("DHCP: adhcp_len = %d\n", adhcp_len);
+ parse_dhcp_options(adhcp_data, adhcp_len, 0);
+
lfree(bp);
}