[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tencent_7FA7E9159716AFC740AEF4B86D359FA59E05@qq.com>
Date: Thu, 12 Sep 2024 10:39:46 +0800
From: laokz <laokz@...mail.com>
To: Josh Poimboeuf <jpoimboe@...nel.org>, live-patching@...r.kernel.org
Cc: linux-kernel@...r.kernel.org, x86@...nel.org, Miroslav Benes
<mbenes@...e.cz>, Petr Mladek <pmladek@...e.com>, Joe Lawrence
<joe.lawrence@...hat.com>, Jiri Kosina <jikos@...nel.org>, Peter Zijlstra
<peterz@...radead.org>, Marcos Paulo de Souza <mpdesouza@...e.com>, Song
Liu <song@...nel.org>
Subject: Re: [RFC 31/31] objtool, livepatch: Livepatch module generation
On Mon, 2024-09-02 at 21:00 -0700, Josh Poimboeuf wrote:
> diff --git a/tools/objtool/klp-diff.c b/tools/objtool/klp-diff.c
> new file mode 100644
> index 000000000000..76296e38f9ff
> --- /dev/null
> +++ b/tools/objtool/klp-diff.c
> ...
> +static unsigned int reloc_size(struct reloc *reloc)
> +{
> + switch (reloc_type(reloc)) {
> +
> + case R_X86_64_PC32:
> + case R_X86_64_32:
> + return 4;
> +
> + case R_X86_64_64:
> + case R_X86_64_PC64:
>
Better separate to arch/x86 directory. Put different architecture
relocation types all together looks a little error prone.
Regards,
laokz
Powered by blists - more mailing lists