aboutsummaryrefslogtreecommitdiff
path: root/include/arch/irq.h
blob: 72b998e861fe42cd9c1d59f54b7156a4cb58b1be (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
/* SPDX-License-Identifier: copyleft-next-0.3.1 */
/* Copyright 2021 - 2022, Kim Kuparinen < kimi.h.kuparinen@gmail.com > */

#ifndef KMI_IRQ_H
#define KMI_IRQ_H

/**
 * @file irq.h
 * Arch-specific interrupt handling, generally implemented in
 * arch/whatever/kernel/irq.c
 *
 * \todo These should probably also be stat_t...
 */

#if defined(riscv64)
#include "../../arch/riscv64/include/irq.h"
#elif defined(riscv32)
#include "../../arch/riscv32/include/irq.h"
#endif

/**
 * Initialize IRQ subsystem.
 *
 * @param fdt Global FDT pointer.
 */
void init_irq(void *fdt);

/** Enable IRQs. */
void enable_irq();

/** Disable IRQs. */
void disable_irq();

#endif /* KMI_IRQ_H */