diff options
author | Simon Horman <horms@verge.net.au> | 2010-11-08 20:05:57 +0900 |
---|---|---|
committer | Simon Horman <horms@verge.net.au> | 2010-11-16 08:13:07 +0900 |
commit | e9e5eee8733739f13a204132b502494b3f494f3b (patch) | |
tree | 916fbec7bdcea22c44565eab7582f3a71d0308e0 /net/netfilter/ipvs/ip_vs_pe.c | |
parent | c5d277d29ad1ae9add8d6984025ccd2e835971ce (diff) | |
download | op-kernel-dev-e9e5eee8733739f13a204132b502494b3f494f3b.zip op-kernel-dev-e9e5eee8733739f13a204132b502494b3f494f3b.tar.gz |
IPVS: Add persistence engine to connection entry
The dest of a connection may not exist if it has been created as the result
of connection synchronisation. But in order for connection entries for
templates with persistence engine data created through connection
synchronisation to be valid access to the persistence engine pointer is
required. So add the persistence engine to the connection itself.
Signed-off-by: Simon Horman <horms@verge.net.au>
Diffstat (limited to 'net/netfilter/ipvs/ip_vs_pe.c')
-rw-r--r-- | net/netfilter/ipvs/ip_vs_pe.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/net/netfilter/ipvs/ip_vs_pe.c b/net/netfilter/ipvs/ip_vs_pe.c index 3414af7..e99f920 100644 --- a/net/netfilter/ipvs/ip_vs_pe.c +++ b/net/netfilter/ipvs/ip_vs_pe.c @@ -30,7 +30,7 @@ void ip_vs_unbind_pe(struct ip_vs_service *svc) /* Get pe in the pe list by name */ static struct ip_vs_pe * -ip_vs_pe_getbyname(const char *pe_name) +__ip_vs_pe_getbyname(const char *pe_name) { struct ip_vs_pe *pe; @@ -60,28 +60,22 @@ ip_vs_pe_getbyname(const char *pe_name) } /* Lookup pe and try to load it if it doesn't exist */ -struct ip_vs_pe *ip_vs_pe_get(const char *name) +struct ip_vs_pe *ip_vs_pe_getbyname(const char *name) { struct ip_vs_pe *pe; /* Search for the pe by name */ - pe = ip_vs_pe_getbyname(name); + pe = __ip_vs_pe_getbyname(name); /* If pe not found, load the module and search again */ if (!pe) { request_module("ip_vs_pe_%s", name); - pe = ip_vs_pe_getbyname(name); + pe = __ip_vs_pe_getbyname(name); } return pe; } -void ip_vs_pe_put(struct ip_vs_pe *pe) -{ - if (pe && pe->module) - module_put(pe->module); -} - /* Register a pe in the pe list */ int register_ip_vs_pe(struct ip_vs_pe *pe) { |