projects
/
deliverable
/
linux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
net: use reciprocal_scale() helper
[deliverable/linux.git]
/
net
/
ipv4
/
netfilter
/
ipt_CLUSTERIP.c
diff --git
a/net/ipv4/netfilter/ipt_CLUSTERIP.c
b/net/ipv4/netfilter/ipt_CLUSTERIP.c
index 2510c02c2d2168ffcd27f286c7eab3ca75165f26..e90f83a3415b464014cecf0f072b2188f6889b7a 100644
(file)
--- a/
net/ipv4/netfilter/ipt_CLUSTERIP.c
+++ b/
net/ipv4/netfilter/ipt_CLUSTERIP.c
@@
-285,7
+285,7
@@
clusterip_hashfn(const struct sk_buff *skb,
}
/* node numbers are 1..n, not 0..n */
- return
(((u64)hashval * config->num_total_nodes) >> 32
) + 1;
+ return
reciprocal_scale(hashval, config->num_total_nodes
) + 1;
}
static inline int
This page took
0.028328 seconds
and
5
git commands to generate.