public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Alan Modra <amodra@gmail.com>
To: Szabolcs Nagy <szabolcs.nagy@arm.com>
Cc: binutils@sourceware.org
Subject: Re: [PATCH v2 1/2] aarch64: Fix DT_RELR support with discarded sections
Date: Thu, 6 Jun 2024 10:47:04 +0930	[thread overview]
Message-ID: <ZmEOELJjRy0_jx_D@squeak.grove.modra.org> (raw)
In-Reply-To: <164ea78d38dc1ee3fffe0380df23092fd3f8541d.1717522516.git.szabolcs.nagy@arm.com>

On Tue, Jun 04, 2024 at 06:41:34PM +0100, Szabolcs Nagy wrote:
> --- a/bfd/elfnn-aarch64.c
> +++ b/bfd/elfnn-aarch64.c
> @@ -9327,6 +9327,10 @@ record_relr_non_got_relocs (bfd *input_bfd, struct bfd_link_info *info,
>      return true;
>    if (sec->alignment_power == 0)
>      return true;
> +  if (!bfd_is_abs_section (sec)
> +      && bfd_is_abs_section (sec->output_section))
> +    /* Input section has been discarded.  */
> +    return true;

I think you should be using discarded_section here and in
elfNN_aarch64_late_size_sections.

>    sreloc = elf_section_data (sec)->sreloc;
>    if (sreloc == NULL)
>      return true;
> -- 
> 2.25.1

-- 
Alan Modra

  reply	other threads:[~2024-06-06  1:17 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-04 17:41 [PATCH v2 0/2] aarch64: fix DT_RELR " Szabolcs Nagy
2024-06-04 17:41 ` [PATCH v2 1/2] aarch64: Fix DT_RELR support " Szabolcs Nagy
2024-06-06  1:17   ` Alan Modra [this message]
2024-06-06  7:57     ` Szabolcs Nagy
2024-06-04 17:41 ` [PATCH v2 2/2] aarch64: Test DT_RELR " Szabolcs Nagy
2024-06-06  1:23   ` Alan Modra
2024-06-06  8:08     ` Szabolcs Nagy

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=ZmEOELJjRy0_jx_D@squeak.grove.modra.org \
    --to=amodra@gmail.com \
    --cc=binutils@sourceware.org \
    --cc=szabolcs.nagy@arm.com \
    /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).