STRUCT PCI_MSI_DESC(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ struct pci_msi_desc(9) β€” the PCI/MSI tea β˜•πŸ’…

okay so bestie, welcome to the kernel API manual (that's the manual name, iykyk 🫢) and today's main character is struct pci_msi_desc β€” literally the PCI/MSI specific MSI descriptor data. it's giving "small struct, big responsibilities" ✨


🌸 NAME 🌸

struct pci_msi_desc β€” the PCI/MSI-specific MSI descriptor data, no cap πŸ’–


πŸŽ€ SYNOPSIS πŸŽ€

struct pci_msi_desc {
    union {
      u32 msi_mask;
      u32 msix_ctrl;
    };
    struct {
      u8 is_msix         : 1;
      u8 multiple        : 3;
      u8 multi_cap       : 3;
      u8 can_mask        : 1;
      u8 is_64           : 1;
      u8 is_virtual      : 1;
      unsigned default_irq;
    } msi_attrib;
    union {
      u8 mask_pos;
      void __iomem *mask_base;
    };
 };

like, look at those bitfields. : 1 everywhere. it's giving "every bit is precious" 🌈 and honestly? obsessed. 🧚


πŸ‘‘ Members πŸ‘‘

not a struct member? it's a member bestie, there's a difference, and we're gonna go through every single one fr fr πŸ“

  • {unnamed_union} β€” anonymous πŸ’€ yes that's literally what it says. it has no name. it simply is.
  • msi_mask β€” [PCI MSI] MSI cached mask bits πŸ”₯
  • msix_ctrl β€” [PCI MSI-X] MSI-X cached per vector control bits, periodt ✨
  • msi_attrib β€” [PCI MSI/X] compound struct of MSI/X attributes πŸŽ€
  • {unnamed_union} β€” anonymous again 😭 second mystery union, we love a recurring motif
  • mask_pos β€” [PCI MSI] mask register position πŸ’…
  • mask_base β€” [PCI MSI-X] mask register base address πŸ‘‘
ngl the two anonymous unions are iconic in a "i refuse to be named" kind of way. respect. 🫢

πŸ¦‹ SEE ALSO πŸ¦‹

the whole friend group shows up, and we're listing them all because nobody gets left on read πŸ’œ

Kernel file ./include/linux/msi.h, plus:

like that's a whole group chat and you're invited πŸŽ‰βœ¨


okay that's the whole page bestie, no notes πŸŽ€ this one came out of ./include/linux, Kernel API Manual, dated October 2026 β€” mwah, stan, and go read msi.h πŸ’–πŸ’…πŸŒŸ

πŸ“¦ where this page comes from