This function handles not only modversions, but also unresolved symbols, export symbols, etc. Rename it to a more proper function name. While I was here, I also added the 'const' qualifier to *sym.
Showing the changes to scripts (1 of 1 file). Show all
Unified · Split
| @@ -683,8 +683,8 @@ static int ignore_undef_symbol(struct elf_info *info, const char *symname) · 682 unmodified lines | ||
| 683 | 683 | return 0; |
| 684 | 684 | } |
| 685 | 685 | |
| 686 | −static void handle_modversions(struct module *mod, struct elf_info *info, | |
| 687 | − Elf_Sym *sym, const char *symname) | |
| 686 | +static void handle_symbol(struct module *mod, struct elf_info *info, | |
| 687 | + const Elf_Sym *sym, const char *symname) | |
| 688 | 688 | { |
| 689 | 689 | unsigned int crc; |
| 690 | 690 | enum export export; |
| @@ -2051,7 +2051,7 @@ static void read_symbols(const char *modname) · 1360 unmodified lines | ||
| 2051 | 2051 | for (sym = info.symtab_start; sym < info.symtab_stop; sym++) { |
| 2052 | 2052 | symname = remove_dot(info.strtab + sym->st_name); |
| 2053 | 2053 | |
| 2054 | − handle_modversions(mod, &info, sym, symname); | |
| 2054 | + handle_symbol(mod, &info, sym, symname); | |
| 2055 | 2055 | handle_moddevtable(mod, &info, sym, symname); |
| 2056 | 2056 | } |
| 2057 | 2057 | |