[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250116092832.GG8362@noisy.programming.kicks-ass.net>
Date: Thu, 16 Jan 2025 10:28:32 +0100
From: Peter Zijlstra <peterz@...radead.org>
To: Christophe Leroy <christophe.leroy@...roup.eu>
Cc: Josh Poimboeuf <jpoimboe@...nel.org>,
Nathan Chancellor <nathan@...nel.org>,
Nick Desaulniers <ndesaulniers@...gle.com>,
Bill Wendling <morbo@...gle.com>,
Justin Stitt <justinstitt@...gle.com>,
Julien Thierry <jthierry@...hat.com>,
Miroslav Benes <mbenes@...e.cz>,
Raphael Gault <raphael.gault@....com>,
Michael Ellerman <mpe@...erman.id.au>,
Nicholas Piggin <npiggin@...il.com>,
Naveen N Rao <naveen@...nel.org>,
Madhavan Srinivasan <maddy@...ux.ibm.com>,
linux-kernel@...r.kernel.org, linuxppc-dev@...ts.ozlabs.org,
llvm@...ts.linux.dev
Subject: Re: [PATCH v5 12/15] objtool: Add support for more complex UACCESS
control
On Wed, Jan 15, 2025 at 11:42:52PM +0100, Christophe Leroy wrote:
> diff --git a/tools/objtool/check.c b/tools/objtool/check.c
> index 91436f4b3622..54625f09d831 100644
> --- a/tools/objtool/check.c
> +++ b/tools/objtool/check.c
> @@ -2422,6 +2422,14 @@ static int __annotate_late(struct objtool_file *file, int type, struct instructi
> insn->dead_end = false;
> break;
>
> + case ANNOTYPE_UACCESS_BEGIN:
> + insn->type = INSN_STAC;
> + break;
> +
> + case ANNOTYPE_UACCESS_END:
> + insn->type = INSN_CLAC;
> + break;
I would feel better if this had something like:
if (insn->type != INSN_OTHER)
WARN_INSN(insn, "over-riding instruction type: %d", insn->type);
Adding these annotations to control flow instruction would be bad etc.
Powered by blists - more mailing lists