ipvs: convert wrr scheduler to rcu
authorJulian Anastasov <ja@ssi.bg>
Fri, 22 Mar 2013 09:46:48 +0000 (11:46 +0200)
committerPablo Neira Ayuso <pablo@netfilter.org>
Mon, 1 Apr 2013 22:23:54 +0000 (00:23 +0200)
commit08cb2d032f13da4a076b51639b104a830b6bd18c
treea4b2b10a9e6f3acbd0920fb5c7bcaf1b6a69cc06
parentb310faad3e710b6822ebc0ec100db3682444e412
ipvs: convert wrr scheduler to rcu

The schedule method now needs _rcu list-traversal
primitive for svc->destinations. As the weight for some
dest can be reduced during dest selection, change the
algorithm to check weights by using minimum weights in the
1 .. max_weight-(di-1) range, with the same step (di). By this
way we ensure that there will be always a weight >= 1 check
before claiming that all destinations are overloaded.

Signed-off-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
net/netfilter/ipvs/ip_vs_wrr.c