⚠️ VeridianOS Kernel Documentation - This is low-level kernel code. All functions are unsafe unless explicitly marked otherwise. no_std

register_handler

Function register_handler 

Source
pub fn register_handler(irq: IrqNumber, handler: IrqHandler) -> KernelResult<()>
Expand description

Register an IRQ handler for the given interrupt number.

The handler will be invoked when the interrupt fires and dispatch is called. Only one handler may be registered per IRQ number.

§Errors

  • KernelError::NotInitialized if the IRQ manager has not been initialized.
  • KernelError::AlreadyExists if a handler is already registered for this IRQ.
  • KernelError::InvalidArgument if the IRQ number exceeds the maximum.