netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] core: fix the use of this_cpu_ptr
@ 2013-03-28  9:42 roy.qing.li
  2013-03-28 13:05 ` Eric Dumazet
  2013-03-29 19:13 ` [PATCH] core: fix the use " David Miller
  0 siblings, 2 replies; 30+ messages in thread
From: roy.qing.li @ 2013-03-28  9:42 UTC (permalink / raw)
  To: netdev

From: Li RongQing <roy.qing.li@gmail.com>

flush_tasklet is not percpu var, and percpu is percpu var, and
	this_cpu_ptr(&info->cache->percpu->flush_tasklet)
is not equal to
	&this_cpu_ptr(info->cache->percpu)->flush_tasklet

1f743b076(use this_cpu_ptr per-cpu helper) introduced this bug.

Signed-off-by: Li RongQing <roy.qing.li@gmail.com>
---
 net/core/flow.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/core/flow.c b/net/core/flow.c
index 7fae135..e8084b8 100644
--- a/net/core/flow.c
+++ b/net/core/flow.c
@@ -346,7 +346,7 @@ static void flow_cache_flush_per_cpu(void *data)
 	struct flow_flush_info *info = data;
 	struct tasklet_struct *tasklet;
 
-	tasklet = this_cpu_ptr(&info->cache->percpu->flush_tasklet);
+	tasklet = &this_cpu_ptr(info->cache->percpu)->flush_tasklet;
 	tasklet->data = (unsigned long)info;
 	tasklet_schedule(tasklet);
 }
-- 
1.7.10.4

^ permalink raw reply related	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2013-04-11 17:01 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-28  9:42 [PATCH] core: fix the use of this_cpu_ptr roy.qing.li
2013-03-28 13:05 ` Eric Dumazet
2013-03-28 14:38   ` Christoph Lameter
2013-03-28 15:36     ` Eric Dumazet
2013-03-28 16:44       ` Christoph Lameter
2013-03-29  1:24     ` RongQing Li
2013-04-01 15:21       ` Christoph Lameter
2013-04-01 16:31         ` Eric Dumazet
2013-04-01 18:15           ` Christoph Lameter
2013-04-03 20:41           ` this cpu documentation Christoph Lameter
2013-04-03 21:18             ` Tejun Heo
2013-04-04  0:09             ` Randy Dunlap
2013-04-04 14:41               ` Christoph Lameter
2013-04-04 16:28                 ` Tejun Heo
2013-04-04 17:19                 ` Randy Dunlap
2013-04-04 17:26                   ` Tejun Heo
2013-04-04 17:40                   ` Christoph Lameter
2013-04-04 18:35                     ` Randy Dunlap
2013-04-04 18:52                       ` Tejun Heo
2013-04-11 17:00                     ` Paul E. McKenney
     [not found]           ` <alpine.DEB.2.02.1304031540110.3444@gentwo.org>
2013-04-03 20:42             ` [PERCPU] Remove & in front of this_cpu_ptr Christoph Lameter
2013-04-03 21:24               ` Tejun Heo
2013-04-03 21:29                 ` Eric Dumazet
2013-04-04 13:52                   ` Christoph Lameter
2013-04-04 14:00                     ` Tejun Heo
2013-04-04 14:21                       ` Christoph Lameter
2013-04-04 14:25                         ` Tejun Heo
2013-04-04 15:02                           ` Christoph Lameter
2013-04-04 14:29                     ` Eric Dumazet
2013-03-29 19:13 ` [PATCH] core: fix the use " David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).