xref: /haiku/src/libs/compat/freebsd_network/compat/altq/if_altq.h (revision bef99ce5849c709f3ac5e8cd043ba1af5c3e8af3)
1 /*
2  * Copyright 2007 Haiku Inc. All rights reserved.
3  * Distributed under the terms of the MIT License.
4  */
5 #ifndef _FBSD_COMPAT_ALTQ_IF_ALTQ_H_
6 #define _FBSD_COMPAT_ALTQ_IF_ALTQ_H_
7 
8 
9 #include <sys/mbuf.h>
10 #include <sys/mutex.h>
11 
12 
13 struct ifaltq {
14 	struct mbuf*	ifq_head;
15 	struct mbuf*	ifq_tail;
16 
17 	int				ifq_len;
18 	int				ifq_maxlen;
19 	int				ifq_drops;
20 	struct mtx		ifq_mtx;
21 
22 	struct mbuf*	ifq_drv_head;
23 	struct mbuf*	ifq_drv_tail;
24 	int				ifq_drv_len;
25 	int				ifq_drv_maxlen;
26 
27 	int				altq_flags;
28 };
29 
30 
31 #define ALTQF_READY	0x1
32 
33 #define ALTDQ_REMOVE 1
34 
35 #define ALTQ_IS_ENABLED(ifq)	0
36 #define ALTQ_ENQUEUE(ifr, m, foo, error) \
37 	do { m_freem(m); error = -1; } while (0)
38 #define ALTQ_DEQUEUE(ifr, m)	(m) = NULL
39 #define ALTQ_PURGE(ifq)
40 
41 #define TBR_IS_ENABLED(ifq)		0
42 #define tbr_dequeue_ptr(ifq, v)	NULL
43 
44 #endif
45