summaryrefslogtreecommitdiffstats
path: root/kernel/include/linux/netfilter/ip_set_iptree.h
blob: 36bf5ac331abc9d928b71bfef5602ff9d910ac9f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#ifndef __IP_SET_IPTREE_H
#define __IP_SET_IPTREE_H

#include <linux/netfilter_ipv4/ip_set.h>

#define SETTYPE_NAME		"iptree"

struct ip_set_iptreed {
	unsigned long expires[256];	   	/* x.x.x.ADDR */
};

struct ip_set_iptreec {
	struct ip_set_iptreed *tree[256];	/* x.x.ADDR.* */
};

struct ip_set_iptreeb {
	struct ip_set_iptreec *tree[256];	/* x.ADDR.*.* */
};

struct ip_set_iptree {
	unsigned int timeout;
	unsigned int gc_interval;
#ifdef __KERNEL__
	uint32_t elements;		/* number of elements */
	struct timer_list gc;
	struct ip_set_iptreeb *tree[256];	/* ADDR.*.*.* */
#endif
};

struct ip_set_req_iptree_create {
	unsigned int timeout;
};

struct ip_set_req_iptree {
	ip_set_ip_t ip;
	unsigned int timeout;
};

#endif	/* __IP_SET_IPTREE_H */