From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29718 invoked by alias); 18 Apr 2011 16:22:47 -0000 Received: (qmail 29710 invoked by uid 22791); 18 Apr 2011 16:22:45 -0000 X-SWARE-Spam-Status: No, hits=-5.7 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from bombadil.infradead.org (HELO bombadil.infradead.org) (18.85.46.34) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 18 Apr 2011 16:22:32 +0000 Received: from canuck.infradead.org ([2001:4978:20e::1]) by bombadil.infradead.org with esmtps (Exim 4.72 #1 (Red Hat Linux)) id 1QBrDR-0005Ff-P2; Mon, 18 Apr 2011 16:22:22 +0000 Received: from j77219.upc-j.chello.nl ([24.132.77.219] helo=twins) by canuck.infradead.org with esmtpsa (Exim 4.72 #1 (Red Hat Linux)) id 1QBrDQ-0005LE-HI; Mon, 18 Apr 2011 16:22:20 +0000 Received: by twins (Postfix, from userid 1000) id 05A8E83FCC01; Mon, 18 Apr 2011 18:21:58 +0200 (CEST) Subject: Re: [PATCH v3 2.6.39-rc1-tip 9/26] 9: uprobes: mmap and fork hooks. From: Peter Zijlstra To: Srikar Dronamraju Cc: Ingo Molnar , Steven Rostedt , Linux-mm , Arnaldo Carvalho de Melo , Linus Torvalds , Jonathan Corbet , Christoph Hellwig , Masami Hiramatsu , Thomas Gleixner , Ananth N Mavinakayanahalli , Oleg Nesterov , LKML , SystemTap , Jim Keniston , Roland McGrath , Andi Kleen , Andrew Morton In-Reply-To: <20110401143413.15455.75831.sendpatchset@localhost6.localdomain6> References: <20110401143223.15455.19844.sendpatchset@localhost6.localdomain6> <20110401143413.15455.75831.sendpatchset@localhost6.localdomain6> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Date: Mon, 18 Apr 2011 16:22:00 -0000 Message-ID: <1303143717.32491.872.camel@twins> Mime-Version: 1.0 Mailing-List: contact systemtap-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: systemtap-owner@sourceware.org X-SW-Source: 2011-q2/txt/msg00090.txt.bz2 On Fri, 2011-04-01 at 20:04 +0530, Srikar Dronamraju wrote: > + if (vma) { > + /* > + * We get here from uprobe_mmap() -- the case where we > + * are trying to copy an instruction from a page that's > + * not yet in page cache. > + * > + * Read page in before copy. > + */ > + struct file *filp =3D vma->vm_file; > + > + if (!filp) > + return -EINVAL; > + page_cache_sync_readahead(mapping, &filp->f_ra, filp, idx= , 1); > + } > + page =3D grab_cache_page(mapping, idx);=20 So I don't see why that isn't so for the normal install_uprobe() <- register_uprobe() path.