dax_kmem_do_hotremove(9)
π dax_kmem_do_hotremove β the kernel API manual, section 9, bestie
okay so welcome to dax_kmem_do_hotremove(9) β it's a real one from the Kernel API Manual (section 9, the fancy kernel-functions section, iykyk) and honestly? she's giving cleanup era. let's get into it π
β¨ NAME β¨
dax_kmem_do_hotremove β hot-remove memory for dax kmem device. that's it, that's the whole vibe: we're taking memory out of a dax kmem device, live, no shutdown, no drama πΈ
π¦ SYNOPSIS π¦
int dax_kmem_do_hotremove (struct dev_dax *dev_dax , struct
dax_kmem_data *data );
so she takes two things and hands you back an int. classic. π
π ARGUMENTS π
dev_daxβ thedev_daxinstance. like, the actual device we're doing this whole hot-remove situation to π«Άdataβ thedax_kmem_datastructure with resource tracking. she's the one keeping receipts on the resources, so don't lose her.
π₯ DESCRIPTION π₯
okay so this is the important part, listen up bestie π
dax_kmem_do_hotremove offlines and removes every currently-added range in the dev_dax region atomically. and when I say atomically I mean it fr fr: either all ranges are offlined and removed, or none are β and in that case the device is returned to its prior state. all-or-nothing. no half-finished messes, no "oops we removed three out of five ranges," none of that π
it returns 0 on success, or a negative errno on failure. so like, check that return value, bestie, don't just vibe past it π
π SEE ALSO π
the kernel file ./drivers/dax/kmem.c β that's the main character, that's where she lives. and also go say hi to her friends:
π§ little reminder: this whole thing is atomic, so if any part of the removal fails, nothing gets removed. the device goes right back to how it was. iconic behaviour honestly.
and that's the page!! sourced from ./drivers/dax, October 2026, dax_kmem_do_hotremove(9) β slay, go hot-remove some memory responsibly, mwah πβπ
π¦ 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