lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20241127005515.a5ddv44cjnvd5awi@jpoimboe>
Date: Tue, 26 Nov 2024 16:55:15 -0800
From: Josh Poimboeuf <jpoimboe@...nel.org>
To: Tiezhu Yang <yangtiezhu@...ngson.cn>
Cc: Huacai Chen <chenhuacai@...nel.org>,
	Peter Zijlstra <peterz@...radead.org>, loongarch@...ts.linux.dev,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH v4 05/10] objtool: Handle unreachable entry of rodata

On Tue, Nov 26, 2024 at 07:04:39PM +0800, Tiezhu Yang wrote:
> On 11/26/2024 03:25 PM, Josh Poimboeuf wrote:
> > Are you sure this is specific to loongarch?
> 
> I am not sure, I only found this issue on LoongArch compiled with Clang,
> but I think there is no effect if make it generic, like this:
> 
> diff --git a/tools/objtool/check.c b/tools/objtool/check.c
> index f7586f82b967..87302e6fc07f 100644
> --- a/tools/objtool/check.c
> +++ b/tools/objtool/check.c
> @@ -2103,9 +2103,10 @@ static int add_jump_table(struct objtool_file *file,
> struct instruction *insn,
>                 if (!dest_insn)
>                         break;
> 
> -               /* Make sure the destination is in the same function: */
> -               if (!insn_func(dest_insn) || insn_func(dest_insn)->pfunc !=
> pfunc)
> -                       break;
> +               if (!insn_func(dest_insn) || insn_func(dest_insn)->pfunc !=
> pfunc) {
> +                       prev_offset = reloc_offset(reloc);
> +                       continue;
> +               }

Yeah, something like that might work.

-- 
Josh

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ