Home | History | Annotate | Line # | Download | only in s3c2xx0
s3c24x0_intr.h revision 1.1.4.3
      1  1.1.4.3    skrll /*	$NetBSD: s3c24x0_intr.h,v 1.1.4.3 2004/09/21 13:13:32 skrll Exp $ */
      2      1.1  thorpej 
      3      1.1  thorpej /*
      4  1.1.4.1    skrll  * Copyright (c) 2002, 2003  Genetec corporation.  All rights reserved.
      5  1.1.4.1    skrll  * Written by Hiroyuki Bessho for Genetec corporation.
      6      1.1  thorpej  *
      7      1.1  thorpej  * Redistribution and use in source and binary forms, with or without
      8      1.1  thorpej  * modification, are permitted provided that the following conditions
      9      1.1  thorpej  * are met:
     10      1.1  thorpej  * 1. Redistributions of source code must retain the above copyright
     11      1.1  thorpej  *    notice, this list of conditions and the following disclaimer.
     12      1.1  thorpej  * 2. Redistributions in binary form must reproduce the above copyright
     13      1.1  thorpej  *    notice, this list of conditions and the following disclaimer in the
     14      1.1  thorpej  *    documentation and/or other materials provided with the distribution.
     15  1.1.4.1    skrll  * 3. The name of Genetec corporation may not be used to endorse
     16  1.1.4.1    skrll  *    or promote products derived from this software without specific prior
     17  1.1.4.1    skrll  *    written permission.
     18      1.1  thorpej  *
     19  1.1.4.1    skrll  * THIS SOFTWARE IS PROVIDED BY GENETEC CORP. ``AS IS'' AND
     20  1.1.4.1    skrll  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
     21  1.1.4.1    skrll  * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
     22  1.1.4.1    skrll  * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL GENETEC CORP.
     23  1.1.4.1    skrll  * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
     24  1.1.4.1    skrll  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
     25  1.1.4.1    skrll  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
     26  1.1.4.1    skrll  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
     27  1.1.4.1    skrll  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
     28  1.1.4.1    skrll  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
     29  1.1.4.1    skrll  * POSSIBILITY OF SUCH DAMAGE.
     30      1.1  thorpej  */
     31      1.1  thorpej 
     32      1.1  thorpej #ifndef _S3C24X0_INTR_H_
     33      1.1  thorpej #define	_S3C24X0_INTR_H_
     34      1.1  thorpej 
     35      1.1  thorpej #ifndef _LOCORE
     36      1.1  thorpej 
     37  1.1.4.1    skrll #define	SI_TO_IRQBIT(si)  (1<<(si))
     38  1.1.4.1    skrll 
     39  1.1.4.1    skrll #define	get_pending_softint()	(softint_pending & soft_intr_mask)
     40  1.1.4.1    skrll #define	update_softintr_mask()	\
     41  1.1.4.1    skrll 	(soft_intr_mask = s3c24x0_soft_imask[current_spl_level])
     42  1.1.4.1    skrll #define	s3c2xx0_update_hw_mask() \
     43  1.1.4.1    skrll 	(*s3c2xx0_intr_mask_reg = ~(intr_mask & global_intr_mask))
     44  1.1.4.1    skrll 
     45  1.1.4.1    skrll /* no room for softinterrupts in intr_mask. */
     46  1.1.4.1    skrll extern int __volatile soft_intr_mask;
     47  1.1.4.1    skrll extern int s3c24x0_soft_imask[];
     48  1.1.4.1    skrll 
     49      1.1  thorpej 
     50      1.1  thorpej #include <arm/s3c2xx0/s3c2xx0_intr.h>
     51      1.1  thorpej 
     52      1.1  thorpej #endif /* ! _LOCORE */
     53      1.1  thorpej 
     54      1.1  thorpej #endif /* _S3C24X0_INTR_H_ */
     55