irq_domain_create_simple(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

🌸 NAME 🌸

irq_domain_create_simple β€” Register an irq_domain and optionally map a range of irqs. This is irq_domain_create_simple(9) from the Kernel API Manual, and it's lowkey the setup bestie for interrupt domains πŸ’–.

✨ SYNOPSIS ✨

okay so the signature is literally:

struct irq_domain * irq_domain_create_simple (struct fwnode_handle
       *fwnode , unsigned int size , unsigned int first_irq , const struct
       irq_domain_ops *ops , void *host_data );

πŸŽ€ ARGUMENTS πŸŽ€

  • fwnode β€” firmware node for the interrupt controller, like the controller's little ID card πŸ’³
  • size β€” total number of irqs in mapping, periodt.
  • first_irq β€” first number of irq block assigned to the domain. Pass zero to assign irqs on-the-fly πŸ¦‹. If first_irq is non-zero, then pre-map all of the irqs in the domain to virqs starting at first_irq.
  • ops β€” domain callbacks.
  • host_data β€” Controller private data pointer, aka the controller's own little stash 🫢.

πŸ’… DESCRIPTION πŸ’…

Okay so irq_domain_create_simple() allocates an irq_domain, and optionally if first_irq is positive then it also allocates irq_descs and maps all of the hwirqs to virqs starting at first_irq. That's the whole glow-up ✨.

This is intended to implement the expected behaviour for most interrupt controllers. If device tree is used, then first_irq will be 0 and irqs get mapped dynamically on the fly. However, if the controller requires static virq assignments (non-DT boot) then it will set that up correctly. So it handles both the chill dynamic vibe and the structured static vibe, iykyk πŸ’….

🌈 SEE ALSO 🌈

The whole friend group lives here, bestie β€” plus the kernel file ./kernel/irq/irqdomain.c 🧚:


Okay bye bestie 🫢 β€” source/version: ./kernel/irq; date: October 2026; page: irq_domain_create_simple(9). That's the whole manual, periodt πŸ’…βœ¨

πŸ“¦ where this page comes from