diff options
author | Mike Belopuhov <mikeb@cvs.openbsd.org> | 2017-06-28 18:31:04 +0000 |
---|---|---|
committer | Mike Belopuhov <mikeb@cvs.openbsd.org> | 2017-06-28 18:31:04 +0000 |
commit | ff0bb5eca7820ea500f63fdba84b65d82f81b4f4 (patch) | |
tree | e81bef8741f4256393dfcdd65047ee3bd5811ab7 | |
parent | e7d423d8be4ef3eae55043fa62fdf43c48708ac8 (diff) |
Extend pf queueing ops to include queue manager hooks
Discussed with and OK henning@ at d2k17 as a part of a larger diff.
-rw-r--r-- | sys/net/pfvar.h | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h index d19f6f769ac..4ab474dbcad 100644 --- a/sys/net/pfvar.h +++ b/sys/net/pfvar.h @@ -1,4 +1,4 @@ -/* $OpenBSD: pfvar.h,v 1.458 2017/06/26 18:33:24 bluhm Exp $ */ +/* $OpenBSD: pfvar.h,v 1.459 2017/06/28 18:31:03 mikeb Exp $ */ /* * Copyright (c) 2001 Daniel Hartmeier @@ -47,6 +47,7 @@ struct ip; struct ip6_hdr; +struct mbuf_list; #define PF_TCPS_PROXY_SRC ((TCP_NSTATES)+0) #define PF_TCPS_PROXY_DST ((TCP_NSTATES)+1) @@ -1365,10 +1366,16 @@ struct hfsc_opts { }; struct pfq_ops { - void *(*pfq_alloc)(struct ifnet *); - int (*pfq_addqueue)(void *, struct pf_queuespec *); - void (*pfq_free)(void *); - int (*pfq_qstats)(struct pf_queuespec *, void *, int *); + void * (*pfq_alloc)(struct ifnet *); + int (*pfq_addqueue)(void *, struct pf_queuespec *); + void (*pfq_free)(void *); + int (*pfq_qstats)(struct pf_queuespec *, void *, int *); + /* Queue manager ops */ + unsigned int (*pfq_qlength)(void *); + struct mbuf * (*pfq_enqueue)(void *, struct mbuf *); + struct mbuf * (*pfq_deq_begin)(void *, void **, struct mbuf_list *); + void (*pfq_deq_commit)(void *, struct mbuf *, void *); + void (*pfq_purge)(void *, struct mbuf_list *); }; struct pf_tagname { |