Mirror of the lttng-dev mailing list
 help / color / mirror / Atom feed
From: laijs@cn.fujitsu.com (Lai Jiangshan)
Subject: [ltt-dev] [PATCH 00/10] urcu,call_rcu: minior fixes, round1
Date: Fri, 16 Sep 2011 11:33:11 +0800	[thread overview]
Message-ID: <4E72C377.2080004@cn.fujitsu.com> (raw)
In-Reply-To: <20110915155700.GB2428@linux.vnet.ibm.com>



On 09/15/2011 11:57 PM, Paul E. McKenney wrote:
> On Thu, Sep 15, 2011 at 11:23:04AM -0400, Mathieu Desnoyers wrote:
>> * Lai Jiangshan (laijs at cn.fujitsu.com) wrote:
>>> 2cleanups and 8bugfixes
>>>
>>> Lai Jiangshan (10):
>>>   add missing static
>>>   init maxcpus before use it
>>>   use get_cpu_call_rcu_data() for get_call_rcu_data()
>>>   use cds_list_for_each_entry_safe()
>>>   avoid memory leak in call_rcu_data_free()
>>>   wake up default call_rcu thread after we move the leftover callbacks
>>>   protect writing to per_cpu_call_rcu_data[*]
>>>   Return -EEXIST when the old cpu call_rcu_data has not been removed
>>>   avoid leaking crdp for failed path
>>>   protects call_rcu_data_list when remove node
> 
> These look good to me, thank you, Lai!
> 
>> Hi Lai,
>>
>> I think patch 10 (protects call_rcu_data_list when remove node) did not
>> make it into my inbox. Can you resend it please ?
> 
> Same here.
> 
> 							Thanx, Paul
> 

sorry, patch is appended.

Thanks,
Lai

Subject: [PATCH 10/10] protects call_rcu_data_list when remove node

Signed-off-by: Lai Jiangshan <laijs at cn.fujitsu.com>
---
 urcu-call-rcu-impl.h |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/urcu-call-rcu-impl.h b/urcu-call-rcu-impl.h
index f9250e8..87d9157 100644
--- a/urcu-call-rcu-impl.h
+++ b/urcu-call-rcu-impl.h
@@ -617,7 +617,10 @@ void call_rcu_data_free(struct call_rcu_data *crdp)
 		wake_call_rcu_thread(default_call_rcu_data);
 	}
 
+	call_rcu_lock(&call_rcu_mutex);
 	cds_list_del(&crdp->list);
+	call_rcu_unlock(&call_rcu_mutex);
+
 	free(crdp);
 }
 
-- 
1.7.4.4




      reply	other threads:[~2011-09-16  3:33 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-15  5:38 Lai Jiangshan
2011-09-15  5:38 ` [ltt-dev] [PATCH 01/10] add missing static Lai Jiangshan
2011-09-15 14:54   ` Mathieu Desnoyers
2011-09-15  5:38 ` [ltt-dev] [PATCH 02/10] init maxcpus before use it Lai Jiangshan
2011-09-15 14:59   ` Mathieu Desnoyers
2011-09-15  5:38 ` [ltt-dev] [PATCH 03/10] use get_cpu_call_rcu_data() for get_call_rcu_data() Lai Jiangshan
2011-09-15 15:08   ` Mathieu Desnoyers
2011-09-15  5:38 ` [ltt-dev] [PATCH 04/10] use cds_list_for_each_entry_safe() Lai Jiangshan
2011-09-15 15:11   ` Mathieu Desnoyers
2011-09-15  5:39 ` [ltt-dev] [PATCH 05/10] avoid memory leak in call_rcu_data_free() Lai Jiangshan
2011-09-15 15:14   ` Mathieu Desnoyers
2011-09-15  5:39 ` [ltt-dev] [PATCH 06/10] wake up default call_rcu thread after we move the leftover callbacks Lai Jiangshan
2011-09-15 15:16   ` Mathieu Desnoyers
2011-09-15  5:39 ` [ltt-dev] [PATCH 07/10] protect writing to per_cpu_call_rcu_data[*] Lai Jiangshan
2011-09-15 15:17   ` Mathieu Desnoyers
2011-09-15  5:39 ` [ltt-dev] [PATCH 08/10] Return -EEXIST when the old cpu call_rcu_data has not been removed Lai Jiangshan
2011-09-15 15:19   ` Mathieu Desnoyers
2011-09-15  5:39 ` [ltt-dev] [PATCH 09/10] avoid leaking crdp for failed path Lai Jiangshan
2011-09-15 15:21   ` Mathieu Desnoyers
2011-09-15 15:23 ` [ltt-dev] [PATCH 00/10] urcu,call_rcu: minior fixes, round1 Mathieu Desnoyers
2011-09-15 15:57   ` Paul E. McKenney
2011-09-16  3:33     ` Lai Jiangshan [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4E72C377.2080004@cn.fujitsu.com \
    --to=laijs@cn.fujitsu.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox