m32r: Define symbols to unify platform-dependent ICU checks

On some m32r platforms, cascaded ICUs are used.
This patch is required to simplify ei_handler and consolidate platform-
dependent ICU check routines.

platform ICU/INT1 ICU/INT0 ICU/INT2
-------------- -------- -------- --------
m32104ut o - -
m32700ut o o o
opsput o o o
usrv o - -
(others) - - -

Signed-off-by: Hitoshi Yamamoto <hitoshiy@linux-m32r.org>
Signed-off-by: Hirokazu Takata <takata@linux-m32r.org>

+40
+20
arch/m32r/Kconfig
··· 57 58 config PLAT_USRV 59 bool "uServer" 60 61 config PLAT_M32700UT 62 bool "M32700UT" 63 help 64 The M3T-M32700UT is an evaluation board based on uT-Engine 65 specification. This board has an M32700 (Chaos) evaluation chip. ··· 72 73 config PLAT_OPSPUT 74 bool "OPSPUT" 75 help 76 The OPSPUT is an evaluation board based on uT-Engine 77 specification. This board has a OPSP-REP chip. ··· 96 97 config PLAT_M32104UT 98 bool "M32104UT" 99 help 100 The M3T-M32104UT is an reference board based on uT-Engine 101 specification. This board has a M32104 chip. ··· 156 bool 157 depends on CHIP_M32700 || CHIP_OPSP 158 default y 159 160 config BUS_CLOCK 161 int "Bus Clock [Hz] (integer)"
··· 57 58 config PLAT_USRV 59 bool "uServer" 60 + select PLAT_HAS_INT1ICU 61 62 config PLAT_M32700UT 63 bool "M32700UT" 64 + select PLAT_HAS_INT0ICU 65 + select PLAT_HAS_INT1ICU 66 + select PLAT_HAS_INT2ICU 67 help 68 The M3T-M32700UT is an evaluation board based on uT-Engine 69 specification. This board has an M32700 (Chaos) evaluation chip. ··· 68 69 config PLAT_OPSPUT 70 bool "OPSPUT" 71 + select PLAT_HAS_INT0ICU 72 + select PLAT_HAS_INT1ICU 73 + select PLAT_HAS_INT2ICU 74 help 75 The OPSPUT is an evaluation board based on uT-Engine 76 specification. This board has a OPSP-REP chip. ··· 89 90 config PLAT_M32104UT 91 bool "M32104UT" 92 + select PLAT_HAS_INT1ICU 93 help 94 The M3T-M32104UT is an reference board based on uT-Engine 95 specification. This board has a M32104 chip. ··· 148 bool 149 depends on CHIP_M32700 || CHIP_OPSP 150 default y 151 + 152 + config PLAT_HAS_INT0ICU 153 + bool 154 + default n 155 + 156 + config PLAT_HAS_INT1ICU 157 + bool 158 + default n 159 + 160 + config PLAT_HAS_INT2ICU 161 + bool 162 + default n 163 164 config BUS_CLOCK 165 int "Bus Clock [Hz] (integer)"
+20
include/asm-m32r/m32r.h
··· 22 #include <asm/m32700ut/m32700ut_pld.h> 23 #include <asm/m32700ut/m32700ut_lan.h> 24 #include <asm/m32700ut/m32700ut_lcd.h> 25 #endif /* CONFIG_PLAT_M32700UT */ 26 27 #if defined(CONFIG_PLAT_OPSPUT) 28 #include <asm/opsput/opsput_pld.h> 29 #include <asm/opsput/opsput_lan.h> 30 #include <asm/opsput/opsput_lcd.h> 31 #endif /* CONFIG_PLAT_OPSPUT */ 32 33 #if defined(CONFIG_PLAT_MAPPI2) ··· 54 55 #if defined(CONFIG_PLAT_USRV) 56 #include <asm/m32700ut/m32700ut_pld.h> 57 #endif 58 59 #if defined(CONFIG_PLAT_M32104UT) 60 #include <asm/m32104ut/m32104ut_pld.h> 61 #endif /* CONFIG_PLAT_M32104 */ 62 63 /*
··· 22 #include <asm/m32700ut/m32700ut_pld.h> 23 #include <asm/m32700ut/m32700ut_lan.h> 24 #include <asm/m32700ut/m32700ut_lcd.h> 25 + /* for ei_handler:linux/arch/m32r/kernel/entry.S */ 26 + #define M32R_INT1ICU_ISTS PLD_ICUISTS 27 + #define M32R_INT1ICU_IRQ_BASE M32700UT_PLD_IRQ_BASE 28 + #define M32R_INT0ICU_ISTS M32700UT_LAN_ICUISTS 29 + #define M32R_INT0ICU_IRQ_BASE M32700UT_LAN_PLD_IRQ_BASE 30 + #define M32R_INT2ICU_ISTS M32700UT_LCD_ICUISTS 31 + #define M32R_INT2ICU_IRQ_BASE M32700UT_LCD_PLD_IRQ_BASE 32 #endif /* CONFIG_PLAT_M32700UT */ 33 34 #if defined(CONFIG_PLAT_OPSPUT) 35 #include <asm/opsput/opsput_pld.h> 36 #include <asm/opsput/opsput_lan.h> 37 #include <asm/opsput/opsput_lcd.h> 38 + /* for ei_handler:linux/arch/m32r/kernel/entry.S */ 39 + #define M32R_INT1ICU_ISTS PLD_ICUISTS 40 + #define M32R_INT1ICU_IRQ_BASE OPSPUT_PLD_IRQ_BASE 41 + #define M32R_INT0ICU_ISTS OPSPUT_LAN_ICUISTS 42 + #define M32R_INT0ICU_IRQ_BASE OPSPUT_LAN_PLD_IRQ_BASE 43 + #define M32R_INT2ICU_ISTS OPSPUT_LCD_ICUISTS 44 + #define M32R_INT2ICU_IRQ_BASE OPSPUT_LCD_PLD_IRQ_BASE 45 #endif /* CONFIG_PLAT_OPSPUT */ 46 47 #if defined(CONFIG_PLAT_MAPPI2) ··· 40 41 #if defined(CONFIG_PLAT_USRV) 42 #include <asm/m32700ut/m32700ut_pld.h> 43 + /* for ei_handler:linux/arch/m32r/kernel/entry.S */ 44 + #define M32R_INT1ICU_ISTS PLD_ICUISTS 45 + #define M32R_INT1ICU_IRQ_BASE M32700UT_PLD_IRQ_BASE 46 #endif 47 48 #if defined(CONFIG_PLAT_M32104UT) 49 #include <asm/m32104ut/m32104ut_pld.h> 50 + /* for ei_handler:linux/arch/m32r/kernel/entry.S */ 51 + #define M32R_INT1ICU_ISTS PLD_ICUISTS 52 + #define M32R_INT1ICU_IRQ_BASE M32104UT_PLD_IRQ_BASE 53 #endif /* CONFIG_PLAT_M32104 */ 54 55 /*