From: Li RongQing Date: Thu, 28 Mar 2013 02:24:11 +0000 (+0000) Subject: net: simplify the getting percpu of flow_cache X-Git-Tag: v3.10-rc1~66^2~281 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=278150321a3f5af85803e1214807ca5cfbace0e1;p=platform%2Fupstream%2Fkernel-adaptation-pc.git net: simplify the getting percpu of flow_cache replace per_cpu with per_cpu_ptr to save conversion between address and pointer Signed-off-by: Li RongQing Signed-off-by: David S. Miller --- diff --git a/net/core/flow.c b/net/core/flow.c index 7fae135..707fb7b 100644 --- a/net/core/flow.c +++ b/net/core/flow.c @@ -334,7 +334,7 @@ static int flow_cache_percpu_empty(struct flow_cache *fc, int cpu) struct flow_cache_percpu *fcp; int i; - fcp = &per_cpu(*fc->percpu, cpu); + fcp = per_cpu_ptr(fc->percpu, cpu); for (i = 0; i < flow_cache_hash_size(fc); i++) if (!hlist_empty(&fcp->hash_table[i])) return 0;