linux-mips
[Top] [All Lists]

Re: [PATCH] MIPS Kprobes: Support branch instructions probing

To: Ralf Baechle <ralf@linux-mips.org>
Subject: Re: [PATCH] MIPS Kprobes: Support branch instructions probing
From: Maneesh Soni <manesoni@cisco.com>
Date: Fri, 14 Oct 2011 23:01:11 +0530
Cc: David Daney <david.daney@cavium.com>, linux-kernel@vger.kernel.org, linux-mips@linux-mips.org, ananth@in.ibm.com, kamensky@cisco.com
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=manesoni@cisco.com; l=1066; q=dns/txt; s=iport; t=1318613478; x=1319823078; h=date:from:to:cc:subject:message-id:reply-to:references: mime-version:in-reply-to; bh=sgyZMNQx0Srr5JqvCixPcO9cNQZYQaevx2IfCu0J5wU=; b=J2B9M7Hca+3vX2ADUEQljjwGgEg4p143ZPkKhup37ROUWnzy9FWSVGnt fijuVm8kqlPi8Q4bRQkwbUH62KvrauoNig9U37lbtyGkcIcaTfBrD/uWE I96+nWMWDI0UTJAM6YQQ30Zol3i1Kz3s1PjPHF4rolFOhtNcM+F4tkvSu 4=;
In-reply-to: <20111013180714.GA7422@linux-mips.org>
References: <20111013090749.GB16761@cisco.com> <4E971FD3.2020308@cavium.com> <20111013180714.GA7422@linux-mips.org>
Reply-to: manesoni@cisco.com
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mutt/1.5.20 (2009-06-14)
On Thu, Oct 13, 2011 at 07:07:14PM +0100, Ralf Baechle wrote:
> On Thu, Oct 13, 2011 at 10:28:51AM -0700, David Daney wrote:
> 
> > Where is the handling for:
> > 
> >     case cop1_op:
> > 
> > #ifdef CONFIG_CPU_CAVIUM_OCTEON
> >     case lwc2_op: /* This is bbit0 on Octeon */
> >     case ldc2_op: /* This is bbit032 on Octeon */
> >     case swc2_op: /* This is bbit1 on Octeon */
> >     case sdc2_op: /* This is bbit132 on Octeon */
> > #endif
> > 
> > These are all defined in insn_has_delayslot() but not here.
> 
> Which is a wonderful demonstration for why duplicating such a large
> function from branch.c was a baaad thing to do.
> 
> Maneesh, can you refactor the code to share everything that was copied
> from __compute_return_epc() can be shared with kprobes?  Idealy make
> everything a two part series, first one patch to refactor branch.c and
> the 2nd patch to deal with kprobes.
> 

Sure.. the branch likely instructions are not make it look good but
still do it in the next version.

Thanks for the comments.

Regards,
Maneesh

<Prev in Thread] Current Thread [Next in Thread>