summaryrefslogtreecommitdiff
path: root/include/net/flowcache.h
blob: 51eb971e897378e25329b06f80678f522eec2ea6 (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
#ifndef _NET_FLOWCACHE_H
#define _NET_FLOWCACHE_H

#include <linux/interrupt.h>
#include <linux/types.h>
#include <linux/timer.h>
#include <linux/notifier.h>

struct flow_cache_percpu {
	struct hlist_head		*hash_table;
	unsigned int			hash_count;
	u32				hash_rnd;
	int				hash_rnd_recalc;
	struct tasklet_struct		flush_tasklet;
};

struct flow_cache {
	u32				hash_shift;
	struct flow_cache_percpu __percpu *percpu;
	struct hlist_node		node;
	unsigned int			low_watermark;
	unsigned int			high_watermark;
	struct timer_list		rnd_timer;
};
#endif	/* _NET_FLOWCACHE_H */