fib: introduce fib_alias_accessed() helper
Perf tools session at NFWS 2010 pointed out a false sharing on struct fib_alias that can be avoided pretty easily, if we set FA_S_ACCESSED bit only if needed (ie : not already set) Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
7b5edbc4cf
commit
9b0c290e78
@@ -901,7 +901,7 @@ int fib_semantic_match(struct list_head *head, const struct flowi *flp,
|
||||
if (fa->fa_scope < flp->fl4_scope)
|
||||
continue;
|
||||
|
||||
fa->fa_state |= FA_S_ACCESSED;
|
||||
fib_alias_accessed(fa);
|
||||
|
||||
err = fib_props[fa->fa_type].error;
|
||||
if (err == 0) {
|
||||
|
Reference in New Issue
Block a user