mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-25 19:42:19 +00:00
This patch adds support for non-threaded IRQs and handlers through irq::Registration and the irq::Handler trait. Registering an irq is dependent upon having a IrqRequest that was previously allocated by a given device. This will be introduced in subsequent patches. Tested-by: Joel Fernandes <joelagnelf@nvidia.com> Tested-by: Dirk Behme <dirk.behme@de.bosch.com> Reviewed-by: Alice Ryhl <aliceryhl@google.com> Signed-off-by: Daniel Almeida <daniel.almeida@collabora.com> Link: https://lore.kernel.org/r/20250811-topics-tyr-request_irq2-v9-3-0485dcd9bcbf@collabora.com [ Remove expect(dead_code) from Flags::into_inner(), add expect(dead_code) to IrqRequest::new(), fix intra-doc links. - Danilo ] Signed-off-by: Danilo Krummrich <dakr@kernel.org>
22 lines
629 B
Rust
22 lines
629 B
Rust
// SPDX-License-Identifier: GPL-2.0
|
|
|
|
//! IRQ abstractions.
|
|
//!
|
|
//! An IRQ is an interrupt request from a device. It is used to get the CPU's
|
|
//! attention so it can service a hardware event in a timely manner.
|
|
//!
|
|
//! The current abstractions handle IRQ requests and handlers, i.e.: it allows
|
|
//! drivers to register a handler for a given IRQ line.
|
|
//!
|
|
//! C header: [`include/linux/device.h`](srctree/include/linux/interrupt.h)
|
|
|
|
/// Flags to be used when registering IRQ handlers.
|
|
mod flags;
|
|
|
|
/// IRQ allocation and handling.
|
|
mod request;
|
|
|
|
pub use flags::Flags;
|
|
|
|
pub use request::{Handler, IrqRequest, IrqReturn, Registration};
|