Work on task #14587: Create common header for IANA assigned numbers

Create include/lwip/prot/iana.h
Move DHCP and ARP #define in there
This commit is contained in:
Dirk Ziegelmeier
2017-08-07 21:06:19 +02:00
parent 42fd01547d
commit 629ec98dd8
6 changed files with 58 additions and 13 deletions

View File

@@ -4,6 +4,7 @@
#include "lwip/etharp.h"
#include "netif/ethernet.h"
#include "lwip/stats.h"
#include "lwip/prot/iana.h"
#if !LWIP_STATS || !UDP_STATS || !MEMP_STATS || !ETHARP_STATS
#error "This tests needs UDP-, MEMP- and ETHARP-statistics enabled"
@@ -89,7 +90,7 @@ create_arp_response(ip4_addr_t *adr)
ethhdr->src = test_ethaddr2;
ethhdr->type = htons(ETHTYPE_ARP);
etharphdr->hwtype = htons(/*HWTYPE_ETHERNET*/ 1);
etharphdr->hwtype = htons(IANA_HWTYPE_ETHERNET);
etharphdr->proto = htons(ETHTYPE_IP);
etharphdr->hwlen = ETHARP_HWADDR_LEN;
etharphdr->protolen = sizeof(ip4_addr_t);