public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
From: Mark Rutland <mark.rutland@arm.com>
To: Mark Brown <broonie@kernel.org>
Cc: linux-arm-kernel@lists.infradead.org, catalin.marinas@arm.com,
	will@kernel.org
Subject: Re: [PATCH] arm64: ftrace: add missing BTIs
Date: Mon, 29 Nov 2021 17:37:51 +0000	[thread overview]
Message-ID: <YaUP7wa/vP2hswhF@FVFF77S0Q05N> (raw)
In-Reply-To: <YaUE3zhN1VRF01ih@sirena.org.uk>

On Mon, Nov 29, 2021 at 04:50:39PM +0000, Mark Brown wrote:
> On Mon, Nov 29, 2021 at 01:57:09PM +0000, Mark Rutland wrote:
> 
> > When branch target identifiers are in use, code reachable via an
> > indirect branch requires a BTI landing pad at the branch target site.
> 
> Reviewed-by: Mark Brown <broonie@kernel.org>

Cheers!

> > In future we may wish to consider adding a new SYM_CODE_START_*()
> > variant which has an implicit BTI.
> 
> > +#ifdef BTI_C
> > +	BTI_C
> > +#endif
> 
> The ifdefs here feel ugly enough that it might be worth doing that right
> now TBH.  I'm trying to think of any cases where we might also need a
> BTI J but nothing springs to mind right now.

Agreed on the ugliness -- I'd like to revisit that with some related
cleanup/improvement to our existing SYM_*() macros. I just didn't want to do
that as a prerequisite for the fix as it'd make backports painful, e.g. by
creating a dependency on commit:

  1cbdf60bd1b74e39 ("kasan: arm64: support specialized outlined tag mismatch checks")

... which uses the ifdef pattern above.

I'm also not sure what naming/structure we'd like, or whether it's simpler to
unconditionally define BTI_C.

Thanks,
Mark.

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2021-11-29 17:39 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-29 13:57 [PATCH] arm64: ftrace: add missing BTIs Mark Rutland
2021-11-29 16:50 ` Mark Brown
2021-11-29 17:37   ` Mark Rutland [this message]
2021-11-29 17:48     ` Mark Brown
2021-12-02 10:43       ` Mark Rutland
2021-12-02 12:34         ` Mark Brown
2021-12-03 11:50           ` Mark Rutland
2021-12-03 13:29             ` Mark Brown
2021-12-02 10:59 ` Will Deacon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YaUP7wa/vP2hswhF@FVFF77S0Q05N \
    --to=mark.rutland@arm.com \
    --cc=broonie@kernel.org \
    --cc=catalin.marinas@arm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=will@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox