summaryrefslogtreecommitdiffstats
path: root/src/include/if_arp.h
diff options
context:
space:
mode:
authorMichael Brown2005-03-08 19:53:11 +0100
committerMichael Brown2005-03-08 19:53:11 +0100
commit3d6123e69ab879c72ff489afc5bf93ef0b7a94ce (patch)
tree9f3277569153a550fa8d81ebd61bd88f266eb8da /src/include/if_arp.h
downloadipxe-3d6123e69ab879c72ff489afc5bf93ef0b7a94ce.tar.gz
ipxe-3d6123e69ab879c72ff489afc5bf93ef0b7a94ce.tar.xz
ipxe-3d6123e69ab879c72ff489afc5bf93ef0b7a94ce.zip
Initial revision
Diffstat (limited to 'src/include/if_arp.h')
-rw-r--r--src/include/if_arp.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/include/if_arp.h b/src/include/if_arp.h
new file mode 100644
index 000000000..b3aebf743
--- /dev/null
+++ b/src/include/if_arp.h
@@ -0,0 +1,23 @@
+#ifndef _IF_ARP_H
+#define _IF_ARP_H
+
+#define ARP_REQUEST 1
+#define ARP_REPLY 2
+
+/*
+ * A pity sipaddr and tipaddr are not longword aligned or we could use
+ * in_addr. No, I don't want to use #pragma packed.
+ */
+struct arprequest {
+ uint16_t hwtype;
+ uint16_t protocol;
+ uint8_t hwlen;
+ uint8_t protolen;
+ uint16_t opcode;
+ uint8_t shwaddr[6];
+ uint8_t sipaddr[4];
+ uint8_t thwaddr[6];
+ uint8_t tipaddr[4];
+} PACKED;
+
+#endif /* _IF_ARP_H */