Danilo Krummrich
d8407396f1
rust: pci: use "kernel vertical" style for imports
...
Convert all imports in the PCI Rust module to use "kernel vertical"
style.
With this subsequent patches neither introduce unrelated changes nor
leave an inconsistent import pattern.
While at it, drop unnecessary imports covered by prelude::*.
Link: https://docs.kernel.org/rust/coding-guidelines.html#imports
Reviewed-by: Zhi Wang <zhiw@nvidia.com >
Link: https://patch.msgid.link/20251105120352.77603-1-dakr@kernel.org
Signed-off-by: Danilo Krummrich <dakr@kernel.org >
2025-11-11 19:45:23 +11:00
Danilo Krummrich
1f7b01661f
rust: pci: get rid of redundant Result in IRQ methods
...
Currently request_irq() returns
Result<impl PinInit<irq::Registration<T>, Error> + 'a>
which may carry an error in the Result or the initializer; the same is
true for request_threaded_irq().
Use pin_init::pin_init_scope() to get rid of this redundancy.
Reviewed-by: Alice Ryhl <aliceryhl@google.com >
Link: https://patch.msgid.link/20251103203053.2348783-1-dakr@kernel.org
Signed-off-by: Danilo Krummrich <dakr@kernel.org >
2025-11-06 10:19:36 +01:00
Peter Colberg
c7f6d5380f
rust: pci: refer to legacy as INTx interrupts
...
Consistently use INTx, as in the description of IrqType::Intx, to refer
to the four legacy PCI interrupts, INTA#, INTB#, INTC#, and INTD#.
Link: https://lore.kernel.org/rust-for-linux/20251015230209.GA960343@bhelgaas/
Link: https://github.com/Rust-for-Linux/linux/issues/1196
Suggested-by: Bjorn Helgaas <helgaas@kernel.org >
Signed-off-by: Peter Colberg <pcolberg@redhat.com >
Signed-off-by: Danilo Krummrich <dakr@kernel.org >
2025-10-23 20:12:32 +02:00
Danilo Krummrich
e6901808a3
rust: pci: move IRQ infrastructure to separate file
...
Move the PCI interrupt infrastructure to a separate sub-module in order
to keep things organized.
Signed-off-by: Danilo Krummrich <dakr@kernel.org >
2025-10-20 12:03:23 +02:00