Lines Matching refs:mod
13 unsigned long module_emit_got_entry(struct module *mod, unsigned long val) in module_emit_got_entry() argument
15 struct mod_section *got_sec = &mod->arch.got; in module_emit_got_entry()
32 unsigned long module_emit_plt_entry(struct module *mod, unsigned long val) in module_emit_plt_entry() argument
34 struct mod_section *got_plt_sec = &mod->arch.got_plt; in module_emit_plt_entry()
36 struct mod_section *plt_sec = &mod->arch.plt; in module_emit_plt_entry()
91 char *secstrings, struct module *mod) in module_frob_arch_sections() argument
102 mod->arch.plt.shdr = sechdrs + i; in module_frob_arch_sections()
104 mod->arch.got.shdr = sechdrs + i; in module_frob_arch_sections()
106 mod->arch.got_plt.shdr = sechdrs + i; in module_frob_arch_sections()
109 if (!mod->arch.plt.shdr) { in module_frob_arch_sections()
110 pr_err("%s: module PLT section(s) missing\n", mod->name); in module_frob_arch_sections()
113 if (!mod->arch.got.shdr) { in module_frob_arch_sections()
114 pr_err("%s: module GOT section(s) missing\n", mod->name); in module_frob_arch_sections()
117 if (!mod->arch.got_plt.shdr) { in module_frob_arch_sections()
118 pr_err("%s: module GOT.PLT section(s) missing\n", mod->name); in module_frob_arch_sections()
138 mod->arch.plt.shdr->sh_type = SHT_NOBITS; in module_frob_arch_sections()
139 mod->arch.plt.shdr->sh_flags = SHF_EXECINSTR | SHF_ALLOC; in module_frob_arch_sections()
140 mod->arch.plt.shdr->sh_addralign = L1_CACHE_BYTES; in module_frob_arch_sections()
141 mod->arch.plt.shdr->sh_size = (num_plts + 1) * sizeof(struct plt_entry); in module_frob_arch_sections()
142 mod->arch.plt.num_entries = 0; in module_frob_arch_sections()
143 mod->arch.plt.max_entries = num_plts; in module_frob_arch_sections()
145 mod->arch.got.shdr->sh_type = SHT_NOBITS; in module_frob_arch_sections()
146 mod->arch.got.shdr->sh_flags = SHF_ALLOC; in module_frob_arch_sections()
147 mod->arch.got.shdr->sh_addralign = L1_CACHE_BYTES; in module_frob_arch_sections()
148 mod->arch.got.shdr->sh_size = (num_gots + 1) * sizeof(struct got_entry); in module_frob_arch_sections()
149 mod->arch.got.num_entries = 0; in module_frob_arch_sections()
150 mod->arch.got.max_entries = num_gots; in module_frob_arch_sections()
152 mod->arch.got_plt.shdr->sh_type = SHT_NOBITS; in module_frob_arch_sections()
153 mod->arch.got_plt.shdr->sh_flags = SHF_ALLOC; in module_frob_arch_sections()
154 mod->arch.got_plt.shdr->sh_addralign = L1_CACHE_BYTES; in module_frob_arch_sections()
155 mod->arch.got_plt.shdr->sh_size = (num_plts + 1) * sizeof(struct got_entry); in module_frob_arch_sections()
156 mod->arch.got_plt.num_entries = 0; in module_frob_arch_sections()
157 mod->arch.got_plt.max_entries = num_plts; in module_frob_arch_sections()