irq_set_vcpu_affinity(9)
π irq_set_vcpu_affinity(9) π
okay so bestie, welcome to the Kernel API Manual, section 9 β this one's all about irq_set_vcpu_affinity, and no cap it's a whole vibe.
β¨ NAME β¨
irq_set_vcpu_affinity β set vcpu affinity for the interrupt π
πΈ SYNOPSIS πΈ
int irq_set_vcpu_affinity (unsigned int irq , void *vcpu_info );
like, that's the whole signature, look at her go π
π¦ ARGUMENTS π¦
irqβ the interrupt number you're setting affinity for. this is the main character of the operation ngl π₯vcpu_infoβ vCPU specific data, or a pointer to a percpu array of vCPU specific data forpercpu_devidinterrupts. two moods, one pointer, iykyk β¨
π DESCRIPTION π
so what she does: this function uses that vCPU specific data to set the vCPU affinity for an irq. the vCPU specific data is passed in from outside, like from KVM β it doesn't magically appear, someone hands it over π«Ά
one example code path is literally this, and it's giving relay race:
KVM -> IOMMU -> irq_set_vcpu_affinity
KVM hands it off, IOMMU carries the baton, and irq_set_vcpu_affinity crosses the finish line. slay π
π SEE ALSO π
Kernel file ./kernel/irq/manage.c β and like, the whole friend group:
synchronize_hardirq(9)synchronize_irq(9)irq_can_set_affinity(9)irq_can_set_affinity_usr(9)irq_set_thread_affinity(9)irq_affinity_schedule_notify_work(9)irq_update_affinity_desc(9)irq_set_affinity(9)irq_force_affinity(9)irq_set_affinity_notifier(9)disable_irq_nosync(9)disable_irq(9)disable_hardirq(9)disable_nmi_nosync(9)enable_irq(9)enable_nmi(9)irq_set_irq_wake(9)irq_wake_thread(9)free_irq(9)request_threaded_irq(9)request_any_context_irq(9)request_nmi(9)irq_percpu_is_enabled(9)free_percpu_irq(9)request_percpu_irq_affinity(9)request_percpu_nmi(9)prepare_percpu_nmi(9)teardown_percpu_nmi(9)irq_get_irqchip_state(9)irq_set_irqchip_state(9)irq_has_action(9)irq_check_status_bit(9)
the way that's literally the entire irq squad ππ
okay that's the page!! this one came straight out of ./kernel/irq, dated October 2026, so shoutout to the source for keeping it iconic β go read it, it ate πππβ¨
π¦ 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