acpi_os_unmap_iomem(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… acpi_os_unmap_iomem πŸ’…

okay so bestie, this one lives in the Kernel API Manual and it's literally the "un-reference a mapping" girlie β€” the counterpart to mapping stuff in the first place. No cap.


✨ NAME ✨

acpi_os_unmap_iomem β€” drop a memory mapping reference. that's it, that's the whole vibe πŸŽ€


πŸ¦‹ SYNOPSIS πŸ¦‹

void __ref acpi_os_unmap_iomem (void __iomem *virt , acpi_size size );

like, look at her. void __ref, two args, she's iconic. πŸ‘‘


🌸 ARGUMENTS 🌸

  • virt β€” start of the address range to drop a reference to. the beginning of the situation, fr fr.
  • size β€” size of the address range to drop a reference to. how much of it we're un-referencing πŸ’–

🌈 DESCRIPTION 🌈

so here's what she does: she looks up the given virtual address range in the list of existing ACPI memory mappings, drops a reference to it, and if there are no more active references to it, she queues it up for later removal. it's giving "bye bestie, you're on the cleanup list" 🧹✨

lowkey important: later removal. she doesn't nuke it on the spot, she queues it. that's the whole point of the reference counting, iykyk.

during early init β€” and this is the key part, so pay attention πŸ™ˆ β€” when acpi_permanent_mmap has not been set yet, this routine simply calls __acpi_unmap_table to get the job done. no reference-counting drama, just straight to the function. periodt.

and because __acpi_unmap_table is an __init function, the __ref annotation is needed here. that's the whole reason __ref is in the synopsis β€” it's not decoration, it's required so the early-init call path works πŸ’…


πŸ’œ SEE ALSO πŸ’œ

go read acpi_os_map_iomem(9) first if you haven't, she's the main character, this page is the sequel 🫢


mwah πŸ’‹ that's the page! sourced from ./drivers/acpi, dated October 2026, and yes she's still acpi_os_unmap_iomem(9) in the Kernel API Manual β€” go drop those references responsibly, bestie πŸ“β­

πŸ“¦ where this page comes from