summaryrefslogtreecommitdiffstats
path: root/samples/bpf/net_shared.h
diff options
context:
space:
mode:
Diffstat (limited to 'samples/bpf/net_shared.h')
-rw-r--r--samples/bpf/net_shared.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/samples/bpf/net_shared.h b/samples/bpf/net_shared.h
index 04b29b217d25..e9429af9aa44 100644
--- a/samples/bpf/net_shared.h
+++ b/samples/bpf/net_shared.h
@@ -2,6 +2,9 @@
#ifndef _NET_SHARED_H
#define _NET_SHARED_H
+#define AF_INET 2
+#define AF_INET6 10
+
#define ETH_ALEN 6
#define ETH_P_802_3_MIN 0x0600
#define ETH_P_8021Q 0x8100
@@ -11,6 +14,9 @@
#define ETH_P_ARP 0x0806
#define IPPROTO_ICMPV6 58
+#define TC_ACT_OK 0
+#define TC_ACT_SHOT 2
+
#if defined(__BYTE_ORDER__) && defined(__ORDER_LITTLE_ENDIAN__) && \
__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
#define bpf_ntohs(x) __builtin_bswap16(x)