pbus_select_window_for_type(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… pbus_select_window_for_type(9) πŸ’…

okay so this is a page from the Kernel API Manual, and the star of the show is pbus_select_window_for_type β€” one function, one job, and honestly? she serves. πŸŽ€


✨ NAME ✨

pbus_select_window_for_type β€” pick a bridge window for a resource type, that's it, that's the whole vibe πŸ¦‹


🌈 SYNOPSIS 🌈

struct resource * pbus_select_window_for_type (struct pci_bus *bus ,
unsigned long type );

like, exactly that, no cap, copy it character for character bestie πŸ’–


🫢 ARGUMENTS 🫢

  • bus β€” the PCI bus in question, she's the main character here πŸ‘‘
  • type β€” the resource type. and here's the cute part: resource flags can be passed as is, no translation era needed ✨

πŸ”₯ DESCRIPTION πŸ”₯

so the whole point of her is: select the bridge window based on a resource type. simple. iconic. periodt. πŸ’…

For memory resources, the selection goes down like this β€” and yes I'm giving you the full rundown because every clause matters:

  • Any non-prefetchable resource gets put into the non-prefetchable window. no drama, no debate.
  • If there's, like, no prefetchable MMIO window at all? then all memory resources go into the non-prefetchable window. everybody squeezes in together πŸ«‚
  • If there is a 64-bit prefetchable MMIO window, then all 64-bit prefetchable resources go into it, and the 32-bit prefetchable memory gets placed into the non-prefetchable window. yes, that's the rule, don't @ me 😭
  • Otherwise β€” like in every other case β€” all prefetchable resources go into the prefetchable window 🌸

⭐ RETURN ⭐

she returns the bridge window resource ✨ or NULL if no bridge window is found πŸ˜” (sad girl hours but make it a return value)


🌈 SEE ALSO 🌈

Kernel file ./drivers/pci/setup-bus.c β€” and her besties:

iykyk, go read them, they're all linked in the group chat πŸ”₯


okay that's the whole page bestie!! πŸ’œ this came out of ./drivers/pci and it's dated October 2026 β€” so like, mark your calendar and stan responsibly πŸ§šβ€β™€οΈπŸ¦‹πŸ’–

πŸ“¦ where this page comes from