ata_pci_bmdma_prepare_host(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… ata_pci_bmdma_prepare_host(9) β€” straight out of the Kernel API Manual, bestie

okay so picture this: you're deep in ./drivers/ata, the vibes are immaculate, and you need a whole PCI BMDMA ATA host set up. that's literally what this function is for. she's a helper. she's iconic. let's get into it πŸ’–


✨ NAME ✨

ata_pci_bmdma_prepare_host β€” the helper that preps your PCI BMDMA ATA host, no cap 🫢


🌸 SYNOPSIS 🌸

int ata_pci_bmdma_prepare_host (struct pci_dev *pdev , const struct
       ata_port_info * const * ppi , struct ata_host **r_host );

πŸŽ€ ARGUMENTS πŸŽ€

  • pdev β€” the target PCI device. this is the one we're setting up for, mwah πŸ’‹
  • ppi β€” an array of port_info, and bestie listen: it must be enough for two ports. two. not one. not three. iykyk πŸ‘€
  • r_host β€” the out argument where the initialized ATA host lands. she gets written into this pointer, periodt ✨

πŸ¦‹ DESCRIPTION πŸ¦‹

so what does she actually do? she's the helper that allocates a BMDMA ATA host for pdev, acquires all the PCI resources, and initializes it accordingly β€” all in one go. one single function call. main character energy fr fr πŸ”₯

πŸ”’ LOCKING πŸ”’

inherited from the calling layer. and yes, it may sleep 😴 β€” so don't go calling her from some atomic context and then act surprised, okay?


⭐ RETURN ⭐

  • 0 on success β€” slay πŸ’…
  • -errno otherwise β€” not slay, but at least you know what went wrong πŸ™ˆ

🌈 SEE ALSO 🌈

okay this list is LONG but we do not skip a single one, because every single entry is a baddie in the kernel file ./drivers/ata/libata-sff.c. buckle up, bestie πŸŽ€

see? told you we weren't skipping any πŸ’€ every last one is here.


okay that's the whole page, bestie 🧚 this little beauty lives over in ./drivers/ata, dropped October 2026, and she goes by ata_pci_bmdma_prepare_host(9) β€” go forth and prepare those hosts, you absolute legend πŸ‘‘πŸ’œ

πŸ“¦ where this page comes from