linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Michael Ellerman <mpe@ellerman.id.au>
To: "Naveen N. Rao" <naveen.n.rao@linux.vnet.ibm.com>,
	Masami Hiramatsu <mhiramat@kernel.org>
Cc: Anton Blanchard <anton@samba.org>,
	linuxppc-dev@lists.ozlabs.org,
	Ananth N Mavinakayanahalli <ananth@in.ibm.com>
Subject: Re: [PATCH] powerpc: kprobes: invoke handlers directly
Date: Mon, 21 Nov 2016 21:24:25 +1100	[thread overview]
Message-ID: <87bmx9w2p2.fsf@concordia.ellerman.id.au> (raw)
In-Reply-To: <20161118113926.31350-1-naveen.n.rao@linux.vnet.ibm.com>

"Naveen N. Rao" <naveen.n.rao@linux.vnet.ibm.com> writes:
> +#ifdef CONFIG_KPROBES
> +	if (kprobe_post_handler(regs))
> +		return;
> +#endif
...
> +#ifdef CONFIG_KPROBES
> +		if (kprobe_handler(regs))
> +			goto bail;
> +#endif
...
> +#ifdef CONFIG_KPROBES
> +		if (kprobe_post_handler(regs))
> +			return;
> +#endif
...
> +#ifdef CONFIG_KPROBES
> +		if (kprobe_post_handler(regs))
> +			return;
> +#endif
> +

Sorry too many ifdefs.

Can you please add empty static inline versions for CONFIG_KPROBES=n
that always return false. The compiler will be smart enough to elide
them entirely.

cheers

      parent reply	other threads:[~2016-11-21 10:24 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-18 11:39 [PATCH] powerpc: kprobes: invoke handlers directly Naveen N. Rao
2016-11-18 14:48 ` Masami Hiramatsu
2016-11-21  4:23 ` Ananth N Mavinakayanahalli
2016-11-21 10:24 ` Michael Ellerman [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=87bmx9w2p2.fsf@concordia.ellerman.id.au \
    --to=mpe@ellerman.id.au \
    --cc=ananth@in.ibm.com \
    --cc=anton@samba.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mhiramat@kernel.org \
    --cc=naveen.n.rao@linux.vnet.ibm.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;
as well as URLs for NNTP newsgroup(s).