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" <ebiederm@xmission.com> Acked-by: Vlad Yasevich <vyasevich@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
4db67e8086
commit
2ce9550350
@@ -204,7 +204,7 @@ int sctp_rcv(struct sk_buff *skb)
|
||||
sctp_endpoint_put(ep);
|
||||
ep = NULL;
|
||||
}
|
||||
sk = sctp_get_ctl_sock();
|
||||
sk = net->sctp.ctl_sock;
|
||||
ep = sctp_sk(sk)->ep;
|
||||
sctp_endpoint_hold(ep);
|
||||
rcvr = &ep->base;
|
||||
@@ -795,7 +795,7 @@ static struct sctp_endpoint *__sctp_rcv_lookup_endpoint(struct net *net,
|
||||
goto hit;
|
||||
}
|
||||
|
||||
ep = sctp_sk((sctp_get_ctl_sock()))->ep;
|
||||
ep = sctp_sk(net->sctp.ctl_sock)->ep;
|
||||
|
||||
hit:
|
||||
sctp_endpoint_hold(ep);
|
||||
|
Reference in New Issue
Block a user