acpi_dma_get_range(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ acpi_dma_get_range β€” bestie, let's get your DMA parameters ✨

Okay so real talk, this one is from the Kernel API Manual (section 9, the kernel API girlies πŸ’…) and it's literally called acpi_dma_get_range. It's giving "small function, big job" and I'm obsessed.


🌸 NAME 🌸

acpi_dma_get_range β€” Get device DMA parameters. That's it, that's the whole vibe. It goes and fetches the DMA deets for a device πŸŽ€


πŸ¦‹ SYNOPSIS πŸ¦‹

int acpi_dma_get_range (struct device *dev , const struct bus_dma_region **map );

Look at her. Two arguments, one int return. Iconic behavior honestly πŸ‘‘


πŸ’œ ARGUMENTS πŸ’œ

  • dev β€” the device you wanna configure. She's the main character here, the one getting her DMA situation sorted 🫢
  • map β€” pointer to the DMA ranges result. Think of it as the lil basket where the answer gets dropped off 🧺

🌈 DESCRIPTION 🌈

So what does she actually do? She evaluates the DMA regions, and on parsing success she returns a pointer to those DMA regions. Slay πŸ’…

⚠️ But bestie, listen β€” on failure she does not update the passed in values. Not even a little. The values you handed in stay exactly how you left them, no cap. So don't go reading map like it's fresh data if things went sideways πŸ™ˆ

The return value, in her own words:

  • 0 on success β€” we ate, no crumbs πŸ”₯
  • < 0 on failure β€” it's giving flop, handle it 😭

🧚 SEE ALSO 🧚

Kernel file ./drivers/acpi/scan.c β€” that's where she lives, go say hi πŸ’–

And her whole friend group, the ACPI scan girlies, all linked up:


πŸ‘‘ Sign-off πŸ‘‘

That's the whole page, bestie! She lives in ./drivers/acpi, this particular glow-up is dated October 2026, and she answers to acpi_dma_get_range(9) β€” remember the manual section, iykyk πŸ“–βœ¨

Go get those DMA ranges. Periodt πŸ’…πŸ’–

πŸ“¦ where this page comes from