summaryrefslogtreecommitdiffstats
path: root/binutils-2.25/bfd
diff options
context:
space:
mode:
authorMarcus Shawcroft <marcus.shawcroft@gmail.com>2015-03-20 18:49:29 +0000
committerAndrew Hsieh <andrewhsieh@google.com>2015-03-30 21:38:53 -0700
commitf0c15889b01b2505368776123956e308b610fb48 (patch)
treea3c77a7097ca60899287a49fa61ca2e922cdbb96 /binutils-2.25/bfd
parent568a7f8e3e43848c9927cda5dd926e00b3982254 (diff)
downloadtoolchain_binutils-f0c15889b01b2505368776123956e308b610fb48.zip
toolchain_binutils-f0c15889b01b2505368776123956e308b610fb48.tar.gz
toolchain_binutils-f0c15889b01b2505368776123956e308b610fb48.tar.bz2
[AArch64] Flip sense of erratum_835769_scan.
Change-Id: Ia79975e3ce9f1eca6ae092b4c9e2d92168fde1a0
Diffstat (limited to 'binutils-2.25/bfd')
-rw-r--r--binutils-2.25/bfd/elfnn-aarch64.c21
1 files changed, 13 insertions, 8 deletions
diff --git a/binutils-2.25/bfd/elfnn-aarch64.c b/binutils-2.25/bfd/elfnn-aarch64.c
index a84207c..0e47f27 100644
--- a/binutils-2.25/bfd/elfnn-aarch64.c
+++ b/binutils-2.25/bfd/elfnn-aarch64.c
@@ -2954,6 +2954,11 @@ elf_aarch64_compare_mapping (const void *a, const void *b)
return 0;
}
+
+/* Scan for cortex-a53 erratum 835769 sequence.
+
+ Return TRUE else FALSE on abnormal termination. */
+
static bfd_boolean
erratum_835769_scan (bfd *input_bfd,
struct bfd_link_info *info,
@@ -2968,7 +2973,7 @@ erratum_835769_scan (bfd *input_bfd,
unsigned int fix_table_size = *fix_table_size_p;
if (htab == NULL)
- return FALSE;
+ return TRUE;
for (section = input_bfd->sections;
section != NULL;
@@ -2988,7 +2993,7 @@ erratum_835769_scan (bfd *input_bfd,
if (elf_section_data (section)->this_hdr.contents != NULL)
contents = elf_section_data (section)->this_hdr.contents;
else if (! bfd_malloc_and_get_section (input_bfd, section, &contents))
- return TRUE;
+ return FALSE;
sec_data = elf_aarch64_section_data (section);
@@ -3021,7 +3026,7 @@ erratum_835769_scan (bfd *input_bfd,
sprintf
(stub_name,"__erratum_835769_veneer_%d", num_fixes);
else
- return TRUE;
+ return FALSE;
if (num_fixes == fix_table_size)
{
@@ -3032,7 +3037,7 @@ erratum_835769_scan (bfd *input_bfd,
sizeof (struct aarch64_erratum_835769_fix)
* fix_table_size);
if (fixes == NULL)
- return TRUE;
+ return FALSE;
}
fixes[num_fixes].input_bfd = input_bfd;
@@ -3052,7 +3057,7 @@ erratum_835769_scan (bfd *input_bfd,
*fixes_p = fixes;
*num_fixes_p = num_fixes;
*fix_table_size_p = fix_table_size;
- return FALSE;
+ return TRUE;
}
/* Find or create a stub section. */
@@ -3419,9 +3424,9 @@ elfNN_aarch64_size_stubs (bfd *output_bfd,
if (htab->fix_erratum_835769)
{
/* Scan for sequences which might trigger erratum 835769. */
- if (erratum_835769_scan (input_bfd, info, &erratum_835769_fixes,
- &num_erratum_835769_fixes,
- &erratum_835769_fix_table_size) != 0)
+ if (!erratum_835769_scan (input_bfd, info, &erratum_835769_fixes,
+ &num_erratum_835769_fixes,
+ &erratum_835769_fix_table_size))
goto error_ret_free_local;
}
}