imr_raw_size(9)
π imr_raw_size(9) β like, the Kernel API Manual but make it make sense π
okay so bestie, we're in the <rainbow>Kernel API Manual</rainbow> today and the star of the show is imr_raw_size(9) β yes it's a section 9 page, yes it's kernel stuff, no you don't have to be scared. let's get into it β¨
πΈ NAME πΈ
imr_raw_size β literally just here to account for the IMR_ALIGN bytes that addr_hi appends. that's it. that's the whole job. she's a one-task icon π
π¦ SYNOPSIS π¦
size_t imr_raw_size (size_t size );
π ARGUMENTS π
sizeβ the input size, in bytes. just bytes. that's the unit. no cap π«Ά
β¨ DESCRIPTION β¨
so here's the tea β β IMR's addr_hi has a built-in offset of plus IMR_ALIGN (0x400) bytes from whatever value is sitting in the register. like, it just does. it's built in. main character behavior honestly π
because of that, we need to subtract IMR_ALIGN bytes from the input sizes. as a result. that's the consequence. that's what we do. periodt π
β RETURN β
the reduced size. that's it, that's the return value, she's smaller now and thriving π
π₯ SEE ALSO π₯
bestie the whole friend group is here, say hi π β kernel file ./arch/x86/platform/intel-quark/imr.c plus:
imr_is_enabled(9)imr_read(9)imr_write(9)imr_dbgfs_state_show(9)imr_debugfs_register(9)imr_check_params(9)imr_address_overlap(9)imr_add_range(9)__imr_remove_range(9)imr_remove_range(9)imr_clear(9)imr_fixup_memmap(9)imr_init(9)
ngl this page is short but she ate. remember:IMR_ALIGNis0x400, subtract it, done. iykyk π
and that's the whole vibe, bestie π§ from ./arch/x86/platform/intel-quark, dated October 2026, signed off on imr_raw_size(9) β mwah, go read some more kernel pages, you're doing amazing ππ
π¦ 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