irq_disable(9)
π irq_disable(9) β Kernel API Manual π
okay bestie, welcome to the irq_disable page, straight out of the Kernel API Manual. yes it's a kernel thing. no you're not allowed to be scared of it. let's go β¨
πΈ NAME πΈ
irq_disable β Mark interrupt disabled
like, that's the whole vibe. marking an interrupt as disabled. iconic behavior, honestly.
π¦ SYNOPSIS π¦
void irq_disable (struct irq_desc *desc );
void return, one argument, no drama. she's lowkey minimal and we love that for her.
π ARGUMENTS π
descβ the irq descriptor that should be disabled π«Ά. that's the thing you're pointing at, that's the thing getting turned off. simple as.
π DESCRIPTION π
okay so here's the tea, and it's genuinely kind of clever. β
If the chip does not implement the irq_disable callback, we use a lazy disable approach. That means we mark the interrupt disabled, but we leave the hardware unmasked. and no, that's not us being sloppy β that's an optimization, because we avoid the hardware access for the common case where no interrupt happens after we marked it disabled. π
efficient queen.
But if an interrupt does happen? then the interrupt flow handler masks the line at the hardware level and marks it pending. so it all works out, the lazy girlies always pull through. β¨
If the interrupt chip does not implement the irq_disable callback, a driver can disable the lazy approach for a particular irq line by calling 'irq_set_status_flags(irq, IRQ_DISABLE_UNLAZY)'. π¦
this one matters: it can be used for devices which cannot disable the interrupt at the device level under certain circumstances and have to use disable_irq[_nosync] instead. so if your device is one of those devices, this is your girl. no cap.
π₯ SEE ALSO π₯
Kernel file ./kernel/irq/chip.c β and like, literally the whole friend group: irq_set_chip(9), irq_set_irq_type(9), irq_set_handler_data(9), irq_set_msi_desc_off(9), irq_set_msi_desc(9), irq_set_chip_data(9), handle_nested_irq(9), handle_simple_irq(9), handle_untracked_irq(9), handle_level_irq(9), handle_fasteoi_irq(9), handle_fasteoi_nmi(9), handle_edge_irq(9), handle_percpu_irq(9), handle_percpu_devid_irq(9), irq_cpu_online(9), irq_cpu_offline(9), handle_fasteoi_ack_irq(9), handle_fasteoi_mask_irq(9), irq_chip_set_parent_state(9), irq_chip_get_parent_state(9), irq_chip_shutdown_parent(9), irq_chip_startup_parent(9), irq_chip_enable_parent(9), irq_chip_disable_parent(9), irq_chip_ack_parent(9), irq_chip_mask_parent(9), irq_chip_mask_ack_parent(9), irq_chip_unmask_parent(9), irq_chip_eoi_parent(9), irq_chip_set_affinity_parent(9), irq_chip_set_type_parent(9), irq_chip_retrigger_hierarchy(9), irq_chip_set_vcpu_affinity_parent(9), irq_chip_set_wake_parent(9), irq_chip_request_resources_parent(9), irq_chip_release_resources_parent(9), irq_chip_compose_msi_msg(9), irq_chip_pm_get(9), irq_chip_pm_put(9)
like, that's the entire group chat right there. read them all, iykyk. π
and that's the page!! mwah π this one came from the ./kernel/irq corner of the tree, dated October 2026 β go drink some water, bestie, and go disable an interrupt (lazily, if the chip lets you) πβπ
π¦ 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