git.openpandora.org
/
pandora-kernel.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
IPVS: netns awareness to ip_vs_app
[pandora-kernel.git]
/
net
/
netfilter
/
ipvs
/
ip_vs_proto_udp.c
diff --git
a/net/netfilter/ipvs/ip_vs_proto_udp.c
b/net/netfilter/ipvs/ip_vs_proto_udp.c
index
3719837
..
1dc3941
100644
(file)
--- a/
net/netfilter/ipvs/ip_vs_proto_udp.c
+++ b/
net/netfilter/ipvs/ip_vs_proto_udp.c
@@
-353,14
+353,14
@@
static inline __u16 udp_app_hashkey(__be16 port)
}
}
-static int udp_register_app(struct ip_vs_app *inc)
+static int udp_register_app(struct
net *net, struct
ip_vs_app *inc)
{
struct ip_vs_app *i;
__u16 hash;
__be16 port = inc->port;
int ret = 0;
{
struct ip_vs_app *i;
__u16 hash;
__be16 port = inc->port;
int ret = 0;
- struct netns_ipvs *ipvs = net_ipvs(
&init_
net);
- struct ip_vs_proto_data *pd = ip_vs_proto_data_get(
&init_
net, IPPROTO_UDP);
+ struct netns_ipvs *ipvs = net_ipvs(net);
+ struct ip_vs_proto_data *pd = ip_vs_proto_data_get(net, IPPROTO_UDP);
hash = udp_app_hashkey(port);
hash = udp_app_hashkey(port);
@@
-382,10
+382,10
@@
static int udp_register_app(struct ip_vs_app *inc)
static void
static void
-udp_unregister_app(struct ip_vs_app *inc)
+udp_unregister_app(struct
net *net, struct
ip_vs_app *inc)
{
{
- struct ip_vs_proto_data *pd = ip_vs_proto_data_get(
&init_
net, IPPROTO_UDP);
- struct netns_ipvs *ipvs = net_ipvs(
&init_
net);
+ struct ip_vs_proto_data *pd = ip_vs_proto_data_get(net, IPPROTO_UDP);
+ struct netns_ipvs *ipvs = net_ipvs(net);
spin_lock_bh(&ipvs->udp_app_lock);
atomic_dec(&pd->appcnt);
spin_lock_bh(&ipvs->udp_app_lock);
atomic_dec(&pd->appcnt);