From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752878Ab2GIKNw (ORCPT ); Mon, 9 Jul 2012 06:13:52 -0400 Received: from merlin.infradead.org ([205.233.59.134]:37201 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752621Ab2GIKNv convert rfc822-to-8bit (ORCPT ); Mon, 9 Jul 2012 06:13:51 -0400 Message-ID: <1341828805.3462.28.camel@twins> Subject: Re: [PATCH 2/5] uprobes: suppress uprobe_munmap() from mmput() From: Peter Zijlstra To: Oleg Nesterov Cc: Ingo Molnar , Srikar Dronamraju , Ananth N Mavinakayanahalli , Anton Arapov , linux-kernel@vger.kernel.org Date: Mon, 09 Jul 2012 12:13:25 +0200 In-Reply-To: <20120709100920.GA21163@redhat.com> References: <20120708203003.GA18226@redhat.com> <1341822602.3462.15.camel@twins> <20120709100920.GA21163@redhat.com> Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7BIT X-Mailer: Evolution 3.2.2- Mime-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2012-07-09 at 12:09 +0200, Oleg Nesterov wrote: > No, mmap/munmap do not participate in uprobe refcounting. This code > does put_uprobe() for each uprobe, yes, but only because the counter > was incremented in build_probe_list(). > > uprobe_munmap() is only needed to decrement mm->uprobes_state.count, > but nobody except uprobe_munmap() itself will use it after mmput(). OK, that also answers my other question. Thanks