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 0340C6B002D for ; Mon, 28 Nov 2011 09:14:05 -0500 (EST) Message-ID: <1322489609.2921.132.camel@twins> Subject: Re: [PATCH v7 3.2-rc2 9/30] uprobes: Background page replacement. From: Peter Zijlstra Date: Mon, 28 Nov 2011 15:13:29 +0100 In-Reply-To: <20111118110823.10512.74338.sendpatchset@srdronam.in.ibm.com> References: <20111118110631.10512.73274.sendpatchset@srdronam.in.ibm.com> <20111118110823.10512.74338.sendpatchset@srdronam.in.ibm.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 Sender: owner-linux-mm@kvack.org List-ID: To: Srikar Dronamraju Cc: Linus Torvalds , Oleg Nesterov , Andrew Morton , LKML , Linux-mm , Ingo Molnar , Andi Kleen , Christoph Hellwig , Steven Rostedt , Roland McGrath , Thomas Gleixner , Masami Hiramatsu , Arnaldo Carvalho de Melo , Anton Arapov , Ananth N Mavinakayanahalli , Jim Keniston , Stephen Wilson On Fri, 2011-11-18 at 16:38 +0530, Srikar Dronamraju wrote: > +/** > + * is_bkpt_insn - check if instruction is breakpoint instruction. > + * @insn: instruction to be checked. > + * Default implementation of is_bkpt_insn > + * Returns true if @insn is a breakpoint instruction. > + */ > +bool __weak is_bkpt_insn(u8 *insn) > +{ > + return (insn[0] =3D=3D UPROBES_BKPT_INSN); > }=20 This seems wrong, UPROBES_BKPT_INSN basically defined to be of uprobe_opcode_t type, not u8. So: bool __weak is_bkpt_insn(uprobe_opcode_t *insn) { return *insn =3D=3D UPROBE_BKPT_INSN; } seems like the right way to write this. -- 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 internet charges in Canada: sign http://stopthemeter.ca/ Don't email: email@kvack.org