swiotlb_find_pool(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… swiotlb_find_pool(9) πŸ’…

okay so bestie, welcome to the Kernel API Manual ✨ β€” today's main character is swiotlb_find_pool, and honestly? she's a little detective and she ate πŸ”πŸ’–


🌸 NAME 🌸

swiotlb_find_pool β€” literally finds the swiotlb pool that a physical address belongs to πŸŽ€ iykyk


✨ SYNOPSIS ✨

struct io_tlb_pool * swiotlb_find_pool (struct device *dev , phys_addr_t paddr );

that's the whole vibe. two args in, one pointer out 🫢


πŸ¦‹ ARGUMENTS πŸ¦‹

  • dev β€” the device that has mapped the buffer. like, which device's business is this? πŸ‘€ that one.
  • paddr β€” a physical address that lives inside the DMA buffer. the address in question, the one we're investigating πŸ”Ž

πŸ’œ DESCRIPTION πŸ’œ

so basically she takes paddr and finds the swiotlb pool that paddr points into. that's it. that's the job. no cap, that's the entire description and she does it flawlessly πŸ’…


⭐ RETURN ⭐

  • the pool address β€” if paddr points into a bounce buffer πŸŽ‰ slay
  • NULL β€” if paddr does not point into a bounce buffer 🫠
and because of that lil NULL situation, you can literally use this function to figure out whether paddr denotes a swiotlb bounce buffer or not. it's giving "two functions in a trench coat" 😭 iconic

🌈 SEE ALSO 🌈

  • kernel file ./include/linux/swiotlb.h
  • struct io_tlb_pool(9)
  • struct io_tlb_mem(9)

go read those too, bestie, they're the supporting cast πŸ‘‘


mwah πŸ’‹ that's the whole page β€” brought to you by ./include/linux, the October 2026 edition, and the letter swiotlb_find_pool(9) πŸ’–βœ¨ go find those pools, queen πŸ§šβ€β™€οΈ

πŸ“¦ where this page comes from