Thu Apr 23 00:27:45 2020 UTC ()
npftest_mbufops and npftest_ifops are owned by npf_mbuf_subr.c


(joerg)
diff -r1.19 -r1.20 src/usr.sbin/npf/npftest/libnpftest/npf_test.h

cvs diff -r1.19 -r1.20 src/usr.sbin/npf/npftest/libnpftest/npf_test.h (expand / switch to unified diff)

--- src/usr.sbin/npf/npftest/libnpftest/npf_test.h 2019/07/23 00:52:02 1.19
+++ src/usr.sbin/npf/npftest/libnpftest/npf_test.h 2020/04/23 00:27:45 1.20
@@ -74,28 +74,28 @@ struct mbuf { @@ -74,28 +74,28 @@ struct mbuf {
74#define M_PKTHDR 0x00002 74#define M_PKTHDR 0x00002
75 75
76#define m_get(x, y) npfkern_m_get(0, MLEN) 76#define m_get(x, y) npfkern_m_get(0, MLEN)
77#define m_gethdr(x, y) npfkern_m_get(M_PKTHDR, MLEN) 77#define m_gethdr(x, y) npfkern_m_get(M_PKTHDR, MLEN)
78#define m_length(m) npfkern_m_length(m) 78#define m_length(m) npfkern_m_length(m)
79#define m_freem(m) npfkern_m_freem(m) 79#define m_freem(m) npfkern_m_freem(m)
80#define mtod(m, t) ((t)((m)->m_data)) 80#define mtod(m, t) ((t)((m)->m_data))
81 81
82#endif 82#endif
83 83
84#define CHECK_TRUE(x) \ 84#define CHECK_TRUE(x) \
85 if (!(x)) { printf("FAIL: %s line %d\n", __func__, __LINE__); return 0; } 85 if (!(x)) { printf("FAIL: %s line %d\n", __func__, __LINE__); return 0; }
86 86
87const npf_mbufops_t npftest_mbufops; 87extern const npf_mbufops_t npftest_mbufops;
88const npf_ifops_t npftest_ifops; 88extern const npf_ifops_t npftest_ifops;
89 89
90struct mbuf * npfkern_m_get(int, int); 90struct mbuf * npfkern_m_get(int, int);
91size_t npfkern_m_length(const struct mbuf *); 91size_t npfkern_m_length(const struct mbuf *);
92void npfkern_m_freem(struct mbuf *); 92void npfkern_m_freem(struct mbuf *);
93 93
94void npf_test_init(int (*)(int, const char *, void *), 94void npf_test_init(int (*)(int, const char *, void *),
95 const char *(*)(int, const void *, char *, socklen_t), 95 const char *(*)(int, const void *, char *, socklen_t),
96 long (*)(void)); 96 long (*)(void));
97void npf_test_fini(void); 97void npf_test_fini(void);
98int npf_test_load(const void *, size_t, bool); 98int npf_test_load(const void *, size_t, bool);
99ifnet_t * npf_test_addif(const char *, bool, bool); 99ifnet_t * npf_test_addif(const char *, bool, bool);
100ifnet_t * npf_test_getif(const char *); 100ifnet_t * npf_test_getif(const char *);
101 101