Andrew Geissler | 84ad7c5 | 2020-06-27 00:00:16 -0500 | [diff] [blame^] | 1 | From 50bd636604305329b302b9fbbb692795d26f5fa5 Mon Sep 17 00:00:00 2001 |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 2 | From: Nagaraju Mekala <nmekala@xilix.com> |
| 3 | Date: Wed, 28 Nov 2018 14:00:29 +0530 |
Andrew Geissler | 84ad7c5 | 2020-06-27 00:00:16 -0500 | [diff] [blame^] | 4 | Subject: [PATCH 24/43] Fixed the bug in the R_MICROBLAZE_64_NONE relocation. |
| 5 | It was adjusting only lower 16bits. |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 6 | |
| 7 | --- |
| 8 | bfd/elf32-microblaze.c | 4 ++-- |
| 9 | bfd/elf64-microblaze.c | 4 ++-- |
| 10 | 2 files changed, 4 insertions(+), 4 deletions(-) |
| 11 | |
| 12 | diff --git a/bfd/elf32-microblaze.c b/bfd/elf32-microblaze.c |
Andrew Geissler | 84ad7c5 | 2020-06-27 00:00:16 -0500 | [diff] [blame^] | 13 | index 035e71f311..2d8c062a42 100644 |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 14 | --- a/bfd/elf32-microblaze.c |
| 15 | +++ b/bfd/elf32-microblaze.c |
| 16 | @@ -2022,8 +2022,8 @@ microblaze_elf_relax_section (bfd *abfd, |
| 17 | sfix = calc_fixup (irel->r_offset + INST_WORD_SIZE, 0, sec); |
| 18 | efix = calc_fixup (target_address, 0, sec); |
| 19 | irel->r_addend -= (efix - sfix); |
| 20 | - microblaze_bfd_write_imm_value_32 (abfd, contents + irel->r_offset |
| 21 | - + INST_WORD_SIZE, irel->r_addend); |
| 22 | + microblaze_bfd_write_imm_value_64 (abfd, contents + irel->r_offset, |
| 23 | + irel->r_addend); |
| 24 | } |
| 25 | break; |
| 26 | } |
| 27 | diff --git a/bfd/elf64-microblaze.c b/bfd/elf64-microblaze.c |
Andrew Geissler | 84ad7c5 | 2020-06-27 00:00:16 -0500 | [diff] [blame^] | 28 | index 184b7d560d..ef6a87062b 100644 |
Brad Bishop | 26bdd44 | 2019-08-16 17:08:17 -0400 | [diff] [blame] | 29 | --- a/bfd/elf64-microblaze.c |
| 30 | +++ b/bfd/elf64-microblaze.c |
| 31 | @@ -2017,8 +2017,8 @@ microblaze_elf_relax_section (bfd *abfd, |
| 32 | sfix = calc_fixup (irel->r_offset + INST_WORD_SIZE, 0, sec); |
| 33 | efix = calc_fixup (target_address, 0, sec); |
| 34 | irel->r_addend -= (efix - sfix); |
| 35 | - microblaze_bfd_write_imm_value_32 (abfd, contents + irel->r_offset |
| 36 | - + INST_WORD_SIZE, irel->r_addend); |
| 37 | + microblaze_bfd_write_imm_value_64 (abfd, contents + irel->r_offset, |
| 38 | + irel->r_addend); |
| 39 | } |
| 40 | break; |
| 41 | } |
Andrew Geissler | 84ad7c5 | 2020-06-27 00:00:16 -0500 | [diff] [blame^] | 42 | -- |
| 43 | 2.17.1 |
| 44 | |