From: "H.J. Lu" <hongjiu.lu@intel.com>
To: binutils@sourceware.org
Subject: PATCH: Don't check relocation overflow for x32.
Date: Wed, 16 Feb 2011 14:59:00 -0000 [thread overview]
Message-ID: <20110216145852.GA15249@intel.com> (raw)
I checked in this patch.
H.J.
---
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 1ab968c..7ce8b2f 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,9 @@
+2011-02-16 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elf64-x86-64.c (elf_x86_64_check_relocs): Check relocation
+ overflow only for ABI_64_P.
+ (elf_x86_64_relocate_section): Likewise.
+
2011-02-15 Tristan Gingold <gingold@adacore.com>
* vms-alpha.c (alpha_vms_link_add_archive_symbols): Add a comment.
diff --git a/bfd/elf64-x86-64.c b/bfd/elf64-x86-64.c
index 343abce..70fe9b1 100644
--- a/bfd/elf64-x86-64.c
+++ b/bfd/elf64-x86-64.c
@@ -1498,6 +1498,7 @@ not_pointer:
sections we don't care about, such as debug sections or
non-constant sections. */
if (info->shared
+ && ABI_64_P (abfd)
&& (sec->flags & SEC_ALLOC) != 0
&& (sec->flags & SEC_READONLY) != 0)
{
@@ -3148,6 +3149,7 @@ elf_x86_64_relocate_section (bfd *output_bfd,
for shared library since it may not be local when used
as function address. */
if (info->shared
+ && ABI_64_P (output_bfd)
&& h
&& h->def_regular
&& h->type == STT_FUNC
next reply other threads:[~2011-02-16 14:59 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-16 14:59 H.J. Lu [this message]
2011-02-17 13:52 ` H.J. Lu
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=20110216145852.GA15249@intel.com \
--to=hongjiu.lu@intel.com \
--cc=binutils@sourceware.org \
--cc=hjl.tools@gmail.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).