msi_domain_..._descs_range(9)
π msi_domain_free_msi_descs_range β Kernel API Manual, bestie edition π
Okay so this is a function from the Kernel API Manual and honestly? It's giving cleanup era. β¨
πΈ NAME πΈ
msi_domain_free_msi_descs_range β frees a whole range of MSI descriptors for a device inside an irqdomain. Literally the "ok we're done here, release the descs" moment π
β¨ SYNOPSIS β¨
void msi_domain_free_msi_descs_range (struct device *dev , unsigned int domid , unsigned int first , unsigned int last );
Note the return type: void. She does her job and doesn't report back, no cap. π«Ά
π¦ ARGUMENTS π¦
devβ the Device whose descriptors we're freeing. It's her descriptors, she's just handing them back. πdomidβ the Id of the domain we're operating on. Gotta know which irqdomain we're in, iykyk. πfirstβ index to start freeing from, and it's inclusive (so yes,firstitself gets freed, bestie). πΈlastβ the last index to be freed, also inclusive. So the range really isfirstthroughlast, both ends counted. π
Quick vibe check on those two: inclusive on both sides. Don't be out here assuming off-by-one shenanigans β free the whole span fromfirsttolast, ends included. π₯
π SEE ALSO π
Kernel file ./kernel/irq/msi.c, plus a whole friend group of related functions and structs:
struct msi_device_data(9)struct msi_ctrl(9)msi_alloc_desc(9)msi_domain_insert_msi_desc(9)msi_domain_add_simple_msi_descs(9)msi_setup_device_data(9)__msi_lock_descs(9)__msi_unlock_descs(9)msi_domain_first_desc(9)msi_next_desc(9)msi_domain_get_virq(9)msi_device_populate_sysfs(9)msi_device_destroy_sysfs(9)msi_domain_set_affinity(9)msi_create_irq_domain(9)msi_create_parent_irq_domain(9)msi_parent_init_dev_msi_info(9)msi_create_device_irq_domain(9)msi_remove_device_irq_domain(9)msi_match_device_irq_domain(9)msi_domain_alloc_irqs_range_locked(9)msi_domain_alloc_irqs_range(9)msi_domain_alloc_irqs_all_locked(9)msi_domain_alloc_irq_at(9)msi_device_domain_alloc_wired(9)msi_domain_free_irqs_range_locked(9)msi_domain_free_irqs_range(9)msi_domain_free_irqs_all_locked(9)msi_domain_free_irqs_all(9)msi_device_domain_free_wired(9)msi_get_domain_info(9)msi_device_has_isolated_msi(9)
That's the whole squad, no notes. π
And that's the page!! π§ Sending you off with the source deets: this one lives under ./kernel/irq and it's dated October 2026. Slay, go free some descriptors responsibly. π
β¨π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms