summaryrefslogtreecommitdiff
path: root/trafgen_proto.h
diff options
context:
space:
mode:
authorVadim Kochan <vadim4j@gmail.com>2016-01-26 22:25:01 +0200
committerTobias Klauser <tklauser@distanz.ch>2016-01-28 16:14:53 +0100
commit2ab562f1a46ffbc459146420caa86e400fa1b9e2 (patch)
treebd96bda5a66f3ff92cff417fa267577dde0b970b /trafgen_proto.h
parentb5100e276763a03c255dd1e7a4147c55c901419c (diff)
trafgen: proto: Add function to set field from device MAC
Add helper function to set device's MAC address to protocol field which may be used by Ethernet & ARP protocol header generation functions. Signed-off-by: Vadim Kochan <vadim4j@gmail.com> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Diffstat (limited to 'trafgen_proto.h')
-rw-r--r--trafgen_proto.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/trafgen_proto.h b/trafgen_proto.h
index 8f1f201..517b278 100644
--- a/trafgen_proto.h
+++ b/trafgen_proto.h
@@ -94,4 +94,7 @@ extern void proto_field_set_default_be16(struct proto_hdr *hdr, uint32_t fid,
extern void proto_field_set_default_be32(struct proto_hdr *hdr, uint32_t fid,
uint32_t val);
+extern void proto_field_set_dev_mac(struct proto_hdr *hdr, uint32_t fid);
+extern void proto_field_set_default_dev_mac(struct proto_hdr *hdr, uint32_t fid);
+
#endif /* TRAFGEN_PROTO_I_H */