intr.h revision 166901
1193326Sed/* $NetBSD: intr.h,v 1.7 2003/06/16 20:01:00 thorpej Exp $ */ 2193326Sed 3193326Sed/*- 4193326Sed * Copyright (c) 1997 Mark Brinicombe. 5193326Sed * All rights reserved. 6193326Sed * 7193326Sed * Redistribution and use in source and binary forms, with or without 8193326Sed * modification, are permitted provided that the following conditions 9193326Sed * are met: 10193326Sed * 1. Redistributions of source code must retain the above copyright 11193326Sed * notice, this list of conditions and the following disclaimer. 12193326Sed * 2. Redistributions in binary form must reproduce the above copyright 13193326Sed * notice, this list of conditions and the following disclaimer in the 14193326Sed * documentation and/or other materials provided with the distribution. 15193326Sed * 3. All advertising materials mentioning features or use of this software 16193326Sed * must display the following acknowledgement: 17193326Sed * This product includes software developed by Mark Brinicombe 18226633Sdim * for the NetBSD Project. 19193326Sed * 4. The name of the company nor the name of the author may be used to 20234353Sdim * endorse or promote products derived from this software without specific 21193326Sed * prior written permission. 22193326Sed * 23193326Sed * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED 24193326Sed * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 25193326Sed * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 26193326Sed * IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 27193326Sed * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 28193326Sed * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 29193326Sed * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 30193326Sed * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 31193326Sed * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 32193326Sed * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 33218893Sdim * SUCH DAMAGE. 34193326Sed * 35193326Sed * $FreeBSD: head/sys/arm/include/intr.h 166901 2007-02-23 12:19:07Z piso $ 36243830Sdim * 37243830Sdim */ 38193326Sed 39193326Sed#ifndef _MACHINE_INTR_H_ 40193326Sed#define _MACHINE_INTR_H_ 41193326Sed 42193326Sed#ifdef CPU_ARM9 43193326Sed#define NIRQ 64 44193326Sed#else 45193326Sed#define NIRQ 32 46193326Sed#endif 47198092Srdivacky 48193326Sed#include <machine/psl.h> 49193326Sed 50193326Sedint arm_get_next_irq(void); 51198092Srdivackyvoid arm_mask_irq(uintptr_t); 52198092Srdivackyvoid arm_unmask_irq(uintptr_t); 53193326Sedvoid arm_setup_irqhandler(const char *, int (*)(void*), void (*)(void*), 54193326Sed void *, int, int, void **); 55193326Sedint arm_remove_irqhandler(void *); 56193326Sed#endif /* _MACHINE_INTR_H */ 57193326Sed