public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Szabolcs Nagy <szabolcs.nagy@arm.com>
To: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Cc: libc-alpha@sourceware.org, jma14 <jma14@rice.edu>,
	Carlos O'Donell <carlos@redhat.com>,
	John Mellor-Crummey <johnmc@rice.edu>
Subject: Re: [PATCH v10 4/4] elf: Fix runtime linker auditing on aarch64 (BZ #26643)
Date: Tue, 18 Jan 2022 13:36:21 +0000	[thread overview]
Message-ID: <20220118133621.GG3294453@arm.com> (raw)
In-Reply-To: <20220117213136.1327053-5-adhemerval.zanella@linaro.org>

The 01/17/2022 18:31, Adhemerval Zanella via Libc-alpha wrote:
> From: Ben Woodard <woodard@redhat.com>
> 
> The rtld audit support show two problems on aarch64:
> 
>   1. _dl_runtime_resolve does not preserve x8, the indirect result
>       location register, which might generate wrong result calls
>       depending of the function signature.
> 
>   2. The NEON Q registers pushed onto the stack by _dl_runtime_resolve
>      were twice the size of D registers extracted from the stack frame by
>      _dl_runtime_profile.
> 
> While 2. might result in wrong information passed on the PLT tracing,
> 1. generates wrong runtime behaviour.
> 
> The aarch64 rtld audit support is change to:
> 
>   * Both La_aarch64_regs and La_aarch64_retval are expanded to include
>     both x8 and the full sized NEON V registers, as defined by the
>     ABI.
> 
>   * dl_runtime_profile needed to extract registers saved by
>     _dl_runtime_resolve and put them into the new correctly sized
>     La_aarch64_regs structure.
> 
>   * The LAV_CURRENT check is change to only accept new audit modules
>     to avoid the undefined behavior of not save/restore x8.
> 
>   * Different than other architectures, audit modules older than
>     LAV_CURRENT are rejected (both La_aarch64_regs and La_aarch64_retval
>     changed their layout and the it does worth the to support multiple
>     audit interface with the inherent aarch64 issues).
> 
>   * A new field is also reserved on both La_aarch64_regs and
>     La_aarch64_retval to support variant pcs symbols.
> 
> Similar to x86, a new La_aarch64_vector type to represent the NEON
> register is added on the La_aarch64_regs (so each type can be accessed
> directly).
> 
> Since LAV_CURRENT was already bumped to support bind-now, there is
> no need to increase it again.
> 
> Checked on aarch64-linux-gnu.
> 
> Co-authored-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>

Please update the copyright years in new files.
With that fixed this looks good to me.

Reviewed-by: Szabolcs Nagy <szabolcs.nagy@arm.com>

  reply	other threads:[~2022-01-18 13:36 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-17 21:31 [PATCH v10 0/4] Multiple rtld-audit fixes Adhemerval Zanella
2022-01-17 21:31 ` [PATCH v10 1/4] elf: Add la_activity during application exit Adhemerval Zanella
2022-01-18 11:29   ` Florian Weimer
2022-01-18 13:10     ` Adhemerval Zanella
2022-01-21 10:50       ` Florian Weimer
2022-01-21 10:50   ` Florian Weimer
2022-01-24 12:53     ` Adhemerval Zanella
2022-01-17 21:31 ` [PATCH v10 2/4] elf: Fix initial-exec TLS access on audit modules (BZ #28096) Adhemerval Zanella
2022-01-18 11:33   ` Florian Weimer
2022-01-18 12:58     ` Adhemerval Zanella
2022-01-18 13:02       ` Florian Weimer
2022-01-18 13:26         ` Adhemerval Zanella
2022-01-18 13:29           ` Florian Weimer
2022-01-18 13:33             ` Adhemerval Zanella
2022-01-18 13:46               ` Adhemerval Zanella
2022-01-18 13:47                 ` Adhemerval Zanella
2022-01-17 21:31 ` [PATCH v10 3/4] elf: Issue la_symbind for bind-now (BZ #23734) Adhemerval Zanella
2022-01-21 11:18   ` Florian Weimer
2022-01-17 21:31 ` [PATCH v10 4/4] elf: Fix runtime linker auditing on aarch64 (BZ #26643) Adhemerval Zanella
2022-01-18 13:36   ` Szabolcs Nagy [this message]
2022-01-21 11:19   ` Florian Weimer

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=20220118133621.GG3294453@arm.com \
    --to=szabolcs.nagy@arm.com \
    --cc=adhemerval.zanella@linaro.org \
    --cc=carlos@redhat.com \
    --cc=jma14@rice.edu \
    --cc=johnmc@rice.edu \
    --cc=libc-alpha@sourceware.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).