aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2021-01-13 15:17:56 +1030
committerAlan Modra <amodra@gmail.com>2021-01-13 22:01:20 +1030
commit8c4645b4887660eb704f152f2a14c5108d56c9d7 (patch)
treef5fb38cd1af37a883cf92962f7b2bd39f758cf3b
parent2ce40d1a5184271aa01675b55be8c04dfc320eee (diff)
downloadgdb-8c4645b4887660eb704f152f2a14c5108d56c9d7.zip
gdb-8c4645b4887660eb704f152f2a14c5108d56c9d7.tar.gz
gdb-8c4645b4887660eb704f152f2a14c5108d56c9d7.tar.bz2
Remove sflag_info param from wild callback functions
* ldlang.h (callback_t): Remove flag_info function parameter. * ldlang.c (walk_wild_consider_section): Adjust to suit. (walk_wild_section_general): Likewise. (output_section_callback_fast, output_section_callback): Likewise. (check_section_callback, gc_section_callback): Likewise. (find_relro_section_callback): Likewise.
-rw-r--r--ld/ChangeLog9
-rw-r--r--ld/ldlang.c13
-rw-r--r--ld/ldlang.h3
3 files changed, 14 insertions, 11 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog
index 80c232d..0224aef 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -1,3 +1,12 @@
+2021-01-13 Alan Modra <amodra@gmail.com>
+
+ * ldlang.h (callback_t): Remove flag_info function parameter.
+ * ldlang.c (walk_wild_consider_section): Adjust to suit.
+ (walk_wild_section_general): Likewise.
+ (output_section_callback_fast, output_section_callback): Likewise.
+ (check_section_callback, gc_section_callback): Likewise.
+ (find_relro_section_callback): Likewise.
+
2021-01-12 H.J. Lu <hongjiu.lu@intel.com>
PR binutils/26792
diff --git a/ld/ldlang.c b/ld/ldlang.c
index 8cbeda6..4d3560f 100644
--- a/ld/ldlang.c
+++ b/ld/ldlang.c
@@ -320,7 +320,7 @@ walk_wild_consider_section (lang_wild_statement_type *ptr,
if (walk_wild_file_in_exclude_list (sec->spec.exclude_name_list, file))
return;
- (*callback) (ptr, sec, s, ptr->section_flag_list, file, data);
+ (*callback) (ptr, sec, s, file, data);
}
/* Lowest common denominator routine that can handle everything correctly,
@@ -339,7 +339,7 @@ walk_wild_section_general (lang_wild_statement_type *ptr,
{
sec = ptr->section_list;
if (sec == NULL)
- (*callback) (ptr, sec, s, ptr->section_flag_list, file, data);
+ (*callback) (ptr, sec, s, file, data);
while (sec != NULL)
{
@@ -566,7 +566,6 @@ static void
output_section_callback_fast (lang_wild_statement_type *ptr,
struct wildcard_list *sec,
asection *section,
- struct flag_info *sflag_list ATTRIBUTE_UNUSED,
lang_input_statement_type *file,
void *output)
{
@@ -2823,7 +2822,6 @@ static void
output_section_callback (lang_wild_statement_type *ptr,
struct wildcard_list *sec,
asection *section,
- struct flag_info *sflag_info,
lang_input_statement_type *file,
void *output)
{
@@ -2844,14 +2842,14 @@ output_section_callback (lang_wild_statement_type *ptr,
of the current list. */
if (before == NULL)
- lang_add_section (&ptr->children, section, sflag_info, os);
+ lang_add_section (&ptr->children, section, ptr->section_flag_list, os);
else
{
lang_statement_list_type list;
lang_statement_union_type **pp;
lang_list_init (&list);
- lang_add_section (&list, section, sflag_info, os);
+ lang_add_section (&list, section, ptr->section_flag_list, os);
/* If we are discarding the section, LIST.HEAD will
be NULL. */
@@ -2877,7 +2875,6 @@ static void
check_section_callback (lang_wild_statement_type *ptr ATTRIBUTE_UNUSED,
struct wildcard_list *sec ATTRIBUTE_UNUSED,
asection *section,
- struct flag_info *sflag_info ATTRIBUTE_UNUSED,
lang_input_statement_type *file ATTRIBUTE_UNUSED,
void *output)
{
@@ -7490,7 +7487,6 @@ static void
gc_section_callback (lang_wild_statement_type *ptr,
struct wildcard_list *sec,
asection *section,
- struct flag_info *sflag_info ATTRIBUTE_UNUSED,
lang_input_statement_type *file ATTRIBUTE_UNUSED,
void *data ATTRIBUTE_UNUSED)
{
@@ -7563,7 +7559,6 @@ static void
find_relro_section_callback (lang_wild_statement_type *ptr ATTRIBUTE_UNUSED,
struct wildcard_list *sec ATTRIBUTE_UNUSED,
asection *section,
- struct flag_info *sflag_info ATTRIBUTE_UNUSED,
lang_input_statement_type *file ATTRIBUTE_UNUSED,
void *data)
{
diff --git a/ld/ldlang.h b/ld/ldlang.h
index 718bcee..205c305 100644
--- a/ld/ldlang.h
+++ b/ld/ldlang.h
@@ -349,8 +349,7 @@ bfd_input_just_syms (const bfd *abfd)
typedef struct lang_wild_statement_struct lang_wild_statement_type;
typedef void (*callback_t) (lang_wild_statement_type *, struct wildcard_list *,
- asection *, struct flag_info *,
- lang_input_statement_type *, void *);
+ asection *, lang_input_statement_type *, void *);
typedef void (*walk_wild_section_handler_t) (lang_wild_statement_type *,
lang_input_statement_type *,