summaryrefslogtreecommitdiff
path: root/bfd/elf32-spu.c
diff options
context:
space:
mode:
Diffstat (limited to 'bfd/elf32-spu.c')
-rw-r--r--bfd/elf32-spu.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/bfd/elf32-spu.c b/bfd/elf32-spu.c
index 16f9450454..13d3a53104 100644
--- a/bfd/elf32-spu.c
+++ b/bfd/elf32-spu.c
@@ -4906,8 +4906,9 @@ spu_elf_relocate_section (bfd *output_bfd,
continue;
/* Change "a rt,ra,rb" to "ai rt,ra,0". */
- if (r_type == R_SPU_ADD_PIC && h != NULL
- && (h->def_regular || ELF_COMMON_DEF_P (h)))
+ if (r_type == R_SPU_ADD_PIC
+ && h != NULL
+ && !(h->def_regular || ELF_COMMON_DEF_P (h)))
{
bfd_byte *loc = contents + rel->r_offset;
loc[0] = 0x1c;