pci_ats_queue_depth(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… pci_ats_queue_depth(9)

okay bestie, welcome to the Kernel API Manual β€” yes we're reading kernel docs together, that's the vibe now 🫢 this page is literally called pci_ats_queue_depth, and it's here to answer one (1) very specific question: what's the Invalidate Queue Depth on this PCI device? ✨


πŸŽ€ NAME

pci_ats_queue_depth β€” query the ATS Invalidate Queue Depth

like, it goes and asks the device "hey how deep is your invalidate queue" and reports back πŸ’–


🌸 SYNOPSIS

int pci_ats_queue_depth (struct pci_dev *dev );

one function, one argument, one int coming back at ya. simple. iconic. no cap πŸ’…


πŸ¦‹ ARGUMENTS

  • dev β€” the PCI device. that's it, that's the whole argument. the PCI device in question, the main character of this call πŸ‘‘

✨ DESCRIPTION

Returns the queue depth on success, or negative on failure. so like, positive number = slay, negative number = it's giving error 😭

now here's the part you actually need to know, bestie, because the numbering is lowkey cursed πŸ™ˆ

The ATS spec uses 0 in the Invalidate Queue Depth field to indicate that the function can accept 32 Invalidate Request. but in this function we use the real values (i.e. 1~32) for the Queue Depth πŸ”₯

and 0 here means the function shares the Queue with other functions (doesn't exclusively own a Queue) β€” so 0 is not "32 requests" in this context, it's "sharing is caring, no exclusive queue for me" 🫢

⚠️ real talk: don't read the raw spec value and this function's return value the same way, because 0 means a whole different thing in each. the spec-vs-here mismatch is exactly the kind of thing that'll have you debugging for an hour at 2am πŸ’€

🧚 SEE ALSO

Kernel file ./drivers/pci/ats.c β€” and the whole friend group:


okay that's the whole page, you ate that πŸ“ this came out of ./drivers/pci in October 2026 β€” go forth and query those queue depths, bestie, and remember: 0 is not a number here, it's a lifestyle πŸ’œβœ¨

πŸ“¦ where this page comes from