intr.h (27067774dce3388702a4cf744d7096c6fb71b688) | intr.h (2d53a67c2cb055ee65e7de878cca28172de2d4f1) |
---|---|
1/*- 2 * Copyright (c) 2015-2016 Ruslan Bukin <br@bsdpad.com> 3 * All rights reserved. 4 * 5 * Portions of this software were developed by SRI International and the 6 * University of Cambridge Computer Laboratory under DARPA/AFRL contract 7 * FA8750-10-C-0237 ("CTSRD"), as part of the DARPA CRASH research programme. 8 * --- 23 unchanged lines hidden (view full) --- 32 * SUCH DAMAGE. 33 * 34 * $FreeBSD$ 35 */ 36 37#ifndef _MACHINE_INTR_MACHDEP_H_ 38#define _MACHINE_INTR_MACHDEP_H_ 39 | 1/*- 2 * Copyright (c) 2015-2016 Ruslan Bukin <br@bsdpad.com> 3 * All rights reserved. 4 * 5 * Portions of this software were developed by SRI International and the 6 * University of Cambridge Computer Laboratory under DARPA/AFRL contract 7 * FA8750-10-C-0237 ("CTSRD"), as part of the DARPA CRASH research programme. 8 * --- 23 unchanged lines hidden (view full) --- 32 * SUCH DAMAGE. 33 * 34 * $FreeBSD$ 35 */ 36 37#ifndef _MACHINE_INTR_MACHDEP_H_ 38#define _MACHINE_INTR_MACHDEP_H_ 39 |
40#define RISCV_NIRQ 1024 41 42#ifndef NIRQ 43#define NIRQ RISCV_NIRQ 44#endif 45 46#ifdef INTRNG 47#include <sys/intr.h> 48#endif 49 |
|
40struct trapframe; 41 | 50struct trapframe; 51 |
42void riscv_init_interrupts(void); | |
43int riscv_teardown_intr(void *); | 52int riscv_teardown_intr(void *); |
44int riscv_config_intr(u_int, enum intr_trigger, enum intr_polarity); | |
45int riscv_setup_intr(const char *, driver_filter_t *, driver_intr_t *, 46 void *, int, int, void **); 47void riscv_cpu_intr(struct trapframe *); 48 49typedef unsigned long * riscv_intrcnt_t; 50 51riscv_intrcnt_t riscv_intrcnt_create(const char *); 52void riscv_intrcnt_setname(riscv_intrcnt_t, const char *); --- 11 unchanged lines hidden (view full) --- 64 IRQ_TIMER_USER, 65 IRQ_TIMER_SUPERVISOR, 66 IRQ_TIMER_HYPERVISOR, 67 IRQ_TIMER_MACHINE, 68 IRQ_EXTERNAL_USER, 69 IRQ_EXTERNAL_SUPERVISOR, 70 IRQ_EXTERNAL_HYPERVISOR, 71 IRQ_EXTERNAL_MACHINE, | 53int riscv_setup_intr(const char *, driver_filter_t *, driver_intr_t *, 54 void *, int, int, void **); 55void riscv_cpu_intr(struct trapframe *); 56 57typedef unsigned long * riscv_intrcnt_t; 58 59riscv_intrcnt_t riscv_intrcnt_create(const char *); 60void riscv_intrcnt_setname(riscv_intrcnt_t, const char *); --- 11 unchanged lines hidden (view full) --- 72 IRQ_TIMER_USER, 73 IRQ_TIMER_SUPERVISOR, 74 IRQ_TIMER_HYPERVISOR, 75 IRQ_TIMER_MACHINE, 76 IRQ_EXTERNAL_USER, 77 IRQ_EXTERNAL_SUPERVISOR, 78 IRQ_EXTERNAL_HYPERVISOR, 79 IRQ_EXTERNAL_MACHINE, |
72#if 0 73 /* lowRISC TODO */ 74 IRQ_COP, /* lowRISC only */ 75 IRQ_UART, /* lowRISC only */ 76#endif 77 NIRQS | 80 INTC_NIRQS |
78}; 79 80#endif /* !_MACHINE_INTR_MACHDEP_H_ */ | 81}; 82 83#endif /* !_MACHINE_INTR_MACHDEP_H_ */ |