STRUCT LOCAL_REG(9)
β¨ struct local_reg(9) β¨
okay bestie, welcome to the Kernel API Manual π this one's a little struct that describes one single register the way the local package sees it. that's it, that's the whole vibe. π
πΈ NAME πΈ
struct local_reg β a register as described in the local package view. literally just one register, but make it documented. π
π¦ SYNOPSIS π¦
struct local_reg {
int pkg;
u64 pbase;
u32 size;
u32 offset;
u8 width;
void __iomem *vbase;
u64 val;
};
no cap, that's the whole struct. now let's meet the members π«Ά
π Members π
okay so every field, one by one, no skipping:
pkgβ (input) the package where the register is located. which package? that one. π¦pbaseβ (input) the IP MMIO base physical address, in the local package view. physical, bestie, don't forget it. π₯sizeβ (input) the IP MMIO size.offsetβ (input) the register offset from the IP MMIO basepbase. so like, you start atpbaseand walkoffsetforward. πΆββοΈwidthβ (input) the register width in byte. yes, "byte", singular, that's what it says, i'm not touching it. πvbaseβ (internal) the IP MMIO base virtual address. internal only, so don't go poking at it from outside, iykyk. πvalβ (output) the register value. this is the one you actually came here for. π
quick vibe check:inputmeans you fill it in,internalmeans hands off,outputmeans it hands you something back. π§
π SEE ALSO π
- Kernel file
./drivers/edac/imh_base.cβ go read it, it's giving main character energy. β
and that's the page!! πΈ source/version: ./drivers/edac, dated October 2026 β slay, iconic, periodt. π
π
π¦ 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