lkml.org 
[lkml]   [2019]   [Feb]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH V4 5/9] x86/alternative: Split text_poke_bp() into tree steps
On Fri, 15 Feb 2019 13:47:16 +0100
Daniel Bristot de Oliveira <bristot@redhat.com> wrote:

> On 2/8/19 1:15 AM, Steven Rostedt wrote:
> > On Mon, 4 Feb 2019 20:58:58 +0100
> > Daniel Bristot de Oliveira <bristot@redhat.com> wrote:
> >
> >>
> >> +static void text_poke_bp_set_handler(void *addr, void *handler,
> >> + unsigned char int3)
> >> +{
> >> + bp_int3_handler = handler;
> >> + bp_int3_addr = (u8 *)addr + sizeof(int3);
> >> + text_poke(addr, &int3, sizeof(int3));
> >> +}
> >> +
> >> +
> >> +static void patch_first_byte(void *addr, const void *opcode, unsigned char int3)
> >> +{
> >> + /* patch the first byte */
> >> + text_poke(addr, opcode, sizeof(int3));
> >> +}
> > Hmm, perhaps get rid of the first function entirely, and just do...
> > (although why have the "int3" here anyway?)
> >
>
> These helpers were created because they were used twice in the first versions of
> this patch set. But with the change suggested by Masami, they are called only in
> the text_poke_bp_batch() now, so I am thinking to get rid of them all (removing
> this patch).
>
> Thoughts?
>

Go ahead.

-- Steve

\
 
 \ /
  Last update: 2019-02-21 16:27    [W:0.058 / U:0.420 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site