From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail137.messagelabs.com (mail137.messagelabs.com [216.82.249.19]) by kanga.kvack.org (Postfix) with ESMTP id A73896B00E8 for ; Wed, 26 Jan 2011 10:16:27 -0500 (EST) Subject: Re: [RFC] [PATCH 2.6.37-rc5-tip 8/20] 8: uprobes: mmap and fork hooks. From: Peter Zijlstra In-Reply-To: <20110126145955.GJ19725@linux.vnet.ibm.com> References: <20101216095714.23751.52601.sendpatchset@localhost6.localdomain6> <20101216095848.23751.73144.sendpatchset@localhost6.localdomain6> <1295957739.28776.717.camel@laptop> <20110126090346.GH19725@linux.vnet.ibm.com> <1296037239.28776.1149.camel@laptop> <20110126145955.GJ19725@linux.vnet.ibm.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Date: Wed, 26 Jan 2011 16:16:49 +0100 Message-ID: <1296055009.28776.1202.camel@laptop> Mime-Version: 1.0 Sender: owner-linux-mm@kvack.org To: Srikar Dronamraju Cc: Ingo Molnar , Steven Rostedt , Linux-mm , Arnaldo Carvalho de Melo , Linus Torvalds , Ananth N Mavinakayanahalli , Christoph Hellwig , Masami Hiramatsu , Oleg Nesterov , LKML , SystemTap , Jim Keniston , Frederic Weisbecker , Andi Kleen , Andrew Morton , "Paul E. McKenney" List-ID: On Wed, 2011-01-26 at 20:29 +0530, Srikar Dronamraju wrote: > list_for_each_entry_safe(mm, tmpmm, &tmp_list, uprobes_list) { > down_read(&mm->map_sem); > if (!install_uprobe(mm, uprobe)) > ret =3D 0; > up_read(&mm->map_sem); > list_del(&mm->uprobes_list); > mmput(mm); > }=20 and the tmp_list thing works because new mm's will hit the mmap callback and you cannot loose mm's due to the refcount, right? -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Fight unfair telecom policy in Canada: sign http://dissolvethecrtc.ca/ Don't email: email@kvack.org