Re: [PATCH -tip v2] x86/kprobes: Remove unneeded casting from immediate value
From: Nadav Amit
Date: Wed Feb 15 2023 - 03:08:14 EST
> On Feb 15, 2023, at 2:10 AM, Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx> wrote:
>
> From: Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx>
>
> Remove unneeded casting from immediate value assignments for relative
> jump offset. Since the immediate values in the 'insn' data structure are
> assigned from immediate bytes as a signed value to insn.immediate.value
> by insn_field_set(). Thus, if we need to access that value as a signed
> value (in this kprobe's case), we don't need to cast it.
> This is a kind of clean up (should not change behavior) follows Nadav's
> bugfix.
>
> Link: https://lore.kernel.org/all/20230208071708.4048-1-namit@xxxxxxxxxx/
>
> Signed-off-by: Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx>
Thanks for incorporating my feedback.
Acked-by: Nadav Amit <namit@xxxxxxxxxx>