]>
Commit | Line | Data |
---|---|---|
ef456144 CG |
1 | #ifndef _SOCK_REUSEPORT_H |
2 | #define _SOCK_REUSEPORT_H | |
3 | ||
4 | #include <linux/types.h> | |
5 | #include <net/sock.h> | |
6 | ||
7 | struct sock_reuseport { | |
8 | struct rcu_head rcu; | |
9 | ||
10 | u16 max_socks; /* length of socks */ | |
11 | u16 num_socks; /* elements in socks */ | |
12 | struct sock *socks[0]; /* array of sock pointers */ | |
13 | }; | |
14 | ||
15 | extern int reuseport_alloc(struct sock *sk); | |
16 | extern int reuseport_add_sock(struct sock *sk, const struct sock *sk2); | |
17 | extern void reuseport_detach_sock(struct sock *sk); | |
18 | extern struct sock *reuseport_select_sock(struct sock *sk, u32 hash); | |
19 | ||
20 | #endif /* _SOCK_REUSEPORT_H */ |