diff options
author | Michael Brown | 2008-03-23 23:05:29 +0100 |
---|---|---|
committer | Michael Brown | 2008-03-23 23:05:47 +0100 |
commit | 2af6c8d130b6ada61f98fc02c7911aad51768ea3 (patch) | |
tree | 83a2d61d5067e2d06745365abbe144baf8b3e2ab /src/include/gpxe/ip.h | |
parent | [DHCP] Fix up fake-packet creation as used by PXENV_GET_CACHED_INFO (diff) | |
download | ipxe-2af6c8d130b6ada61f98fc02c7911aad51768ea3.tar.gz ipxe-2af6c8d130b6ada61f98fc02c7911aad51768ea3.tar.xz ipxe-2af6c8d130b6ada61f98fc02c7911aad51768ea3.zip |
[IPv4] Tidy up some header files.
Diffstat (limited to 'src/include/gpxe/ip.h')
-rw-r--r-- | src/include/gpxe/ip.h | 29 |
1 files changed, 22 insertions, 7 deletions
diff --git a/src/include/gpxe/ip.h b/src/include/gpxe/ip.h index 0a23565b..b1b0c48c 100644 --- a/src/include/gpxe/ip.h +++ b/src/include/gpxe/ip.h @@ -7,9 +7,15 @@ * */ -#include <ip.h> +#include <stdint.h> +#include <gpxe/in.h> +#include <gpxe/list.h> #include <gpxe/retry.h> +struct io_buffer; +struct net_device; +struct net_protocol; + /* IP constants */ #define IP_VER 0x40U @@ -27,7 +33,21 @@ #define IP_FRAG_IOB_SIZE 1500 #define IP_FRAG_TIMEOUT 50 -/* IP4 pseudo header */ +/** An IPv4 packet header */ +struct iphdr { + uint8_t verhdrlen; + uint8_t service; + uint16_t len; + uint16_t ident; + uint16_t frags; + uint8_t ttl; + uint8_t protocol; + uint16_t chksum; + struct in_addr src; + struct in_addr dest; +} __attribute__ (( packed )); + +/** An IPv4 pseudo header */ struct ipv4_pseudo_header { struct in_addr src; struct in_addr dest; @@ -68,11 +88,6 @@ struct frag_buffer { struct list_head list; }; -struct io_buffer; -struct net_device; -struct net_protocol; -struct tcpip_protocol; - extern struct list_head ipv4_miniroutes; extern struct net_protocol ipv4_protocol; |