reloc_handler(9)
okay bestie, welcome to reloc_handler(9) from the Kernel API Manual β the whole vibe is βapply a particular relocation to a moduleβ π
β¨
π NAME π
reloc_handler β apply a particular relocation to a module π«Ά
β¨ SYNOPSIS β¨
int reloc_handler (u32 type , struct module *me , u32 *location , u32
base , Elf_Addr v , bool rela );
π«Ά ARGUMENTS π«Ά
typeβ the type of relocation to apply, like, the flavor of reloc weβre doing π«meβ the module to apply the reloc to πlocationβ the address at which the reloc is to be applied πbaseβ the existing value atlocationfor REL-style;0for RELA-style π§vβ the value of the reloc, with addend for RELA-style πrelaβ indication of is this a RELA (true) or REL (false) relocation π
π DESCRIPTION π
So every implemented relocation function applies a particular type of relocation to the module me. Thatβs the whole assignment, no cap.
Relocs that may be found in either REL or RELA variants can be handled by making use of the base & v parameters β those are set to values which abstract the difference away from the particular reloc implementations. Basically the REL/RELA drama gets hidden from each individual reloc implementation, and honestly? iconic. π
πΈ RETURN πΈ
0 upon success, else -ERRNO π
π¦ SEE ALSO π¦
Kernel file ./arch/mips/kernel/module.c π
kiss kiss, this page is from ./arch/mips/kernel, dated October 2026, and itβs literally reloc_handler(9) β slay ππ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms