Re: [PATCH 3/3] rust: pci: move IRQ infrastructure to separate file

From: Bjorn Helgaas

Date: Wed Oct 15 2025 - 19:02:11 EST


On Wed, Oct 15, 2025 at 08:14:31PM +0200, Danilo Krummrich wrote:
> Move the PCI interrupt infrastructure to a separate sub-module in order
> to keep things organized.

> +++ b/rust/kernel/pci/irq.rs

> +pub enum IrqType {
> + /// INTx interrupts.
> + Intx,
> + /// Message Signaled Interrupts (MSI).
> + Msi,
> + /// Extended Message Signaled Interrupts (MSI-X).
> + MsiX,
> +}

> +impl IrqTypes {
> + /// Create a set containing all IRQ types (MSI-X, MSI, and Legacy).
> ...
> + /// // Create a set with only MSI and MSI-X (no legacy interrupts).
> ...
> + /// The allocation will use MSI-X, MSI, or legacy interrupts based on the `irq_types`
> + /// parameter and hardware capabilities. When multiple types are specified, the kernel
> + /// will try them in order of preference: MSI-X first, then MSI, then legacy interrupts.
> ...
> + /// // Allocate MSI or MSI-X only (no legacy interrupts).

Again, just a move, but could s/Legacy/INTx/ to make them all match.