modules: make arch's use default loader hooks

This patch removes all the module loader hook implementations in the
architecture specific code where the functionality is the same as that
now provided by the recently added default hooks.

Signed-off-by: Jonas Bonn <[email protected]>
Acked-by: Mike Frysinger <[email protected]>
Acked-by: Geert Uytterhoeven <[email protected]>
Tested-by: Michal Simek <[email protected]>
Signed-off-by: Rusty Russell <[email protected]>
This commit is contained in:
Jonas Bonn 2011-06-30 21:22:12 +02:00 • committed by Rusty Russell
commit 66574cc054
26 changed files with 12 additions and 777 deletions

View file

@ -24,26 +24,6 @@
#undef DEBUG_RELOCATE
void *module_alloc(unsigned long size)
{
if (size == 0)
return NULL;
return vmalloc_exec(size);
}
void module_free(struct module *mod, void *module_region)
{
vfree(module_region);
}
int module_frob_arch_sections(Elf32_Ehdr *hdr,
Elf32_Shdr *sechdrs,
char *secstrings,
struct module *mod)
{
return 0;
}
static int
decode_calln_opcode (unsigned char *location)
{
@ -66,18 +46,6 @@ decode_l32r_opcode (unsigned char *location)
#endif
}
int apply_relocate(Elf32_Shdr *sechdrs,
const char *strtab,
unsigned int symindex,
unsigned int relsec,
struct module *mod)
{
printk(KERN_ERR "module %s: REL RELOCATION unsupported\n",
mod->name);
return -ENOEXEC;
}
int apply_relocate_add(Elf32_Shdr *sechdrs,
const char *strtab,
unsigned int symindex,
@ -222,14 +190,3 @@ int apply_relocate_add(Elf32_Shdr *sechdrs,
}
return 0;
}
int module_finalize(const Elf_Ehdr *hdr,
const Elf_Shdr *sechdrs,
struct module *mod)
{
return 0;
}
void module_arch_cleanup(struct module *mod)
{
}