mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-26 16:41:25 +00:00
modules: add default loader hook implementations
The module loader code allows architectures to hook into the code by providing a small number of entry points that each arch must implement. This patch provides __weakly linked generic implementations of these entry points for architectures that don't need to do anything special. Signed-off-by: Jonas Bonn <jonas@southpole.se> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
81c7413650
commit
74e08fcf7b
2 changed files with 55 additions and 1 deletions
|
@ -5,7 +5,12 @@
|
|||
#include <linux/module.h>
|
||||
#include <linux/elf.h>
|
||||
|
||||
/* These must be implemented by the specific architecture */
|
||||
/* These may be implemented by architectures that need to hook into the
|
||||
* module loader code. Architectures that don't need to do anything special
|
||||
* can just rely on the 'weak' default hooks defined in kernel/module.c.
|
||||
* Note, however, that at least one of apply_relocate or apply_relocate_add
|
||||
* must be implemented by each architecture.
|
||||
*/
|
||||
|
||||
/* Adjust arch-specific sections. Return 0 on success. */
|
||||
int module_frob_arch_sections(Elf_Ehdr *hdr,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue