linux-5.4: backport modpost upstream patches
[openwrt/staging/jogo.git] / target / linux / generic / hack-5.4 / 204-module_strip.patch
index d37dfd4f98a7e6db6b78ef33c1971aa9be0b5c8d..8b84ddd7f07e5e418fd376decc41a970ba451f8a 100644 (file)
@@ -135,7 +135,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
  
 --- a/scripts/mod/modpost.c
 +++ b/scripts/mod/modpost.c
-@@ -2051,7 +2051,9 @@ static void read_symbols(const char *mod
+@@ -2056,7 +2056,9 @@ static void read_symbols(const char *mod
                symname = remove_dot(info.strtab + sym->st_name);
  
                handle_modversions(mod, &info, sym, symname);
@@ -145,7 +145,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
        }
  
        /* Apply symbol namespaces from __kstrtabns_<symbol> entries. */
-@@ -2265,8 +2267,10 @@ static void add_header(struct buffer *b,
+@@ -2270,8 +2272,10 @@ static void add_header(struct buffer *b,
        buf_printf(b, "\n");
        buf_printf(b, "BUILD_SALT;\n");
        buf_printf(b, "\n");
@@ -156,7 +156,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
        buf_printf(b, "\n");
        buf_printf(b, "__visible struct module __this_module\n");
        buf_printf(b, "__section(.gnu.linkonce.this_module) = {\n");
-@@ -2283,8 +2287,10 @@ static void add_header(struct buffer *b,
+@@ -2288,8 +2292,10 @@ static void add_header(struct buffer *b,
  
  static void add_intree_flag(struct buffer *b, int is_intree)
  {
@@ -167,7 +167,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
  }
  
  /* Cannot check for assembler */
-@@ -2297,8 +2303,10 @@ static void add_retpoline(struct buffer
+@@ -2302,8 +2308,10 @@ static void add_retpoline(struct buffer
  
  static void add_staging_flag(struct buffer *b, const char *name)
  {
@@ -178,7 +178,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
  }
  
  /**
-@@ -2382,11 +2390,13 @@ static void add_depends(struct buffer *b
+@@ -2387,11 +2395,13 @@ static void add_depends(struct buffer *b
  
  static void add_srcversion(struct buffer *b, struct module *mod)
  {
@@ -192,7 +192,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
  }
  
  static void write_if_changed(struct buffer *b, const char *fname)
-@@ -2656,7 +2666,9 @@ int main(int argc, char **argv)
+@@ -2661,7 +2671,9 @@ int main(int argc, char **argv)
                add_staging_flag(&buf, mod->name);
                err |= add_versions(&buf, mod);
                add_depends(&buf, mod);