sctp: Make the ctl_sock per network namespace

- Kill sctp_get_ctl_sock, it is useless now.
- Pass struct net where needed so net->sctp.ctl_sock is accessible.

Signed-off-by: "Eric W. Biederman" <[email protected]>
Acked-by: Vlad Yasevich <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
This commit is contained in:
Eric W. Biederman 2012-08-06 08:43:06 +00:00 • committed by David S. Miller
commit 2ce9550350
5 changed files with 60 additions and 45 deletions

View file

@ -1,7 +1,15 @@
#ifndef __NETNS_SCTP_H__
#define __NETNS_SCTP_H__
struct sock;
struct netns_sctp {
/* This is the global socket data structure used for responding to
* the Out-of-the-blue (OOTB) packets. A control sock will be created
* for this socket at the initialization time.
*/
struct sock *ctl_sock;
/* This is the global local address list.
* We actively maintain this complete list of addresses on
* the system by catching address add/delete events.

View file

@ -114,7 +114,6 @@
/*
* sctp/protocol.c
*/
extern struct sock *sctp_get_ctl_sock(void);
extern int sctp_copy_local_addr_list(struct net *, struct sctp_bind_addr *,
sctp_scope_t, gfp_t gfp,
int flags);