intr.h (204425) | intr.h (205234) |
---|---|
1/*- 2 * Copyright (c) 2007-2010 Marcel Moolenaar 3 * Copyright (c) 1998 Doug Rabson 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 10 unchanged lines hidden (view full) --- 19 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 20 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 21 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 22 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 23 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 24 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 25 * SUCH DAMAGE. 26 * | 1/*- 2 * Copyright (c) 2007-2010 Marcel Moolenaar 3 * Copyright (c) 1998 Doug Rabson 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 10 unchanged lines hidden (view full) --- 19 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 20 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 21 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 22 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 23 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 24 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 25 * SUCH DAMAGE. 26 * |
27 * $FreeBSD: head/sys/ia64/include/intr.h 204425 2010-02-27 18:55:43Z marcel $ | 27 * $FreeBSD: head/sys/ia64/include/intr.h 205234 2010-03-17 00:37:15Z marcel $ |
28 */ 29 30#ifndef _MACHINE_INTR_H_ 31#define _MACHINE_INTR_H_ 32 | 28 */ 29 30#ifndef _MACHINE_INTR_H_ 31#define _MACHINE_INTR_H_ 32 |
33#define IA64_NXIVS 256 /* External Interrupt Vectors */ 34#define IA64_MIN_XIV 16 35 36#define IA64_MAX_HWPRIO 14 37 |
|
33struct sapic; | 38struct sapic; |
39struct thread; 40struct trapframe; |
|
34 35/* 36 * Layout of the Processor Interrupt Block. 37 */ 38struct ia64_pib 39{ 40 uint64_t ib_ipi[65536][2]; /* 64K-way IPIs (1MB area). */ 41 uint8_t _rsvd1[0xe0000]; 42 uint8_t ib_inta; /* Generate INTA cycle. */ 43 uint8_t _rsvd2[7]; 44 uint8_t ib_xtp; /* External Task Priority. */ 45 uint8_t _rsvd3[7]; 46 uint8_t _rsvd4[0x1fff0]; 47}; 48 | 41 42/* 43 * Layout of the Processor Interrupt Block. 44 */ 45struct ia64_pib 46{ 47 uint64_t ib_ipi[65536][2]; /* 64K-way IPIs (1MB area). */ 48 uint8_t _rsvd1[0xe0000]; 49 uint8_t ib_inta; /* Generate INTA cycle. */ 50 uint8_t _rsvd2[7]; 51 uint8_t ib_xtp; /* External Task Priority. */ 52 uint8_t _rsvd3[7]; 53 uint8_t _rsvd4[0x1fff0]; 54}; 55 |
56enum ia64_xiv_use { 57 IA64_XIV_FREE, 58 IA64_XIV_ARCH, /* Architecturally defined. */ 59 IA64_XIV_PLAT, /* Platform defined. */ 60 IA64_XIV_IPI, /* Used for IPIs. */ 61 IA64_XIV_IRQ /* Used for external interrupts. */ 62}; 63 64typedef u_int (ia64_ihtype)(struct thread *, u_int, struct trapframe *); 65 |
|
49extern struct ia64_pib *ia64_pib; 50 | 66extern struct ia64_pib *ia64_pib; 67 |
68void ia64_handle_intr(struct trapframe *); |
|
51int ia64_setup_intr(const char *, int, driver_filter_t, driver_intr_t, 52 void *, enum intr_type, void **); 53int ia64_teardown_intr(void *); 54 | 69int ia64_setup_intr(const char *, int, driver_filter_t, driver_intr_t, 70 void *, enum intr_type, void **); 71int ia64_teardown_intr(void *); 72 |
73void ia64_xiv_init(void); 74u_int ia64_xiv_alloc(u_int, enum ia64_xiv_use, ia64_ihtype); 75int ia64_xiv_free(u_int, enum ia64_xiv_use); 76int ia64_xiv_reserve(u_int, enum ia64_xiv_use, ia64_ihtype); 77 |
|
55int sapic_config_intr(u_int, enum intr_trigger, enum intr_polarity); 56struct sapic *sapic_create(u_int, u_int, uint64_t); 57int sapic_enable(struct sapic *, u_int, u_int); 58void sapic_eoi(struct sapic *, u_int); 59struct sapic *sapic_lookup(u_int, u_int *); 60void sapic_mask(struct sapic *, u_int); 61void sapic_unmask(struct sapic *, u_int); 62 63#ifdef DDB 64void sapic_print(struct sapic *, u_int); 65#endif 66 67#endif /* !_MACHINE_INTR_H_ */ | 78int sapic_config_intr(u_int, enum intr_trigger, enum intr_polarity); 79struct sapic *sapic_create(u_int, u_int, uint64_t); 80int sapic_enable(struct sapic *, u_int, u_int); 81void sapic_eoi(struct sapic *, u_int); 82struct sapic *sapic_lookup(u_int, u_int *); 83void sapic_mask(struct sapic *, u_int); 84void sapic_unmask(struct sapic *, u_int); 85 86#ifdef DDB 87void sapic_print(struct sapic *, u_int); 88#endif 89 90#endif /* !_MACHINE_INTR_H_ */ |