2010-07-26 10:12:15 +00:00
|
|
|
/*
|
|
|
|
* Copyright (C) ST-Ericsson SA 2010
|
|
|
|
*
|
|
|
|
* Author: Rabin Vincent <rabin.vincent@stericsson.com>
|
|
|
|
* License terms: GNU General Public License (GPL) version 2
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __MACH_IRQS_BOARD_MOP500_H
|
|
|
|
#define __MACH_IRQS_BOARD_MOP500_H
|
|
|
|
|
2010-12-02 12:46:00 +00:00
|
|
|
/* Number of AB8500 irqs is taken from header file */
|
2011-12-02 13:16:33 +00:00
|
|
|
#include <linux/mfd/abx500/ab8500.h>
|
2010-07-26 10:12:15 +00:00
|
|
|
|
|
|
|
#define MOP500_AB8500_IRQ_BASE IRQ_BOARD_START
|
|
|
|
#define MOP500_AB8500_IRQ_END (MOP500_AB8500_IRQ_BASE \
|
2012-02-20 20:42:24 +00:00
|
|
|
+ AB8500_MAX_NR_IRQS)
|
2010-08-09 13:48:17 +00:00
|
|
|
|
2010-12-03 15:05:38 +00:00
|
|
|
/* TC35892 */
|
2010-08-09 13:48:17 +00:00
|
|
|
#define TC35892_NR_INTERNAL_IRQS 8
|
|
|
|
#define TC35892_INT_GPIO(x) (TC35892_NR_INTERNAL_IRQS + (x))
|
|
|
|
#define TC35892_NR_GPIOS 24
|
|
|
|
#define TC35892_NR_IRQS TC35892_INT_GPIO(TC35892_NR_GPIOS)
|
|
|
|
|
|
|
|
#define MOP500_EGPIO_NR_IRQS TC35892_NR_IRQS
|
|
|
|
|
|
|
|
#define MOP500_EGPIO_IRQ_BASE MOP500_AB8500_IRQ_END
|
|
|
|
#define MOP500_EGPIO_IRQ_END (MOP500_EGPIO_IRQ_BASE \
|
|
|
|
+ MOP500_EGPIO_NR_IRQS)
|
2010-12-03 15:05:38 +00:00
|
|
|
/* STMPE1601 irqs */
|
|
|
|
#define STMPE_NR_INTERNAL_IRQS 9
|
|
|
|
#define STMPE_INT_GPIO(x) (STMPE_NR_INTERNAL_IRQS + (x))
|
|
|
|
#define STMPE_NR_GPIOS 24
|
|
|
|
#define STMPE_NR_IRQS STMPE_INT_GPIO(STMPE_NR_GPIOS)
|
2010-08-09 13:48:17 +00:00
|
|
|
|
2010-12-03 15:05:38 +00:00
|
|
|
#define MOP500_STMPE1601_IRQBASE MOP500_EGPIO_IRQ_END
|
|
|
|
#define MOP500_STMPE1601_IRQ(x) (MOP500_STMPE1601_IRQBASE + (x))
|
|
|
|
|
2011-02-15 07:26:16 +00:00
|
|
|
#define MOP500_STMPE1601_IRQ_END \
|
|
|
|
MOP500_STMPE1601_IRQ(STMPE_NR_INTERNAL_IRQS)
|
2010-12-03 15:05:38 +00:00
|
|
|
|
2013-01-15 16:41:43 +00:00
|
|
|
#define MOP500_NR_IRQS MOP500_STMPE1601_IRQ_END
|
2011-02-15 07:26:16 +00:00
|
|
|
|
|
|
|
#define MOP500_IRQ_END MOP500_NR_IRQS
|
2010-07-26 10:12:15 +00:00
|
|
|
|
2011-03-29 19:59:51 +00:00
|
|
|
/*
|
|
|
|
* We may have several boards, but only one will run at a
|
|
|
|
* time, so the one with most IRQs will bump this ahead,
|
|
|
|
* but the IRQ_BOARD_START remains the same for either board.
|
|
|
|
*/
|
2010-07-26 10:12:15 +00:00
|
|
|
#if MOP500_IRQ_END > IRQ_BOARD_END
|
|
|
|
#undef IRQ_BOARD_END
|
|
|
|
#define IRQ_BOARD_END MOP500_IRQ_END
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif
|