blob: 12f4060a31b034e9cd7190b075da6f58d6d4abaa [file] [log] [blame]
Bryan Wu1394f032007-05-06 14:50:22 -07001/*
Robin Getz96f10502009-09-24 14:11:24 +00002 * Copyright 2004-2009 Analog Devices Inc.
3 * 2003 HuTao
4 * 2002 Arcturus Networks Inc. (www.arcturusnetworks.com
5 * Ted Ma <mated@sympatico.ca>
Bryan Wu1394f032007-05-06 14:50:22 -07006 *
Robin Getz96f10502009-09-24 14:11:24 +00007 * Licensed under the GPL-2
Bryan Wu1394f032007-05-06 14:50:22 -07008 */
9
10#ifndef _BFIN_IRQ_H_
11#define _BFIN_IRQ_H_
12
Mike Frysinger8f860012009-06-08 12:49:48 -040013#include <linux/irqflags.h>
14
Michael Hennerichf3dec782010-01-19 14:45:38 +000015/* IRQs that may be used by external irq_chip controllers */
16#define NR_SPARE_IRQS 32
17
Mike Frysingerd586e832009-09-21 01:42:52 +000018#include <mach/anomaly.h>
19
Mike Frysinger8f860012009-06-08 12:49:48 -040020/* SYS_IRQS and NR_IRQS are defined in <mach-bf5xx/irq.h> */
Bryan Wu639f6572008-08-27 10:51:02 +080021#include <mach/irq.h>
Bryan Wu1394f032007-05-06 14:50:22 -070022
Yi Li6a01f232009-01-07 23:14:39 +080023#if ANOMALY_05000244 && defined(CONFIG_BFIN_ICACHE)
24# define NOP_PAD_ANOMALY_05000244 "nop; nop;"
25#else
26# define NOP_PAD_ANOMALY_05000244
27#endif
28
29#define idle_with_irq_disabled() \
30 __asm__ __volatile__( \
31 NOP_PAD_ANOMALY_05000244 \
32 ".align 8;" \
33 "sti %0;" \
34 "idle;" \
35 : \
36 : "d" (bfin_irq_flags) \
37 )
38
Mike Frysingerd5ce5282009-06-13 11:32:34 -040039#include <asm-generic/irq.h>
Yi Li6a01f232009-01-07 23:14:39 +080040
Graf Yang60ffdb32010-01-20 10:56:24 +000041#ifdef CONFIG_NMI_WATCHDOG
42# define ARCH_HAS_NMI_WATCHDOG
43#endif
44
Bryan Wu1394f032007-05-06 14:50:22 -070045#endif /* _BFIN_IRQ_H_ */