1198160Srrs/*- 2198160Srrs * Copyright (c) 2003-2009 RMI Corporation 3198160Srrs * All rights reserved. 4198160Srrs * 5198160Srrs * Redistribution and use in source and binary forms, with or without 6198160Srrs * modification, are permitted provided that the following conditions 7198160Srrs * are met: 8198160Srrs * 1. Redistributions of source code must retain the above copyright 9198160Srrs * notice, this list of conditions and the following disclaimer. 10198160Srrs * 2. Redistributions in binary form must reproduce the above copyright 11198160Srrs * notice, this list of conditions and the following disclaimer in the 12198160Srrs * documentation and/or other materials provided with the distribution. 13198160Srrs * 3. Neither the name of RMI Corporation, nor the names of its contributors, 14198160Srrs * may be used to endorse or promote products derived from this software 15198160Srrs * without specific prior written permission. 16198160Srrs * 17198160Srrs * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 18198160Srrs * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19198160Srrs * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 20198160Srrs * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 21198160Srrs * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22198160Srrs * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23198160Srrs * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24198160Srrs * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25198160Srrs * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26198160Srrs * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27198160Srrs * SUCH DAMAGE. 28211994Sjchandra * 29211994Sjchandra * RMI_BSD 30211994Sjchandra * $FreeBSD: releng/10.3/sys/mips/rmi/interrupt.h 211994 2010-08-30 13:05:21Z jchandra $ 31211994Sjchandra */ 32198160Srrs#ifndef _RMI_INTERRUPT_H_ 33198160Srrs#define _RMI_INTERRUPT_H_ 34198160Srrs 35198160Srrs/* Defines for the IRQ numbers */ 36198160Srrs 37208165Srrs#define IRQ_IPI 41 /* 8-39 are mapped by PIC intr 0-31 */ 38208165Srrs#define IRQ_MSGRING 6 39208165Srrs#define IRQ_TIMER 7 40198160Srrs 41204130Srrs/* 42204130Srrs * XLR needs custom pre and post handlers for PCI/PCI-e interrupts 43204130Srrs * XXX: maybe follow i386 intsrc model 44204130Srrs */ 45211893Sjchandravoid xlr_establish_intr(const char *name, driver_filter_t filt, 46211893Sjchandra driver_intr_t handler, void *arg, int irq, int flags, 47211893Sjchandra void **cookiep, void (*busack)(int)); 48211893Sjchandravoid xlr_enable_irq(int irq); 49204130Srrs 50198625Srrs#endif /* _RMI_INTERRUPT_H_ */ 51