git.openpandora.org
/
pandora-u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b956637
)
tools: relocate-rela: Use global variables
author
Michal Simek
<michal.simek@amd.com>
Fri, 24 Jun 2022 12:14:59 +0000
(14:14 +0200)
committer
Michal Simek
<michal.simek@amd.com>
Fri, 24 Jun 2022 12:14:59 +0000
(14:14 +0200)
Declare rela_start/end and text_base as global variables. It will help with
using these variables for ELF decoding.
Signed-off-by: Michal Simek <michal.simek@amd.com>
Link:
https://lore.kernel.org/r/7485b163e92f8f3f754c35f7c88c3314f2212efd.1655299267.git.michal.simek@amd.com
tools/relocate-rela.c
patch
|
blob
|
history
diff --git
a/tools/relocate-rela.c
b/tools/relocate-rela.c
index
8839871
..
67a138a
100644
(file)
--- a/
tools/relocate-rela.c
+++ b/
tools/relocate-rela.c
@@
-20,6
+20,8
@@
#define R_AARCH64_RELATIVE 1027
#endif
+static uint64_t rela_start, rela_end, text_base;
+
static const bool debug_en;
static void debug(const char *fmt, ...)
@@
-63,7
+65,7
@@
int main(int argc, char **argv)
{
FILE *f;
int i, num;
- uint64_t
rela_start, rela_end, text_base,
file_size;
+ uint64_t file_size;
if (argc != 5) {
fprintf(stderr, "Statically apply ELF rela relocations\n");