gre: Compatibility with older Linux kernel versions.
[openvswitch] / datapath / linux-2.6 / compat-2.6 / include / net / net_namespace.h
1 #ifndef __NET_NAMESPACE_WRAPPER_H
2 #define __NET_NAMESPACE_WRAPPER_H 1
3
4 #include <linux/version.h>
5 #if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,24)
6 #include_next <net/net_namespace.h>
7 #endif
8
9 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,26)
10
11 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,24)
12 struct net;
13
14 struct pernet_operations {
15         struct list_head list;
16         int (*init)(struct net *net);
17         void (*exit)(struct net *net);
18 };
19 #endif /* linux kernel < 2.6.24 */
20
21 extern int register_pernet_gen_device(int *id, struct pernet_operations *);
22 extern void unregister_pernet_gen_device(int id, struct pernet_operations *);
23
24 #endif /* linux kernel < 2.6.26 */
25
26 #endif