SPEAr3xx: Unify build of SPEAr3xx platforms
Subsystems (2)
cover SPEAr3xx: Unify build of SPEAr3xx platforms
Rework the SPEAr3xx code to allow all three SPEAr3xx platforms to be built into a single kernel.
I do not have access to any SPEAr3xx hardware, so the patch series is build tested only.
Ryan Mallon (5):
SPEAr3xx: Make local structres static
SPEAR3xx: Rename register/irq defines to remove naming conflicts
SPEAr3xx: Rework pmx_dev code to remove conflicts
SPEAr3xx: Rework KConfig to allow all boards to be compiled in
SPEAr3xx: Replace defconfigs with single unfied defconfig
arch/arm/configs/spear300_defconfig | 773 ----------------------- arch/arm/configs/spear310_defconfig | 775 ------------------------ arch/arm/configs/spear320_defconfig | 775 ------------------------ arch/arm/configs/spear3xx_defconfig | 775 ++++++++++++++++++++++++ arch/arm/mach-spear3xx/Kconfig | 30 +- arch/arm/mach-spear3xx/Kconfig300 | 17 - arch/arm/mach-spear3xx/Kconfig310 | 17 - arch/arm/mach-spear3xx/Kconfig320 | 17 - arch/arm/mach-spear3xx/include/mach/generic.h | 139 ++--- arch/arm/mach-spear3xx/include/mach/irqs.h | 195 +++--- arch/arm/mach-spear3xx/include/mach/spear300.h | 26 +- arch/arm/mach-spear3xx/include/mach/spear310.h | 44 +- arch/arm/mach-spear3xx/include/mach/spear320.h | 50 +- arch/arm/mach-spear3xx/spear300.c | 135 ++-- arch/arm/mach-spear3xx/spear300_evb.c | 26 +- arch/arm/mach-spear3xx/spear310.c | 137 +++-- arch/arm/mach-spear3xx/spear310_evb.c | 42 +- arch/arm/mach-spear3xx/spear320.c | 247 ++++---- arch/arm/mach-spear3xx/spear320_evb.c | 36 +- arch/arm/mach-spear3xx/spear3xx.c | 124 ++-- 20 files changed, 1387 insertions(+), 2993 deletions(-) delete mode 100644 arch/arm/configs/spear300_defconfig delete mode 100644 arch/arm/configs/spear310_defconfig delete mode 100644 arch/arm/configs/spear320_defconfig create mode 100644 arch/arm/configs/spear3xx_defconfig delete mode 100644 arch/arm/mach-spear3xx/Kconfig300 delete mode 100644 arch/arm/mach-spear3xx/Kconfig310 delete mode 100644 arch/arm/mach-spear3xx/Kconfig320
PATCH 1/5 SPEAr3xx: Make local structres static
Several structures in arch/arm/mach-spear3xx are not marked static like they should be. Fix this.
--- arch/arm/mach-spear3xx/spear300.c | 33 ++++++++++---------- arch/arm/mach-spear3xx/spear310.c | 16 +++++----- arch/arm/mach-spear3xx/spear320.c | 56 +++++++++++++++++----------------- arch/arm/mach-spear3xx/spear3xx.c | 60 ++++++++++++++++++------------------ 4 files changed, 83 insertions(+), 82 deletions(-)
arch/arm/mach-spear3xx/spear300.c +17 -16
@@ -119,7 +119,7 @@ struct pmx_mode caml_lcd_mode = { };/* devices */ -struct pmx_dev_mode pmx_fsmc_2_chips_modes[] = { +static struct pmx_dev_mode pmx_fsmc_2_chips_modes[] = { { .ids =NAND_MODE |NOR_MODE |PHOTO_FRAME_MODE |ATA_PABX_WI2S_MODE |ATA_PABX_I2S_MODE ,
@@ -134,7 +134,7 @@ struct pmx_dev pmx_fsmc_2_chips = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_fsmc_4_chips_modes[] = { +static struct pmx_dev_mode pmx_fsmc_4_chips_modes[] = { { .ids =NAND_MODE |NOR_MODE |PHOTO_FRAME_MODE |ATA_PABX_WI2S_MODE |ATA_PABX_I2S_MODE ,
@@ -149,7 +149,7 @@ struct pmx_dev pmx_fsmc_4_chips = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_keyboard_modes[] = { +static struct pmx_dev_mode pmx_keyboard_modes[] = { { .ids =LEND_IP_PHONE_MODE |HEND_IP_PHONE_MODE | LEND_WIFI_PHONE_MODE | HEND_WIFI_PHONE_MODE |
@@ -166,7 +166,7 @@ struct pmx_dev pmx_keyboard = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_clcd_modes[] = { +static struct pmx_dev_mode pmx_clcd_modes[] = { { .ids =PHOTO_FRAME_MODE , .mask =PMX_TIMER_1_2_MASK |PMX_TIMER_3_4_MASK ,
@@ -184,7 +184,7 @@ struct pmx_dev pmx_clcd = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_gpio_modes[] = { +static struct pmx_dev_mode pmx_telecom_gpio_modes[] = { { .ids =PHOTO_FRAME_MODE |CAMU_LCD_MODE |CAML_LCD_MODE , .mask =PMX_MII_MASK ,
@@ -211,7 +211,7 @@ struct pmx_dev pmx_telecom_gpio = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_tdm_modes[] = { +static struct pmx_dev_mode pmx_telecom_tdm_modes[] = { { .ids =PHOTO_FRAME_MODE |LEND_IP_PHONE_MODE |HEND_IP_PHONE_MODE |LEND_WIFI_PHONE_MODE
@@ -229,7 +229,7 @@ struct pmx_dev pmx_telecom_tdm = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_spi_cs_i2c_clk_modes[] = { +static struct pmx_dev_mode pmx_telecom_spi_cs_i2c_clk_modes[] = { { .ids =LEND_IP_PHONE_MODE |HEND_IP_PHONE_MODE |LEND_WIFI_PHONE_MODE |HEND_WIFI_PHONE_MODE
@@ -246,7 +246,7 @@ struct pmx_dev pmx_telecom_spi_cs_i2c_clk = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_camera_modes[] = { +static struct pmx_dev_mode pmx_telecom_camera_modes[] = { { .ids =CAML_LCDW_MODE |CAML_LCD_MODE , .mask =PMX_MII_MASK ,
@@ -263,7 +263,7 @@ struct pmx_dev pmx_telecom_camera = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_dac_modes[] = { +static struct pmx_dev_mode pmx_telecom_dac_modes[] = { { .ids =ATA_PABX_I2S_MODE |CAML_LCDW_MODE |CAMU_LCD_MODE |CAMU_WLCD_MODE |CAML_LCD_MODE ,
@@ -278,7 +278,7 @@ struct pmx_dev pmx_telecom_dac = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_i2s_modes[] = { +static struct pmx_dev_mode pmx_telecom_i2s_modes[] = { { .ids =LEND_IP_PHONE_MODE |HEND_IP_PHONE_MODE | LEND_WIFI_PHONE_MODE | HEND_WIFI_PHONE_MODE |
@@ -295,7 +295,7 @@ struct pmx_dev pmx_telecom_i2s = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_boot_pins_modes[] = { +static struct pmx_dev_mode pmx_telecom_boot_pins_modes[] = { { .ids =NAND_MODE |NOR_MODE , .mask = PMX_UART0_MODEM_MASK | PMX_TIMER_1_2_MASK |
@@ -310,7 +310,7 @@ struct pmx_dev pmx_telecom_boot_pins = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_sdio_4bit_modes[] = { +static struct pmx_dev_mode pmx_telecom_sdio_4bit_modes[] = { { .ids =PHOTO_FRAME_MODE |LEND_IP_PHONE_MODE | HEND_IP_PHONE_MODE | LEND_WIFI_PHONE_MODE |
@@ -330,7 +330,7 @@ struct pmx_dev pmx_telecom_sdio_4bit = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_sdio_8bit_modes[] = { +static struct pmx_dev_mode pmx_telecom_sdio_8bit_modes[] = { { .ids =PHOTO_FRAME_MODE |LEND_IP_PHONE_MODE | HEND_IP_PHONE_MODE | LEND_WIFI_PHONE_MODE |
@@ -349,7 +349,7 @@ struct pmx_dev pmx_telecom_sdio_8bit = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_gpio1_modes[] = { +static struct pmx_dev_mode pmx_gpio1_modes[] = { { .ids =PHOTO_FRAME_MODE , .mask = PMX_UART0_MODEM_MASK | PMX_TIMER_1_2_MASK |
@@ -391,7 +391,7 @@ struct amba_device gpio1_device = { };/* spear3xx shared irq */ -struct shirq_dev_config shirq_ras1_config[] = { +static struct shirq_dev_config shirq_ras1_config[] = { { .virq =VIRQ_IT_PERS_S , .enb_mask =IT_PERS_S_IRQ_MASK ,
@@ -431,7 +431,8 @@ struct shirq_dev_config shirq_ras1_config[] = { }, }; -struct spear_shirq shirq_ras1 = { + +static struct spear_shirq shirq_ras1 = { .irq =IRQ_GEN_RAS_1 , .dev_config = shirq_ras1_config, .dev_count =ARRAY_SIZE (shirq_ras1_config),
arch/arm/mach-spear3xx/spear310.c +8 -8
@@ -142,7 +142,7 @@ struct pmx_driver pmx_driver = {/* Add spear310 specific devices here */ /* spear3xx shared irq */ -struct shirq_dev_config shirq_ras1_config[] = { +static struct shirq_dev_config shirq_ras1_config[] = { { .virq =VIRQ_SMII0 , .status_mask =SMII0_IRQ_MASK ,
@@ -170,7 +170,7 @@ struct shirq_dev_config shirq_ras1_config[] = { }, }; -struct spear_shirq shirq_ras1 = { +static struct spear_shirq shirq_ras1 = { .irq =IRQ_GEN_RAS_1 , .dev_config = shirq_ras1_config, .dev_count =ARRAY_SIZE (shirq_ras1_config),
@@ -182,7 +182,7 @@ struct spear_shirq shirq_ras1 = { }, }; -struct shirq_dev_config shirq_ras2_config[] = { +static struct shirq_dev_config shirq_ras2_config[] = { { .virq =VIRQ_UART1 , .status_mask =UART1_IRQ_MASK ,
@@ -201,7 +201,7 @@ struct shirq_dev_config shirq_ras2_config[] = { }, }; -struct spear_shirq shirq_ras2 = { +static struct spear_shirq shirq_ras2 = { .irq =IRQ_GEN_RAS_2 , .dev_config = shirq_ras2_config, .dev_count =ARRAY_SIZE (shirq_ras2_config),
@@ -213,14 +213,14 @@ struct spear_shirq shirq_ras2 = { }, }; -struct shirq_dev_config shirq_ras3_config[] = { +static struct shirq_dev_config shirq_ras3_config[] = { { .virq =VIRQ_EMI , .status_mask =EMI_IRQ_MASK , }, }; -struct spear_shirq shirq_ras3 = { +static struct spear_shirq shirq_ras3 = { .irq =IRQ_GEN_RAS_3 , .dev_config = shirq_ras3_config, .dev_count =ARRAY_SIZE (shirq_ras3_config),
@@ -232,7 +232,7 @@ struct spear_shirq shirq_ras3 = { }, }; -struct shirq_dev_config shirq_intrcomm_ras_config[] = { +static struct shirq_dev_config shirq_intrcomm_ras_config[] = { { .virq =VIRQ_TDM_HDLC , .status_mask =TDM_HDLC_IRQ_MASK ,
@@ -245,7 +245,7 @@ struct shirq_dev_config shirq_intrcomm_ras_config[] = { }, }; -struct spear_shirq shirq_intrcomm_ras = { +static struct spear_shirq shirq_intrcomm_ras = { .irq =IRQ_INTRCOMM_RAS_ARM , .dev_config = shirq_intrcomm_ras_config, .dev_count =ARRAY_SIZE (shirq_intrcomm_ras_config),
arch/arm/mach-spear3xx/spear320.c +28 -28
224 lines not on this page · raw message
arch/arm/mach-spear3xx/spear3xx.c +30 -30
240 lines not on this page · raw message
Signature · 1 line
1.5.5
PATCH 1/5 SPEAr3xx: Make local structres static
Quoted 757 lines · Ryan Mallon
Several structures in
arch/arm/mach-spear3xxare not marked static like they should be. Fix this.Signed-off-by Ryan Mallon <[email protected]>--- arch/arm/mach-spear3xx/spear300.c | 33 ++++++++++---------- arch/arm/mach-spear3xx/spear310.c | 16 +++++----- arch/arm/mach-spear3xx/spear320.c | 56 +++++++++++++++++----------------- arch/arm/mach-spear3xx/spear3xx.c | 60 ++++++++++++++++++------------------ 4 files changed, 83 insertions(+), 82 deletions(-)arch/arm/mach-spear3xx/spear300.c +17
-16@@ -119,7 +119,7 @@ struct pmx_mode caml_lcd_mode = { };/* devices */ -struct pmx_dev_mode pmx_fsmc_2_chips_modes[] = { +static struct pmx_dev_mode pmx_fsmc_2_chips_modes[] = { { .ids =NAND_MODE |NOR_MODE |PHOTO_FRAME_MODE |ATA_PABX_WI2S_MODE |ATA_PABX_I2S_MODE ,@@ -134,7 +134,7 @@ struct pmx_dev pmx_fsmc_2_chips = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_fsmc_4_chips_modes[] = { +static struct pmx_dev_mode pmx_fsmc_4_chips_modes[] = { { .ids =NAND_MODE |NOR_MODE |PHOTO_FRAME_MODE |ATA_PABX_WI2S_MODE |ATA_PABX_I2S_MODE ,@@ -149,7 +149,7 @@ struct pmx_dev pmx_fsmc_4_chips = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_keyboard_modes[] = { +static struct pmx_dev_mode pmx_keyboard_modes[] = { { .ids =LEND_IP_PHONE_MODE |HEND_IP_PHONE_MODE | LEND_WIFI_PHONE_MODE | HEND_WIFI_PHONE_MODE |@@ -166,7 +166,7 @@ struct pmx_dev pmx_keyboard = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_clcd_modes[] = { +static struct pmx_dev_mode pmx_clcd_modes[] = { { .ids =PHOTO_FRAME_MODE , .mask =PMX_TIMER_1_2_MASK |PMX_TIMER_3_4_MASK ,@@ -184,7 +184,7 @@ struct pmx_dev pmx_clcd = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_gpio_modes[] = { +static struct pmx_dev_mode pmx_telecom_gpio_modes[] = { { .ids =PHOTO_FRAME_MODE |CAMU_LCD_MODE |CAML_LCD_MODE , .mask =PMX_MII_MASK ,@@ -211,7 +211,7 @@ struct pmx_dev pmx_telecom_gpio = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_tdm_modes[] = { +static struct pmx_dev_mode pmx_telecom_tdm_modes[] = { { .ids =PHOTO_FRAME_MODE |LEND_IP_PHONE_MODE |HEND_IP_PHONE_MODE |LEND_WIFI_PHONE_MODE @@ -229,7 +229,7 @@ struct pmx_dev pmx_telecom_tdm = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_spi_cs_i2c_clk_modes[] = { +static struct pmx_dev_mode pmx_telecom_spi_cs_i2c_clk_modes[] = { { .ids =LEND_IP_PHONE_MODE |HEND_IP_PHONE_MODE |LEND_WIFI_PHONE_MODE |HEND_WIFI_PHONE_MODE @@ -246,7 +246,7 @@ struct pmx_dev pmx_telecom_spi_cs_i2c_clk = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_camera_modes[] = { +static struct pmx_dev_mode pmx_telecom_camera_modes[] = { { .ids =CAML_LCDW_MODE |CAML_LCD_MODE , .mask =PMX_MII_MASK ,@@ -263,7 +263,7 @@ struct pmx_dev pmx_telecom_camera = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_dac_modes[] = { +static struct pmx_dev_mode pmx_telecom_dac_modes[] = { { .ids =ATA_PABX_I2S_MODE |CAML_LCDW_MODE |CAMU_LCD_MODE |CAMU_WLCD_MODE |CAML_LCD_MODE ,@@ -278,7 +278,7 @@ struct pmx_dev pmx_telecom_dac = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_i2s_modes[] = { +static struct pmx_dev_mode pmx_telecom_i2s_modes[] = { { .ids =LEND_IP_PHONE_MODE |HEND_IP_PHONE_MODE | LEND_WIFI_PHONE_MODE | HEND_WIFI_PHONE_MODE |@@ -295,7 +295,7 @@ struct pmx_dev pmx_telecom_i2s = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_boot_pins_modes[] = { +static struct pmx_dev_mode pmx_telecom_boot_pins_modes[] = { { .ids =NAND_MODE |NOR_MODE , .mask = PMX_UART0_MODEM_MASK | PMX_TIMER_1_2_MASK |@@ -310,7 +310,7 @@ struct pmx_dev pmx_telecom_boot_pins = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_sdio_4bit_modes[] = { +static struct pmx_dev_mode pmx_telecom_sdio_4bit_modes[] = { { .ids =PHOTO_FRAME_MODE |LEND_IP_PHONE_MODE | HEND_IP_PHONE_MODE | LEND_WIFI_PHONE_MODE |@@ -330,7 +330,7 @@ struct pmx_dev pmx_telecom_sdio_4bit = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_telecom_sdio_8bit_modes[] = { +static struct pmx_dev_mode pmx_telecom_sdio_8bit_modes[] = { { .ids =PHOTO_FRAME_MODE |LEND_IP_PHONE_MODE | HEND_IP_PHONE_MODE | LEND_WIFI_PHONE_MODE |@@ -349,7 +349,7 @@ struct pmx_dev pmx_telecom_sdio_8bit = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_gpio1_modes[] = { +static struct pmx_dev_mode pmx_gpio1_modes[] = { { .ids =PHOTO_FRAME_MODE , .mask = PMX_UART0_MODEM_MASK | PMX_TIMER_1_2_MASK |@@ -391,7 +391,7 @@ struct amba_device gpio1_device = { };/* spear3xx shared irq */ -struct shirq_dev_config shirq_ras1_config[] = { +static struct shirq_dev_config shirq_ras1_config[] = { { .virq =VIRQ_IT_PERS_S , .enb_mask =IT_PERS_S_IRQ_MASK ,@@ -431,7 +431,8 @@ struct shirq_dev_config shirq_ras1_config[] = { }, }; -struct spear_shirq shirq_ras1 = { + +static struct spear_shirq shirq_ras1 = { .irq =IRQ_GEN_RAS_1 , .dev_config = shirq_ras1_config, .dev_count =ARRAY_SIZE (shirq_ras1_config),arch/arm/mach-spear3xx/spear310.c +8
-8@@ -142,7 +142,7 @@ struct pmx_driver pmx_driver = {/* Add spear310 specific devices here */ /* spear3xx shared irq */ -struct shirq_dev_config shirq_ras1_config[] = { +static struct shirq_dev_config shirq_ras1_config[] = { { .virq =VIRQ_SMII0 , .status_mask =SMII0_IRQ_MASK ,@@ -170,7 +170,7 @@ struct shirq_dev_config shirq_ras1_config[] = { }, }; -struct spear_shirq shirq_ras1 = { +static struct spear_shirq shirq_ras1 = { .irq =IRQ_GEN_RAS_1 , .dev_config = shirq_ras1_config, .dev_count =ARRAY_SIZE (shirq_ras1_config),@@ -182,7 +182,7 @@ struct spear_shirq shirq_ras1 = { }, }; -struct shirq_dev_config shirq_ras2_config[] = { +static struct shirq_dev_config shirq_ras2_config[] = { { .virq =VIRQ_UART1 , .status_mask =UART1_IRQ_MASK ,@@ -201,7 +201,7 @@ struct shirq_dev_config shirq_ras2_config[] = { }, }; -struct spear_shirq shirq_ras2 = { +static struct spear_shirq shirq_ras2 = { .irq =IRQ_GEN_RAS_2 , .dev_config = shirq_ras2_config, .dev_count =ARRAY_SIZE (shirq_ras2_config),@@ -213,14 +213,14 @@ struct spear_shirq shirq_ras2 = { }, }; -struct shirq_dev_config shirq_ras3_config[] = { +static struct shirq_dev_config shirq_ras3_config[] = { { .virq =VIRQ_EMI , .status_mask =EMI_IRQ_MASK , }, }; -struct spear_shirq shirq_ras3 = { +static struct spear_shirq shirq_ras3 = { .irq =IRQ_GEN_RAS_3 , .dev_config = shirq_ras3_config, .dev_count =ARRAY_SIZE (shirq_ras3_config),@@ -232,7 +232,7 @@ struct spear_shirq shirq_ras3 = { }, }; -struct shirq_dev_config shirq_intrcomm_ras_config[] = { +static struct shirq_dev_config shirq_intrcomm_ras_config[] = { { .virq =VIRQ_TDM_HDLC , .status_mask =TDM_HDLC_IRQ_MASK ,@@ -245,7 +245,7 @@ struct shirq_dev_config shirq_intrcomm_ras_config[] = { }, }; -struct spear_shirq shirq_intrcomm_ras = { +static struct spear_shirq shirq_intrcomm_ras = { .irq =IRQ_INTRCOMM_RAS_ARM , .dev_config = shirq_intrcomm_ras_config, .dev_count =ARRAY_SIZE (shirq_intrcomm_ras_config),arch/arm/mach-spear3xx/spear320.c +28
-28@@ -54,7 +54,7 @@ struct pmx_mode small_printers_mode = { };/* devices */ -struct pmx_dev_mode pmx_clcd_modes[] = { +static struct pmx_dev_mode pmx_clcd_modes[] = { { .ids =AUTO_NET_SMII_MODE , .mask =0x0 ,@@ -68,7 +68,7 @@ struct pmx_dev pmx_clcd = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_emi_modes[] = { +static struct pmx_dev_mode pmx_emi_modes[] = { { .ids =AUTO_EXP_MODE , .mask =PMX_TIMER_1_2_MASK |PMX_TIMER_3_4_MASK ,@@ -82,7 +82,7 @@ struct pmx_dev pmx_emi = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_fsmc_modes[] = { +static struct pmx_dev_mode pmx_fsmc_modes[] = { { .ids =ALL_MODES , .mask =0x0 ,@@ -96,7 +96,7 @@ struct pmx_dev pmx_fsmc = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_spp_modes[] = { +static struct pmx_dev_mode pmx_spp_modes[] = { { .ids =SMALL_PRINTERS_MODE , .mask =0x0 ,@@ -110,7 +110,7 @@ struct pmx_dev pmx_spp = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_sdio_modes[] = { +static struct pmx_dev_mode pmx_sdio_modes[] = { { .ids =AUTO_NET_SMII_MODE |AUTO_NET_MII_MODE |SMALL_PRINTERS_MODE ,@@ -125,7 +125,7 @@ struct pmx_dev pmx_sdio = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_i2s_modes[] = { +static struct pmx_dev_mode pmx_i2s_modes[] = { { .ids =AUTO_NET_SMII_MODE |AUTO_NET_MII_MODE , .mask =PMX_UART0_MODEM_MASK ,@@ -139,7 +139,7 @@ struct pmx_dev pmx_i2s = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_uart1_modes[] = { +static struct pmx_dev_mode pmx_uart1_modes[] = { { .ids =ALL_MODES , .mask =PMX_GPIO_PIN0_MASK |PMX_GPIO_PIN1_MASK ,@@ -153,7 +153,7 @@ struct pmx_dev pmx_uart1 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_uart1_modem_modes[] = { +static struct pmx_dev_mode pmx_uart1_modem_modes[] = { { .ids =AUTO_EXP_MODE , .mask = PMX_TIMER_1_2_MASK | PMX_TIMER_3_4_MASK |@@ -172,7 +172,7 @@ struct pmx_dev pmx_uart1_modem = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_uart2_modes[] = { +static struct pmx_dev_mode pmx_uart2_modes[] = { { .ids =ALL_MODES , .mask =PMX_FIRDA_MASK ,@@ -186,7 +186,7 @@ struct pmx_dev pmx_uart2 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_touchscreen_modes[] = { +static struct pmx_dev_mode pmx_touchscreen_modes[] = { { .ids =AUTO_NET_SMII_MODE , .mask =PMX_SSP_CS_MASK ,@@ -200,7 +200,7 @@ struct pmx_dev pmx_touchscreen = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_can_modes[] = { +static struct pmx_dev_mode pmx_can_modes[] = { { .ids =AUTO_NET_SMII_MODE |AUTO_NET_MII_MODE |AUTO_EXP_MODE , .mask = PMX_GPIO_PIN2_MASK | PMX_GPIO_PIN3_MASK |@@ -215,7 +215,7 @@ struct pmx_dev pmx_can = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_sdio_led_modes[] = { +static struct pmx_dev_mode pmx_sdio_led_modes[] = { { .ids =AUTO_NET_SMII_MODE |AUTO_NET_MII_MODE , .mask =PMX_SSP_CS_MASK ,@@ -229,7 +229,7 @@ struct pmx_dev pmx_sdio_led = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_pwm0_modes[] = { +static struct pmx_dev_mode pmx_pwm0_modes[] = { { .ids =AUTO_NET_SMII_MODE |AUTO_NET_MII_MODE , .mask =PMX_UART0_MODEM_MASK ,@@ -246,7 +246,7 @@ struct pmx_dev pmx_pwm0 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_pwm1_modes[] = { +static struct pmx_dev_mode pmx_pwm1_modes[] = { { .ids =AUTO_NET_SMII_MODE |AUTO_NET_MII_MODE , .mask =PMX_UART0_MODEM_MASK ,@@ -263,7 +263,7 @@ struct pmx_dev pmx_pwm1 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_pwm2_modes[] = { +static struct pmx_dev_mode pmx_pwm2_modes[] = { { .ids =AUTO_NET_SMII_MODE |AUTO_NET_MII_MODE , .mask =PMX_SSP_CS_MASK ,@@ -280,7 +280,7 @@ struct pmx_dev pmx_pwm2 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_pwm3_modes[] = { +static struct pmx_dev_mode pmx_pwm3_modes[] = { { .ids =AUTO_EXP_MODE |SMALL_PRINTERS_MODE |AUTO_NET_SMII_MODE , .mask =PMX_MII_MASK ,@@ -294,7 +294,7 @@ struct pmx_dev pmx_pwm3 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_ssp1_modes[] = { +static struct pmx_dev_mode pmx_ssp1_modes[] = { { .ids =SMALL_PRINTERS_MODE |AUTO_NET_SMII_MODE , .mask =PMX_MII_MASK ,@@ -308,7 +308,7 @@ struct pmx_dev pmx_ssp1 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_ssp2_modes[] = { +static struct pmx_dev_mode pmx_ssp2_modes[] = { { .ids =AUTO_NET_SMII_MODE , .mask =PMX_MII_MASK ,@@ -322,7 +322,7 @@ struct pmx_dev pmx_ssp2 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_mii1_modes[] = { +static struct pmx_dev_mode pmx_mii1_modes[] = { { .ids =AUTO_NET_MII_MODE , .mask =0x0 ,@@ -336,7 +336,7 @@ struct pmx_dev pmx_mii1 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_smii0_modes[] = { +static struct pmx_dev_mode pmx_smii0_modes[] = { { .ids =AUTO_NET_SMII_MODE |AUTO_EXP_MODE |SMALL_PRINTERS_MODE , .mask =PMX_MII_MASK ,@@ -350,7 +350,7 @@ struct pmx_dev pmx_smii0 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_smii1_modes[] = { +static struct pmx_dev_mode pmx_smii1_modes[] = { { .ids =AUTO_NET_SMII_MODE |SMALL_PRINTERS_MODE , .mask =PMX_MII_MASK ,@@ -364,7 +364,7 @@ struct pmx_dev pmx_smii1 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_i2c1_modes[] = { +static struct pmx_dev_mode pmx_i2c1_modes[] = { { .ids =AUTO_EXP_MODE , .mask =0x0 ,@@ -387,7 +387,7 @@ struct pmx_driver pmx_driver = {/* Add spear320 specific devices here */ /* spear3xx shared irq */ -struct shirq_dev_config shirq_ras1_config[] = { +static struct shirq_dev_config shirq_ras1_config[] = { { .virq =VIRQ_EMI , .status_mask =EMI_IRQ_MASK ,@@ -403,7 +403,7 @@ struct shirq_dev_config shirq_ras1_config[] = { }, }; -struct spear_shirq shirq_ras1 = { +static struct spear_shirq shirq_ras1 = { .irq =IRQ_GEN_RAS_1 , .dev_config = shirq_ras1_config, .dev_count =ARRAY_SIZE (shirq_ras1_config),@@ -416,7 +416,7 @@ struct spear_shirq shirq_ras1 = { }, }; -struct shirq_dev_config shirq_ras3_config[] = { +static struct shirq_dev_config shirq_ras3_config[] = { { .virq =VIRQ_PLGPIO , .enb_mask =GPIO_IRQ_MASK ,@@ -435,7 +435,7 @@ struct shirq_dev_config shirq_ras3_config[] = { }, }; -struct spear_shirq shirq_ras3 = { +static struct spear_shirq shirq_ras3 = { .irq =IRQ_GEN_RAS_3 , .dev_config = shirq_ras3_config, .dev_count =ARRAY_SIZE (shirq_ras3_config),@@ -449,7 +449,7 @@ struct spear_shirq shirq_ras3 = { }, }; -struct shirq_dev_config shirq_intrcomm_ras_config[] = { +static struct shirq_dev_config shirq_intrcomm_ras_config[] = { { .virq =VIRQ_CANU , .status_mask =CAN_U_IRQ_MASK ,@@ -497,7 +497,7 @@ struct shirq_dev_config shirq_intrcomm_ras_config[] = { }, }; -struct spear_shirq shirq_intrcomm_ras = { +static struct spear_shirq shirq_intrcomm_ras = { .irq =IRQ_INTRCOMM_RAS_ARM , .dev_config = shirq_intrcomm_ras_config, .dev_count =ARRAY_SIZE (shirq_intrcomm_ras_config),arch/arm/mach-spear3xx/spear3xx.c +29
-29@@ -102,7 +102,7 @@ void __init spear3xx_map_io(void)/* pad multiplexing support */ /* devices */ -struct pmx_dev_mode pmx_firda_modes[] = { +static struct pmx_dev_mode pmx_firda_modes[] = { { .ids =0xffffffff , .mask =PMX_FIRDA_MASK ,@@ -116,7 +116,7 @@ struct pmx_dev pmx_firda = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_i2c_modes[] = { +static struct pmx_dev_mode pmx_i2c_modes[] = { { .ids =0xffffffff , .mask =PMX_I2C_MASK ,@@ -130,7 +130,7 @@ struct pmx_dev pmx_i2c = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_ssp_cs_modes[] = { +static struct pmx_dev_mode pmx_ssp_cs_modes[] = { { .ids =0xffffffff , .mask =PMX_SSP_CS_MASK ,@@ -144,7 +144,7 @@ struct pmx_dev pmx_ssp_cs = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_ssp_modes[] = { +static struct pmx_dev_mode pmx_ssp_modes[] = { { .ids =0xffffffff , .mask =PMX_SSP_MASK ,@@ -158,7 +158,7 @@ struct pmx_dev pmx_ssp = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_mii_modes[] = { +static struct pmx_dev_mode pmx_mii_modes[] = { { .ids =0xffffffff , .mask =PMX_MII_MASK ,@@ -172,7 +172,7 @@ struct pmx_dev pmx_mii = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_gpio_pin0_modes[] = { +static struct pmx_dev_mode pmx_gpio_pin0_modes[] = { { .ids =0xffffffff , .mask =PMX_GPIO_PIN0_MASK ,@@ -186,7 +186,7 @@ struct pmx_dev pmx_gpio_pin0 = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_gpio_pin1_modes[] = { +static struct pmx_dev_mode pmx_gpio_pin1_modes[] = { { .ids =0xffffffff , .mask =PMX_GPIO_PIN1_MASK ,@@ -200,7 +200,7 @@ struct pmx_dev pmx_gpio_pin1 = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_gpio_pin2_modes[] = { +static struct pmx_dev_mode pmx_gpio_pin2_modes[] = { { .ids =0xffffffff , .mask =PMX_GPIO_PIN2_MASK ,@@ -214,7 +214,7 @@ struct pmx_dev pmx_gpio_pin2 = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_gpio_pin3_modes[] = { +static struct pmx_dev_mode pmx_gpio_pin3_modes[] = { { .ids =0xffffffff , .mask =PMX_GPIO_PIN3_MASK ,@@ -228,7 +228,7 @@ struct pmx_dev pmx_gpio_pin3 = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_gpio_pin4_modes[] = { +static struct pmx_dev_mode pmx_gpio_pin4_modes[] = { { .ids =0xffffffff , .mask =PMX_GPIO_PIN4_MASK ,@@ -242,7 +242,7 @@ struct pmx_dev pmx_gpio_pin4 = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_gpio_pin5_modes[] = { +static struct pmx_dev_mode pmx_gpio_pin5_modes[] = { { .ids =0xffffffff , .mask =PMX_GPIO_PIN5_MASK ,@@ -256,7 +256,7 @@ struct pmx_dev pmx_gpio_pin5 = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_uart0_modem_modes[] = { +static struct pmx_dev_mode pmx_uart0_modem_modes[] = { { .ids =0xffffffff , .mask =PMX_UART0_MODEM_MASK ,@@ -270,7 +270,7 @@ struct pmx_dev pmx_uart0_modem = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_uart0_modes[] = { +static struct pmx_dev_mode pmx_uart0_modes[] = { { .ids =0xffffffff , .mask =PMX_UART0_MASK ,@@ -284,7 +284,7 @@ struct pmx_dev pmx_uart0 = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_timer_3_4_modes[] = { +static struct pmx_dev_mode pmx_timer_3_4_modes[] = { { .ids =0xffffffff , .mask =PMX_TIMER_3_4_MASK ,@@ -298,7 +298,7 @@ struct pmx_dev pmx_timer_3_4 = { .enb_on_reset = 0, }; -struct pmx_dev_mode pmx_timer_1_2_modes[] = { +static struct pmx_dev_mode pmx_timer_1_2_modes[] = { { .ids =0xffffffff , .mask =PMX_TIMER_1_2_MASK ,@@ -314,7 +314,7 @@ struct pmx_dev pmx_timer_1_2 = { #if defined(CONFIG_MACH_SPEAR310) || defined(CONFIG_MACH_SPEAR320) /* plgpios devices */ -struct pmx_dev_mode pmx_plgpio_0_1_modes[] = { +static struct pmx_dev_mode pmx_plgpio_0_1_modes[] = { { .ids = 0x00, .mask = PMX_FIRDA_MASK,@@ -328,7 +328,7 @@ struct pmx_dev pmx_plgpio_0_1 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_2_3_modes[] = { +static struct pmx_dev_mode pmx_plgpio_2_3_modes[] = { { .ids =0x00 , .mask =PMX_UART0_MASK ,@@ -342,7 +342,7 @@ struct pmx_dev pmx_plgpio_2_3 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_4_5_modes[] = { +static struct pmx_dev_mode pmx_plgpio_4_5_modes[] = { { .ids =0x00 , .mask =PMX_I2C_MASK ,@@ -356,7 +356,7 @@ struct pmx_dev pmx_plgpio_4_5 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_6_9_modes[] = { +static struct pmx_dev_mode pmx_plgpio_6_9_modes[] = { { .ids =0x00 , .mask =PMX_SSP_MASK ,@@ -370,7 +370,7 @@ struct pmx_dev pmx_plgpio_6_9 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_10_27_modes[] = { +static struct pmx_dev_mode pmx_plgpio_10_27_modes[] = { { .ids =0x00 , .mask =PMX_MII_MASK ,@@ -384,7 +384,7 @@ struct pmx_dev pmx_plgpio_10_27 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_28_modes[] = { +static struct pmx_dev_mode pmx_plgpio_28_modes[] = { { .ids =0x00 , .mask =PMX_GPIO_PIN0_MASK ,@@ -398,7 +398,7 @@ struct pmx_dev pmx_plgpio_28 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_29_modes[] = { +static struct pmx_dev_mode pmx_plgpio_29_modes[] = { { .ids =0x00 , .mask =PMX_GPIO_PIN1_MASK ,@@ -412,7 +412,7 @@ struct pmx_dev pmx_plgpio_29 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_30_modes[] = { +static struct pmx_dev_mode pmx_plgpio_30_modes[] = { { .ids =0x00 , .mask =PMX_GPIO_PIN2_MASK ,@@ -426,7 +426,7 @@ struct pmx_dev pmx_plgpio_30 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_31_modes[] = { +static struct pmx_dev_mode pmx_plgpio_31_modes[] = { { .ids =0x00 , .mask =PMX_GPIO_PIN3_MASK ,@@ -440,7 +440,7 @@ struct pmx_dev pmx_plgpio_31 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_32_modes[] = { +static struct pmx_dev_mode pmx_plgpio_32_modes[] = { { .ids =0x00 , .mask =PMX_GPIO_PIN4_MASK ,@@ -454,7 +454,7 @@ struct pmx_dev pmx_plgpio_32 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_33_modes[] = { +static struct pmx_dev_mode pmx_plgpio_33_modes[] = { { .ids =0x00 , .mask =PMX_GPIO_PIN5_MASK ,@@ -468,7 +468,7 @@ struct pmx_dev pmx_plgpio_33 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_34_36_modes[] = { +static struct pmx_dev_mode pmx_plgpio_34_36_modes[] = { { .ids =0x00 , .mask =PMX_SSP_CS_MASK ,@@ -482,7 +482,7 @@ struct pmx_dev pmx_plgpio_34_36 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_37_42_modes[] = { +static struct pmx_dev_mode pmx_plgpio_37_42_modes[] = { { .ids =0x00 , .mask =PMX_UART0_MODEM_MASK ,@@ -496,7 +496,7 @@ struct pmx_dev pmx_plgpio_37_42 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_43_44_47_48_modes[] = { +static struct pmx_dev_mode pmx_plgpio_43_44_47_48_modes[] = { { .ids =0x00 , .mask =PMX_TIMER_1_2_MASK ,
arch/arm/mach-spear3xx/spear3xx.c struct pmx_dev pmx_plgpio_43_44_47_48 = { · line 516
Quoted 8 lines
arch/arm/mach-spear3xx/spear3xx.c +1
-1@@ -510,7 +510,7 @@ struct pmx_dev pmx_plgpio_43_44_47_48 = { .enb_on_reset = 1, }; -struct pmx_dev_mode pmx_plgpio_45_46_49_50_modes[] = { +static struct pmx_dev_mode pmx_plgpio_45_46_49_50_modes[] = { { .ids =0x00 , .mask =PMX_TIMER_3_4_MASK ,
These structures are not local, they are used in spear3**_evb.c files, and hence can't be static.
PATCH 1/5 SPEAr3xx: Make local structres static
Quoted 12 lines · Viresh KUMAR
Quoted 11 lines · Ryan Mallon
Several structures in
arch/arm/mach-spear3xxare not marked static like they should be. Fix this.Signed-off-by Ryan Mallon <[email protected]>--- arch/arm/mach-spear3xx/spear300.c | 33 ++++++++++---------- arch/arm/mach-spear3xx/spear310.c | 16 +++++----- arch/arm/mach-spear3xx/spear320.c | 56 +++++++++++++++++----------------- arch/arm/mach-spear3xx/spear3xx.c | 60 ++++++++++++++++++------------------ 4 files changed, 83 insertions(+), 82 deletions(-)
<snip>
Quoted 8 lines
arch/arm/mach-spear3xx/spear3xx.c struct pmx_dev pmx_plgpio_43_44_47_48 = { · line 516
Quoted 5 lines
arch/arm/mach-spear3xx/spear3xx.c +1
-1-struct pmx_dev_mode pmx_plgpio_45_46_49_50_modes[] = { +static struct pmx_dev_mode pmx_plgpio_45_46_49_50_modes[] = { { .ids =0x00 , .mask =PMX_TIMER_3_4_MASK ,These structures are not local, they are used in spear3**_evb.c files, and hence can't be static.
The pmx_dev structures are used by the spear3**_evb.c files, but the pmx_dev_mode structures are local. This patch is only making the latter static. I have done a build test which includes all three spear3**_evb board files and got no compilation warnings/errors.
~Ryan
PATCH 1/5 SPEAr3xx: Make local structres static
Quoted 6 lines · Ryan Mallon
Quoted 6 lines
Quoted 6 lines
-struct
pmx_dev_modepmx_plgpio_45_46_49_50_modes[] = {Quoted 4 lines
Quoted 4 lines
arch/arm/mach-spear3xx/spear3xx.c +1
-0+static struct pmx_dev_mode pmx_plgpio_45_46_49_50_modes[] = { { .ids =0x00 , .mask =PMX_TIMER_3_4_MASK ,
Quoted 6 lines
Quoted 2 lines
Quoted 2 lines
These structures are not local, they are used in spear3**_evb.c files, and hence can't be static.
The
pmx_devstructures are used by the spear3**_evb.c files, but thepmx_dev_modestructures are local. This patch is only making the latter static. I have done a build test which includes all three spear3**_evb board files and got no compilation warnings/errors.
sorry!! You were correct.
PATCH 2/5 SPEAR3xx: Rename register/irq defines to remove naming conflicts
In reply to Ryan MallonPrefix register and irq defintions to remove naming conflicts between the three SPEAr3xx platforms.
--- arch/arm/mach-spear3xx/include/mach/generic.h | 4 +- arch/arm/mach-spear3xx/include/mach/irqs.h | 195 ++++++++++++------------ arch/arm/mach-spear3xx/include/mach/spear300.h | 26 ++-- arch/arm/mach-spear3xx/include/mach/spear310.h | 44 +++--- arch/arm/mach-spear3xx/include/mach/spear320.h | 50 +++--- arch/arm/mach-spear3xx/spear300.c | 65 ++++---- arch/arm/mach-spear3xx/spear310.c | 92 ++++++------ arch/arm/mach-spear3xx/spear320.c | 134 ++++++++-------- arch/arm/mach-spear3xx/spear3xx.c | 4 +- 9 files changed, 308 insertions(+), 306 deletions(-)
arch/arm/mach-spear3xx/include/mach/generic.h +2 -2
@@ -27,8 +27,8 @@* Following GPT channels will be used as clock source and clockevent */ #define SPEAR_GPT0_BASE SPEAR3XX_ML1_TMR_BASE -#define SPEAR_GPT0_CHAN0_IRQ IRQ_CPU_GPT1_1 -#define SPEAR_GPT0_CHAN1_IRQ IRQ_CPU_GPT1_2 +#define SPEAR_GPT0_CHAN0_IRQ SPEAR3XX_IRQ_CPU_GPT1_1 +#define SPEAR_GPT0_CHAN1_IRQ SPEAR3XX_IRQ_CPU_GPT1_2/* Add spear3xx family device structure declarations here */ extern struct amba_device gpio_device;
arch/arm/mach-spear3xx/include/mach/irqs.h +99 -96
237 lines not on this page · raw message
arch/arm/mach-spear3xx/include/mach/spear300.h +13 -13
@@ -22,19 +22,19 @@/* Interrupt registers offsets and masks */ #define SPEAR300_TELECOM_REG_SIZE 0x00010000 -#define INT_ENB_MASK_REG 0x54 -#define INT_STS_MASK_REG 0x58 -#define IT_PERS_S_IRQ_MASK (1 << 0) -#define IT_CHANGE_S_IRQ_MASK (1 << 1) -#define I2S_IRQ_MASK (1 << 2) -#define TDM_IRQ_MASK (1 << 3) -#define CAMERA_L_IRQ_MASK (1 << 4) -#define CAMERA_F_IRQ_MASK (1 << 5) -#define CAMERA_V_IRQ_MASK (1 << 6) -#define KEYBOARD_IRQ_MASK (1 << 7) -#define GPIO1_IRQ_MASK (1 << 8) - -#define SHIRQ_RAS1_MASK 0x1FF +#define SPEAR300_INT_ENB_MASK_REG 0x54 +#define SPEAR300_INT_STS_MASK_REG 0x58 +#define SPEAR300_IT_PERS_S_IRQ_MASK (1 << 0) +#define SPEAR300_IT_CHANGE_S_IRQ_MASK (1 << 1) +#define SPEAR300_I2S_IRQ_MASK (1 << 2) +#define SPEAR300_TDM_IRQ_MASK (1 << 3) +#define SPEAR300_CAMERA_L_IRQ_MASK (1 << 4) +#define SPEAR300_CAMERA_F_IRQ_MASK (1 << 5) +#define SPEAR300_CAMERA_V_IRQ_MASK (1 << 6) +#define SPEAR300_KEYBOARD_IRQ_MASK (1 << 7) +#define SPEAR300_GPIO1_IRQ_MASK (1 << 8) + +#define SPEAR300_SHIRQ_RAS1_MASK 0x1FF#define SPEAR300_CLCD_BASE 0x60000000#define SPEAR300_CLCD_SIZE 0x10000000
arch/arm/mach-spear3xx/include/mach/spear310.h +22 -22
51 lines not on this page · raw message
arch/arm/mach-spear3xx/include/mach/spear320.h +25 -25
56 lines not on this page · raw message
arch/arm/mach-spear3xx/spear300.c +32 -33
91 lines not on this page · raw message
arch/arm/mach-spear3xx/spear310.c +46 -46
161 lines not on this page · raw message
arch/arm/mach-spear3xx/spear320.c +67 -67
190 lines not on this page · raw message
arch/arm/mach-spear3xx/spear3xx.c +2 -2
@@ -38,7 +38,7 @@ struct amba_device gpio_device = { .end = SPEAR3XX_ICM3_GPIO_BASE + SPEAR3XX_ICM3_GPIO_SIZE - 1, .flags = IORESOURCE_MEM, }, - .irq = {IRQ_BASIC_GPIO, NO_IRQ}, + .irq = {SPEAR3XX_IRQ_BASIC_GPIO, NO_IRQ}, };/* uart device registeration */
@@ -51,7 +51,7 @@ struct amba_device uart_device = { .end = SPEAR3XX_ICM1_UART_BASE + SPEAR3XX_ICM1_UART_SIZE - 1, .flags = IORESOURCE_MEM, }, - .irq = {IRQ_UART, NO_IRQ}, + .irq = {SPEAR3XX_IRQ_UART, NO_IRQ}, };/* Do spear3xx familiy common initialization part here */
Signature · 1 line
1.5.5
PATCH 2/5 SPEAR3xx: Rename register/irq defines to remove naming conflicts
Quoted 100 lines · Ryan Mallon
Prefix register and irq defintions to remove naming conflicts between the three SPEAr3xx platforms.
Signed-off-by Ryan Mallon <[email protected]>--- arch/arm/mach-spear3xx/include/mach/generic.h | 4 +- arch/arm/mach-spear3xx/include/mach/irqs.h | 195 ++++++++++++------------ arch/arm/mach-spear3xx/include/mach/spear300.h | 26 ++-- arch/arm/mach-spear3xx/include/mach/spear310.h | 44 +++--- arch/arm/mach-spear3xx/include/mach/spear320.h | 50 +++--- arch/arm/mach-spear3xx/spear300.c | 65 ++++---- arch/arm/mach-spear3xx/spear310.c | 92 ++++++------ arch/arm/mach-spear3xx/spear320.c | 134 ++++++++-------- arch/arm/mach-spear3xx/spear3xx.c | 4 +- 9 files changed, 308 insertions(+), 306 deletions(-)arch/arm/mach-spear3xx/include/mach/generic.h +2
-2@@ -27,8 +27,8 @@* Following GPT channels will be used as clock source and clockevent */ #define SPEAR_GPT0_BASE SPEAR3XX_ML1_TMR_BASE -#define SPEAR_GPT0_CHAN0_IRQ IRQ_CPU_GPT1_1 -#define SPEAR_GPT0_CHAN1_IRQ IRQ_CPU_GPT1_2 +#define SPEAR_GPT0_CHAN0_IRQ SPEAR3XX_IRQ_CPU_GPT1_1 +#define SPEAR_GPT0_CHAN1_IRQ SPEAR3XX_IRQ_CPU_GPT1_2/* Add spear3xx family device structure declarations here */ extern struct amba_device gpio_device;arch/arm/mach-spear3xx/include/mach/irqs.h +25
-36@@ -15,138 +15,141 @@#define __MACH_IRQS_H/* SPEAr3xx IRQ definitions */ -#define IRQ_HW_ACCEL_MOD_0 0 -#define IRQ_INTRCOMM_RAS_ARM 1 -#define IRQ_CPU_GPT1_1 2 -#define IRQ_CPU_GPT1_2 3 -#define IRQ_BASIC_GPT1_1 4 -#define IRQ_BASIC_GPT1_2 5 -#define IRQ_BASIC_GPT2_1 6 -#define IRQ_BASIC_GPT2_2 7 -#define IRQ_BASIC_DMA 8 -#define IRQ_BASIC_SMI 9 -#define IRQ_BASIC_RTC 10 -#define IRQ_BASIC_GPIO 11 -#define IRQ_BASIC_WDT 12 -#define IRQ_DDR_CONTROLLER 13 -#define IRQ_SYS_ERROR 14 -#define IRQ_WAKEUP_RCV 15 -#define IRQ_JPEG 16 -#define IRQ_IRDA 17 -#define IRQ_ADC 18 -#define IRQ_UART 19 -#define IRQ_SSP 20 -#define IRQ_I2C 21 -#define IRQ_MAC_1 22 -#define IRQ_MAC_2 23 -#define IRQ_USB_DEV 24 -#define IRQ_USB_H_OHCI_0 25 -#define IRQ_USB_H_EHCI_0 26 -#define IRQ_USB_H_EHCI_1 IRQ_USB_H_EHCI_0 -#define IRQ_USB_H_OHCI_1 27 -#define IRQ_GEN_RAS_1 28 -#define IRQ_GEN_RAS_2 29 -#define IRQ_GEN_RAS_3 30 -#define IRQ_HW_ACCEL_MOD_1 31 -#define IRQ_VIC_END 32 - -#define VIRQ_START IRQ_VIC_END +#define SPEAR3XX_IRQ_HW_ACCEL_MOD_0 0 +#define SPEAR3XX_IRQ_INTRCOMM_RAS_ARM 1 +#define SPEAR3XX_IRQ_CPU_GPT1_1 2 +#define SPEAR3XX_IRQ_CPU_GPT1_2 3 +#define SPEAR3XX_IRQ_BASIC_GPT1_1 4 +#define SPEAR3XX_IRQ_BASIC_GPT1_2 5 +#define SPEAR3XX_IRQ_BASIC_GPT2_1 6 +#define SPEAR3XX_IRQ_BASIC_GPT2_2 7 +#define SPEAR3XX_IRQ_BASIC_DMA 8 +#define SPEAR3XX_IRQ_BASIC_SMI 9 +#define SPEAR3XX_IRQ_BASIC_RTC 10 +#define SPEAR3XX_IRQ_BASIC_GPIO 11 +#define SPEAR3XX_IRQ_BASIC_WDT 12 +#define SPEAR3XX_IRQ_DDR_CONTROLLER 13 +#define SPEAR3XX_IRQ_SYS_ERROR 14 +#define SPEAR3XX_IRQ_WAKEUP_RCV 15 +#define SPEAR3XX_IRQ_JPEG 16 +#define SPEAR3XX_IRQ_IRDA 17 +#define SPEAR3XX_IRQ_ADC 18 +#define SPEAR3XX_IRQ_UART 19 +#define SPEAR3XX_IRQ_SSP 20 +#define SPEAR3XX_IRQ_I2C 21 +#define SPEAR3XX_IRQ_MAC_1 22 +#define SPEAR3XX_IRQ_MAC_2 23 +#define SPEAR3XX_IRQ_USB_DEV 24
arch/arm/mach-spear3xx/include/mach/irqs.h line 52
Quoted 10 lines
arch/arm/mach-spear3xx/include/mach/irqs.h +10
-0+#define SPEAR3XX_IRQ_USB_H_OHCI_0 25 +#define SPEAR3XX_IRQ_USB_H_EHCI_0 26 +#define SPEAR3XX_IRQ_USB_H_EHCI_1 SPEAR3XX_IRQ_USB_H_EHCI_0 +#define SPEAR3XX_IRQ_USB_H_OHCI_1 27 +#define SPEAR3XX_IRQ_GEN_RAS_1 28 +#define SPEAR3XX_IRQ_GEN_RAS_2 29 +#define SPEAR3XX_IRQ_GEN_RAS_3 30 +#define SPEAR3XX_IRQ_HW_ACCEL_MOD_1 31 +#define SPEAR3XX_IRQ_VIC_END 32 +
We have kept it, the way it was intentionally. I don't understand why any conflicts will occur.
PATCH 2/5 SPEAR3xx: Rename register/irq defines to remove naming conflicts
Quoted 30 lines · Viresh KUMAR
Quoted 29 lines · Ryan Mallon
Prefix register and irq defintions to remove naming conflicts between the three SPEAr3xx platforms.
Signed-off-by Ryan Mallon <[email protected]>--- arch/arm/mach-spear3xx/include/mach/generic.h | 4 +- arch/arm/mach-spear3xx/include/mach/irqs.h | 195 ++++++++++++------------ arch/arm/mach-spear3xx/include/mach/spear300.h | 26 ++-- arch/arm/mach-spear3xx/include/mach/spear310.h | 44 +++--- arch/arm/mach-spear3xx/include/mach/spear320.h | 50 +++--- arch/arm/mach-spear3xx/spear300.c | 65 ++++---- arch/arm/mach-spear3xx/spear310.c | 92 ++++++------ arch/arm/mach-spear3xx/spear320.c | 134 ++++++++-------- arch/arm/mach-spear3xx/spear3xx.c | 4 +- 9 files changed, 308 insertions(+), 306 deletions(-)arch/arm/mach-spear3xx/include/mach/generic.h +2
-2@@ -27,8 +27,8 @@* Following GPT channels will be used as clock source and clockevent */ #define SPEAR_GPT0_BASE SPEAR3XX_ML1_TMR_BASE -#define SPEAR_GPT0_CHAN0_IRQ IRQ_CPU_GPT1_1 -#define SPEAR_GPT0_CHAN1_IRQ IRQ_CPU_GPT1_2 +#define SPEAR_GPT0_CHAN0_IRQ SPEAR3XX_IRQ_CPU_GPT1_1 +#define SPEAR_GPT0_CHAN1_IRQ SPEAR3XX_IRQ_CPU_GPT1_2
<snip>
Quoted 3 lines
We have kept it, the way it was intentionally. I don't understand why any conflicts will occur.
The goal of the patch series is to allow all a single kernel to have support for all of the spear platforms, ie CONFIG_MACH_SPEAR300, CONFIG_MACH_SPEAR310 and CONFIG_MACH_SPEAR320 can all be set.
The current code has duplicate defines in arch/arm/mach-spear3xx/include/mach/spear3[012]0.h which means that these three files cannot be included at once (they are included from arch/arm/mach-spear3xx/include/mach/spear.h).
~Ryan
PATCH 2/5 SPEAR3xx: Rename register/irq defines to remove naming conflicts
Quoted 8 lines · Ryan Mallon
The goal of the patch series is to allow all a single kernel to have support for all of the spear platforms, ie
CONFIG_MACH_SPEAR300,CONFIG_MACH_SPEAR310andCONFIG_MACH_SPEAR320can all be set.The current code has duplicate defines in arch/arm/mach-spear3xx/include/mach/spear3[012]0.h which means that these three files cannot be included at once (they are included from
arch/arm/mach-spear3xx/include/mach/spear.h).
I understood what you did, but i am not sure how will it actually work. I tried to look into kernel source but couldn't find much.
Suppose all three machines/boards are selected and we got one kernel. Then how should we tell the kernel which machines init routine to be called. I suppose through uboot only, but not sure how it internally works.
Can you please help me understand that?
viresh.
PATCH 2/5 SPEAR3xx: Rename register/irq defines to remove naming conflicts
Quoted 10 lines · Viresh KUMAR
Quoted 8 lines · Ryan Mallon
The goal of the patch series is to allow all a single kernel to have support for all of the spear platforms, ie
CONFIG_MACH_SPEAR300,CONFIG_MACH_SPEAR310andCONFIG_MACH_SPEAR320can all be set.The current code has duplicate defines in arch/arm/mach-spear3xx/include/mach/spear3[012]0.h which means that these three files cannot be included at once (they are included from
arch/arm/mach-spear3xx/include/mach/spear.h).
Quoted 8 lines
I understood what you did, but i am not sure how will it actually work. I tried to look into kernel source but couldn't find much.
Suppose all three machines/boards are selected and we got one kernel. Then how should we tell the kernel which machines init routine to be called. I suppose through uboot only, but not sure how it internally works.
Can you please help me understand that?
The machine id is passed in register r1 by the boot loader, which matches the id in the MACHINE_START descriptors in the board files. Many of the other arm sub-architectures already allow multiple boards/implementations to be compiled into a single kernel and selected at runtime.
~Ryan
PATCH 2/5 SPEAR3xx: Rename register/irq defines to remove naming conflicts
In reply to Ryan MallonRyan,
Sorry for testing this set of patches so late. Patch is working fine. I have few comments:
Quoted 38 lines · Ryan Mallon
Prefix register and irq defintions to remove naming conflicts between the three SPEAr3xx platforms.
Signed-off-by Ryan Mallon <[email protected]>--- arch/arm/mach-spear3xx/include/mach/generic.h | 4 +- arch/arm/mach-spear3xx/include/mach/irqs.h | 195 ++++++++++++------------ arch/arm/mach-spear3xx/include/mach/spear300.h | 26 ++-- arch/arm/mach-spear3xx/include/mach/spear310.h | 44 +++--- arch/arm/mach-spear3xx/include/mach/spear320.h | 50 +++--- arch/arm/mach-spear3xx/spear300.c | 65 ++++---- arch/arm/mach-spear3xx/spear310.c | 92 ++++++------ arch/arm/mach-spear3xx/spear320.c | 134 ++++++++-------- arch/arm/mach-spear3xx/spear3xx.c | 4 +- 9 files changed, 308 insertions(+), 306 deletions(-)arch/arm/mach-spear3xx/include/mach/generic.h +2
-2@@ -27,8 +27,8 @@* Following GPT channels will be used as clock source and clockevent */ #define SPEAR_GPT0_BASE SPEAR3XX_ML1_TMR_BASE -#define SPEAR_GPT0_CHAN0_IRQ IRQ_CPU_GPT1_1 -#define SPEAR_GPT0_CHAN1_IRQ IRQ_CPU_GPT1_2 +#define SPEAR_GPT0_CHAN0_IRQ SPEAR3XX_IRQ_CPU_GPT1_1 +#define SPEAR_GPT0_CHAN1_IRQ SPEAR3XX_IRQ_CPU_GPT1_2/* Add spear3xx family device structure declarations here */ extern struct amba_device gpio_device;arch/arm/mach-spear3xx/include/mach/irqs.h +0
-0@@ -15,138 +15,141 @@#define __MACH_IRQS_H
[snip...]
arch/arm/mach-spear3xx/include/mach/irqs.h line 75
Quoted 2 lines
arch/arm/mach-spear3xx/include/mach/irqs.h +1
-1-#define SPEAR_GPIO_INT_END (SPEAR_GPIO1_INT_BASE + 8) +//#define SPEAR_GPIO_INT_END (SPEAR_GPIO1_INT_BASE + 8)
wrong comment sytle. Also we can move above definition with rest of GPIO virtual irq no.s.
Quoted 1 line
[snip...]
arch/arm/mach-spear3xx/include/mach/irqs.h line 142
Quoted 13 lines
arch/arm/mach-spear3xx/include/mach/irqs.h +11
-0+/* +* GPIO pins virtual irqs +* Use the lowest number for the GPIO virtual IRQs base on which subarchs +* we have compiled in +*/ +#if defined(CONFIG_MACH_SPEAR310 ) +#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 18) +#elif defined(CONFIG_MACH_SPEAR320 ) +#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 17) +#else +#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 9)#endif
If we have all three machines enabled, then SPEAR_GPIO_INT_BASE will start from VIRQ_START + 18, which will work for spear310 and spear320, but will not be correct as we will skip 9 irq no.s.
It would be better to have three different base addresses SPEAR300_GPIO_INT_BASE, etc.
viresh.
PATCH 2/5 SPEAR3xx: Rename register/irq defines to remove naming conflicts
Quoted 5 lines · viresh kumar
Ryan,
Sorry for testing this set of patches so late. Patch is working fine. I have few comments:
Thanks for looking at this.
Quoted 6 lines
arch/arm/mach-spear3xx/include/mach/irqs.h line 75
Quoted 3 lines
arch/arm/mach-spear3xx/include/mach/irqs.h +1
-1-#define SPEAR_GPIO_INT_END (SPEAR_GPIO1_INT_BASE + 8) +//#define SPEAR_GPIO_INT_END (SPEAR_GPIO1_INT_BASE + 8) wrong comment sytle. Also we can move above definition with rest of GPIO virtual irq no.s.
Oops, that looks like it should have been removed. Moving the definition is fine.
Quoted 5 lines
Quoted 1 line
[snip...]
Quoted 1 line
Quoted 16 lines
arch/arm/mach-spear3xx/include/mach/irqs.h line 142
Quoted 12 lines
arch/arm/mach-spear3xx/include/mach/irqs.h +11
-0+/* +* GPIO pins virtual irqs +* Use the lowest number for the GPIO virtual IRQs base on which subarchs +* we have compiled in +*/ +#if defined(CONFIG_MACH_SPEAR310 ) +#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 18) +#elif defined(CONFIG_MACH_SPEAR320 ) +#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 17) +#else +#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 9)#endif If we have all three machines enabled, then
SPEAR_GPIO_INT_BASEwill start fromVIRQ_START+ 18, which will work for spear310 and spear320, but will not be correct as we will skip 9 irq no.s.
Do the virtual irqs map directly to the hardware in some way? I thought that since they were virtual there offset would be somewhat arbitrary?
Quoted 2 lines
It would be better to have three different base addresses
SPEAR300_GPIO_INT_BASE, etc.
This is possible. We can either do this by making SPEAR3XX_GPIO_INT_BASE a variable, or by having some ifdef/machine_is code in the board initialisation.
~Ryan
Signature · 7 lines
Bluewater Systems Ltd - ARM Technology Solution Centre Ryan Mallon 5 Amuri Park, 404 Barbadoes St ryan at bluewatersys.com PO Box 13 889, Christchurch 8013 http://www.bluewatersys.com New Zealand Phone: +64 3 3779127 Freecall: Australia 1800 148 751 Fax: +64 3 3779135 USA 1800 261 2934
PATCH 2/5 SPEAR3xx: Rename register/irq defines to remove naming conflicts
Quoted 17 lines · Ryan Mallon
Quoted 17 lines
Quoted 17 lines
Quoted 13 lines
arch/arm/mach-spear3xx/include/mach/irqs.h line 142
Quoted 13 lines
arch/arm/mach-spear3xx/include/mach/irqs.h +11
-0+/* +* GPIO pins virtual irqs +* Use the lowest number for the GPIO virtual IRQs base on which subarchs +* we have compiled in +*/ +#if defined(CONFIG_MACH_SPEAR310 ) +#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 18) +#elif defined(CONFIG_MACH_SPEAR320 ) +#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 17) +#else +#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 9)#endif If we have all three machines enabled, then
SPEAR_GPIO_INT_BASEwill start fromVIRQ_START+ 18, which will work for spear310 and spear320, but will not be correct as we will skip 9 irq no.s.
Quoted 2 lines
Do the virtual irqs map directly to the hardware in some way? I thought that since they were virtual there offset would be somewhat arbitrary?
No. Virtual irqs are not fixed with hardware. What i wanted to say is NR_IRQS will have a higher value, which will make irq_desc[NR_IRQS] array have more size.
Quoted 6 lines
Quoted 3 lines
Quoted 3 lines
It would be better to have three different base addresses
SPEAR300_GPIO_INT_BASE, etc.This is possible. We can either do this by making
SPEAR3XX_GPIO_INT_BASEa variable, or by having some ifdef/machine_is code in the board initialisation.
Not sure! We need to have single value of NR_IRQS for all spear3xx variants. This will always waste some memory. I don't know if any other solution can be there.
So SPEAR_GPIO_INT_BASE can be kept common with a single value without these #ifdefs, i.e. we can have
#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 18)
and now we can have different macros per machine, i.e. 300,310,320.
viresh.
PATCH 2/5 SPEAR3xx: Rename register/irq defines to remove naming conflicts
Quoted 18 lines · viresh kumar
Quoted 17 lines · Ryan Mallon
Quoted 17 lines
Quoted 17 lines
Quoted 13 lines
arch/arm/mach-spear3xx/include/mach/irqs.h line 142
Quoted 13 lines
arch/arm/mach-spear3xx/include/mach/irqs.h +11
-0+/* +* GPIO pins virtual irqs +* Use the lowest number for the GPIO virtual IRQs base on which subarchs +* we have compiled in +*/ +#if defined(CONFIG_MACH_SPEAR310 ) +#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 18) +#elif defined(CONFIG_MACH_SPEAR320 ) +#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 17) +#else +#define SPEAR_GPIO_INT_BASE (SPEAR3XX_VIRQ_START + 9)#endif If we have all three machines enabled, then
SPEAR_GPIO_INT_BASEwill start fromVIRQ_START+ 18, which will work for spear310 and spear320, but will not be correct as we will skip 9 irq no.s.
Quoted 6 lines
Quoted 2 lines
Do the virtual irqs map directly to the hardware in some way? I thought that since they were virtual there offset would be somewhat arbitrary?
No. Virtual irqs are not fixed with hardware. What i wanted to say is
NR_IRQSwill have a higher value, which will make irq_desc[NR_IRQS] array have more size.
Right, but the ifdef code about will make sure that if you only compile in a single Spear implementation then the VIRQ start will be optimal. If you compile multiple Spear implementations in then you get the benefit of a single kernel which boots on multiple boards, at the cost of some minimal memory wastage in some cases.
~Ryan
Quoted 18 lines
Quoted 6 lines
Quoted 3 lines
Quoted 3 lines
It would be better to have three different base addresses
SPEAR300_GPIO_INT_BASE, etc.This is possible. We can either do this by making
SPEAR3XX_GPIO_INT_BASEa variable, or by having some ifdef/machine_is code in the board initialisation.Not sure! We need to have single value of
NR_IRQSfor all spear3xx variants. This will always waste some memory. I don't know if any other solution can be there.So
SPEAR_GPIO_INT_BASEcan be kept common with a single value without these #ifdefs, i.e. we can have
#defineSPEAR_GPIO_INT_BASE(SPEAR3XX_VIRQ_START+ 18)and now we can have different macros per machine, i.e. 300,310,320.
viresh.
Signature · 7 lines
Bluewater Systems Ltd - ARM Technology Solution Centre Ryan Mallon 5 Amuri Park, 404 Barbadoes St ryan at bluewatersys.com PO Box 13 889, Christchurch 8013 http://www.bluewatersys.com New Zealand Phone: +64 3 3779127 Freecall: Australia 1800 148 751 Fax: +64 3 3779135 USA 1800 261 2934
PATCH 2/5 SPEAR3xx: Rename register/irq defines to remove naming conflicts
Quoted 6 lines · Ryan Mallon
Right, but the ifdef code about will make sure that if you only compile in a single Spear implementation then the VIRQ start will be optimal. If you compile multiple Spear implementations in then you get the benefit of a single kernel which boots on multiple boards, at the cost of some minimal memory wastage in some cases.
OK. This is fine. Just remove "//" comment from V2 and i will ack it.
Thanks
viresh.
PATCH 3/5 SPEAr3xx: Rework pmx_dev code to remove conflicts
In reply to Ryan MallonPrefix the pmx_devs to remove naming conflicts between the three SPEAr3xx platforms. Also make pmx_driver static to each platform and rework the init code to pass the devices rather than export the pmx_driver structure.
--- arch/arm/mach-spear3xx/include/mach/generic.h | 135 ++++++++++++------------- arch/arm/mach-spear3xx/spear300.c | 39 ++++---- arch/arm/mach-spear3xx/spear300_evb.c | 26 ++--- arch/arm/mach-spear3xx/spear310.c | 29 +++--- arch/arm/mach-spear3xx/spear310_evb.c | 42 ++++----- arch/arm/mach-spear3xx/spear320.c | 57 ++++++----- arch/arm/mach-spear3xx/spear320_evb.c | 36 +++---- arch/arm/mach-spear3xx/spear3xx.c | 60 ++++++------ 8 files changed, 202 insertions(+), 222 deletions(-)
arch/arm/mach-spear3xx/include/mach/generic.h +65 -70
@@ -60,21 +60,21 @@ void spear_pmx_init(struct pmx_driver *pmx_driver, uint base, uint size);#define PMX_TIMER_1_2_MASK (1 << 0)/* pad mux devices */ -extern struct pmx_dev pmx_firda; -extern struct pmx_dev pmx_i2c; -extern struct pmx_dev pmx_ssp_cs; -extern struct pmx_dev pmx_ssp; -extern struct pmx_dev pmx_mii; -extern struct pmx_dev pmx_gpio_pin0; -extern struct pmx_dev pmx_gpio_pin1; -extern struct pmx_dev pmx_gpio_pin2; -extern struct pmx_dev pmx_gpio_pin3; -extern struct pmx_dev pmx_gpio_pin4; -extern struct pmx_dev pmx_gpio_pin5; -extern struct pmx_dev pmx_uart0_modem; -extern struct pmx_dev pmx_uart0; -extern struct pmx_dev pmx_timer_3_4; -extern struct pmx_dev pmx_timer_1_2; +extern struct pmx_dev spear3xx_pmx_firda; +extern struct pmx_dev spear3xx_pmx_i2c; +extern struct pmx_dev spear3xx_pmx_ssp_cs; +extern struct pmx_dev spear3xx_pmx_ssp; +extern struct pmx_dev spear3xx_pmx_mii; +extern struct pmx_dev spear3xx_pmx_gpio_pin0; +extern struct pmx_dev spear3xx_pmx_gpio_pin1; +extern struct pmx_dev spear3xx_pmx_gpio_pin2; +extern struct pmx_dev spear3xx_pmx_gpio_pin3; +extern struct pmx_dev spear3xx_pmx_gpio_pin4; +extern struct pmx_dev spear3xx_pmx_gpio_pin5; +extern struct pmx_dev spear3xx_pmx_uart0_modem; +extern struct pmx_dev spear3xx_pmx_uart0; +extern struct pmx_dev spear3xx_pmx_timer_3_4; +extern struct pmx_dev spear3xx_pmx_timer_1_2;#if defined(CONFIG_MACH_SPEAR310 ) || defined(CONFIG_MACH_SPEAR320 )/* padmux plgpio devices */
@@ -95,8 +95,6 @@ extern struct pmx_dev pmx_plgpio_43_44_47_48;extern struct pmx_dev pmx_plgpio_45_46_49_50;#endif -extern struct pmx_driver pmx_driver; -/* spear300 declarations */ #ifdef CONFIG_MACH_SPEAR300 /* Add spear300 machine device structure declarations here */
@@ -118,25 +116,24 @@ extern struct pmx_mode camu_wlcd_mode;extern struct pmx_mode caml_lcd_mode;/* pad mux devices */ -extern struct pmx_dev pmx_fsmc_2_chips; -extern struct pmx_dev pmx_fsmc_4_chips; -extern struct pmx_dev pmx_keyboard; -extern struct pmx_dev pmx_clcd; -extern struct pmx_dev pmx_telecom_gpio; -extern struct pmx_dev pmx_telecom_tdm; -extern struct pmx_dev pmx_telecom_spi_cs_i2c_clk; -extern struct pmx_dev pmx_telecom_camera; -extern struct pmx_dev pmx_telecom_dac; -extern struct pmx_dev pmx_telecom_i2s; -extern struct pmx_dev pmx_telecom_boot_pins; -extern struct pmx_dev pmx_telecom_sdio_4bit; -extern struct pmx_dev pmx_telecom_sdio_8bit; -extern struct pmx_dev pmx_gpio1; - -void spear300_pmx_init (void ); +extern struct pmx_dev spear300_pmx_fsmc_2_chips; +extern struct pmx_dev spear300_pmx_fsmc_4_chips; +extern struct pmx_dev spear300_pmx_keyboard; +extern struct pmx_dev spear300_pmx_clcd; +extern struct pmx_dev spear300_pmx_telecom_gpio; +extern struct pmx_dev spear300_pmx_telecom_tdm; +extern struct pmx_dev spear300_pmx_telecom_spi_cs_i2c_clk; +extern struct pmx_dev spear300_pmx_telecom_camera; +extern struct pmx_dev spear300_pmx_telecom_dac; +extern struct pmx_dev spear300_pmx_telecom_i2s; +extern struct pmx_dev spear300_pmx_telecom_boot_pins; +extern struct pmx_dev spear300_pmx_telecom_sdio_4bit; +extern struct pmx_dev spear300_pmx_telecom_sdio_8bit; +extern struct pmx_dev spear300_pmx_gpio1;/* Add spear300 machine function declarations here */ -void __init spear300_init (void ); +void __init spear300_init (struct pmx_mode *pmx_mode,struct pmx_dev **pxm_devs, +u8 pmx_dev_count);#endif /* CONFIG_MACH_SPEAR300 */
@@ -145,19 +142,18 @@ void __init spear300_init(void);/* Add spear310 machine device structure declarations here */ /* pad mux devices */ -extern struct pmx_dev pmx_emi_cs_0_1_4_5; -extern struct pmx_dev pmx_emi_cs_2_3; -extern struct pmx_dev pmx_uart1; -extern struct pmx_dev pmx_uart2; -extern struct pmx_dev pmx_uart3_4_5; -extern struct pmx_dev pmx_fsmc; -extern struct pmx_dev pmx_rs485_0_1; -extern struct pmx_dev pmx_tdm0; - -void spear310_pmx_init (void ); +extern struct pmx_dev spear310_pmx_emi_cs_0_1_4_5; +extern struct pmx_dev spear310_pmx_emi_cs_2_3; +extern struct pmx_dev spear310_pmx_uart1; +extern struct pmx_dev spear310_pmx_uart2; +extern struct pmx_dev spear310_pmx_uart3_4_5; +extern struct pmx_dev spear310_pmx_fsmc; +extern struct pmx_dev spear310_pmx_rs485_0_1; +extern struct pmx_dev spear310_pmx_tdm0;/* Add spear310 machine function declarations here */ -void __init spear310_init (void ); +void __init spear310_init (struct pmx_mode *pmx_mode,struct pmx_dev **pxm_devs, +u8 pmx_dev_count);#endif /* CONFIG_MACH_SPEAR310 */
@@ -172,33 +168,32 @@ extern struct pmx_mode auto_exp_mode;extern struct pmx_mode small_printers_mode;/* pad mux devices */ -extern struct pmx_dev pmx_clcd; -extern struct pmx_dev pmx_emi; -extern struct pmx_dev pmx_fsmc; -extern struct pmx_dev pmx_spp; -extern struct pmx_dev pmx_sdio; -extern struct pmx_dev pmx_i2s; -extern struct pmx_dev pmx_uart1; -extern struct pmx_dev pmx_uart1_modem; -extern struct pmx_dev pmx_uart2; -extern struct pmx_dev pmx_touchscreen; -extern struct pmx_dev pmx_can; -extern struct pmx_dev pmx_sdio_led; -extern struct pmx_dev pmx_pwm0; -extern struct pmx_dev pmx_pwm1; -extern struct pmx_dev pmx_pwm2; -extern struct pmx_dev pmx_pwm3; -extern struct pmx_dev pmx_ssp1; -extern struct pmx_dev pmx_ssp2; -extern struct pmx_dev pmx_mii1; -extern struct pmx_dev pmx_smii0; -extern struct pmx_dev pmx_smii1; -extern struct pmx_dev pmx_i2c1; - -void spear320_pmx_init (void ); +extern struct pmx_dev spear320_pmx_clcd; +extern struct pmx_dev spear320_pmx_emi; +extern struct pmx_dev spear320_pmx_fsmc; +extern struct pmx_dev spear320_pmx_spp; +extern struct pmx_dev spear320_pmx_sdio; +extern struct pmx_dev spear320_pmx_i2s; +extern struct pmx_dev spear320_pmx_uart1; +extern struct pmx_dev spear320_pmx_uart1_modem; +extern struct pmx_dev spear320_pmx_uart2; +extern struct pmx_dev spear320_pmx_touchscreen; +extern struct pmx_dev spear320_pmx_can; +extern struct pmx_dev spear320_pmx_sdio_led; +extern struct pmx_dev spear320_pmx_pwm0; +extern struct pmx_dev spear320_pmx_pwm1; +extern struct pmx_dev spear320_pmx_pwm2; +extern struct pmx_dev spear320_pmx_pwm3; +extern struct pmx_dev spear320_pmx_ssp1; +extern struct pmx_dev spear320_pmx_ssp2; +extern struct pmx_dev spear320_pmx_mii1; +extern struct pmx_dev spear320_pmx_smii0; +extern struct pmx_dev spear320_pmx_smii1; +extern struct pmx_dev spear320_pmx_i2c1;/* Add spear320 machine function declarations here */ -void __init spear320_init (void ); +void __init spear320_init (struct pmx_mode *pmx_mode,struct pmx_dev **pxm_devs, +u8 pmx_dev_count);#endif /* CONFIG_MACH_SPEAR320 */
arch/arm/mach-spear3xx/spear300.c +20 -19
@@ -127,7 +127,7 @@ static struct pmx_dev_mode pmx_fsmc_2_chips_modes[] = { }, }; -struct pmx_dev pmx_fsmc_2_chips = { +struct pmx_dev spear300_pmx_fsmc_2_chips = { .name ="fsmc_2_chips" , .modes = pmx_fsmc_2_chips_modes, .mode_count =ARRAY_SIZE (pmx_fsmc_2_chips_modes),
@@ -142,7 +142,7 @@ static struct pmx_dev_mode pmx_fsmc_4_chips_modes[] = { }, }; -struct pmx_dev pmx_fsmc_4_chips = { +struct pmx_dev spear300_pmx_fsmc_4_chips = { .name ="fsmc_4_chips" , .modes = pmx_fsmc_4_chips_modes, .mode_count =ARRAY_SIZE (pmx_fsmc_4_chips_modes),
@@ -159,7 +159,7 @@ static struct pmx_dev_mode pmx_keyboard_modes[] = { }, }; -struct pmx_dev pmx_keyboard = { +struct pmx_dev spear300_pmx_keyboard = { .name ="keyboard" , .modes = pmx_keyboard_modes, .mode_count =ARRAY_SIZE (pmx_keyboard_modes),
@@ -177,7 +177,7 @@ static struct pmx_dev_mode pmx_clcd_modes[] = { }, }; -struct pmx_dev pmx_clcd = { +struct pmx_dev spear300_pmx_clcd = { .name ="clcd" , .modes = pmx_clcd_modes, .mode_count =ARRAY_SIZE (pmx_clcd_modes),
@@ -222,7 +222,7 @@ static struct pmx_dev_mode pmx_telecom_tdm_modes[] = { }, }; -struct pmx_dev pmx_telecom_tdm = { +struct pmx_dev spear300_pmx_telecom_tdm = { .name ="telecom_tdm" , .modes = pmx_telecom_tdm_modes, .mode_count =ARRAY_SIZE (pmx_telecom_tdm_modes),
@@ -239,7 +239,7 @@ static struct pmx_dev_mode pmx_telecom_spi_cs_i2c_clk_modes[] = { }, }; -struct pmx_dev pmx_telecom_spi_cs_i2c_clk = { +struct pmx_dev spear300_pmx_telecom_spi_cs_i2c_clk = { .name ="telecom_spi_cs_i2c_clk" , .modes = pmx_telecom_spi_cs_i2c_clk_modes, .mode_count =ARRAY_SIZE (pmx_telecom_spi_cs_i2c_clk_modes),
@@ -256,7 +256,7 @@ static struct pmx_dev_mode pmx_telecom_camera_modes[] = { }, }; -struct pmx_dev pmx_telecom_camera = { +struct pmx_dev spear300_pmx_telecom_camera = { .name ="telecom_camera" , .modes = pmx_telecom_camera_modes, .mode_count =ARRAY_SIZE (pmx_telecom_camera_modes),
@@ -271,7 +271,7 @@ static struct pmx_dev_mode pmx_telecom_dac_modes[] = { }, }; -struct pmx_dev pmx_telecom_dac = { +struct pmx_dev spear300_pmx_telecom_dac = { .name ="telecom_dac" , .modes = pmx_telecom_dac_modes, .mode_count =ARRAY_SIZE (pmx_telecom_dac_modes),
@@ -288,7 +288,7 @@ static struct pmx_dev_mode pmx_telecom_i2s_modes[] = { }, }; -struct pmx_dev pmx_telecom_i2s = { +struct pmx_dev spear300_pmx_telecom_i2s = { .name ="telecom_i2s" , .modes = pmx_telecom_i2s_modes, .mode_count =ARRAY_SIZE (pmx_telecom_i2s_modes),
@@ -303,7 +303,7 @@ static struct pmx_dev_mode pmx_telecom_boot_pins_modes[] = { }, }; -struct pmx_dev pmx_telecom_boot_pins = { +struct pmx_dev spear300_pmx_telecom_boot_pins = { .name ="telecom_boot_pins" , .modes = pmx_telecom_boot_pins_modes, .mode_count =ARRAY_SIZE (pmx_telecom_boot_pins_modes),
@@ -323,7 +323,7 @@ static struct pmx_dev_mode pmx_telecom_sdio_4bit_modes[] = { }, }; -struct pmx_dev pmx_telecom_sdio_4bit = { +struct pmx_dev spear300_pmx_telecom_sdio_4bit = { .name ="telecom_sdio_4bit" , .modes = pmx_telecom_sdio_4bit_modes, .mode_count =ARRAY_SIZE (pmx_telecom_sdio_4bit_modes),
@@ -342,7 +342,7 @@ static struct pmx_dev_mode pmx_telecom_sdio_8bit_modes[] = { }, }; -struct pmx_dev pmx_telecom_sdio_8bit = { +struct pmx_dev spear300_pmx_telecom_sdio_8bit = { .name ="telecom_sdio_8bit" , .modes = pmx_telecom_sdio_8bit_modes, .mode_count =ARRAY_SIZE (pmx_telecom_sdio_8bit_modes),
@@ -357,7 +357,7 @@ static struct pmx_dev_mode pmx_gpio1_modes[] = { }, }; -struct pmx_dev pmx_gpio1 = { +struct pmx_dev spear300_pmx_gpio1 = { .name ="arm gpio1" , .modes = pmx_gpio1_modes, .mode_count =ARRAY_SIZE (pmx_gpio1_modes),
@@ -365,7 +365,7 @@ struct pmx_dev pmx_gpio1 = { };/* pmx driver structure */ -struct pmx_driver pmx_driver = { +static struct pmx_driver pmx_driver = { .mode_reg = {.offset =MODE_CONFIG_REG , .mask =0x0000000f }, .mux_reg = {.offset =PAD_MUX_CONFIG_REG , .mask =0x00007fff }, };
@@ -444,7 +444,8 @@ static struct spear_shirq shirq_ras1 = { };/* spear300 routines */ -void __init spear300_init (void ) +void __init spear300_init (struct pmx_mode *pmx_mode,struct pmx_dev **pmx_devs, +u8 pmx_dev_count) {int ret =0 ;
@@ -459,10 +460,10 @@ void __init spear300_init(void)if (ret)printk (KERN_ERR "Error registering Shared IRQ\n" ); } -} -void spear300_pmx_init (void ) -{ + pmx_driver.mode = pmx_mode; + pmx_driver.devs = pmx_devs; + pmx_driver.devs_count = pmx_dev_count;spear_pmx_init (&pmx_driver,SPEAR300_SOC_CONFIG_BASE , -SPEAR300_SOC_CONFIG_SIZE ); +SPEAR300_SOC_CONFIG_SIZE ); }
arch/arm/mach-spear3xx/spear300_evb.c +10 -16
@@ -19,17 +19,17 @@/* padmux devices to enable */ static struct pmx_dev *pmx_devs[] = {/* spear3xx specific devices */ - &pmx_i2c, - &pmx_ssp_cs, - &pmx_ssp, - &pmx_mii, - &pmx_uart0, + &spear3xx_pmx_i2c, + &spear3xx_pmx_ssp_cs, + &spear3xx_pmx_ssp, + &spear3xx_pmx_mii, + &spear3xx_pmx_uart0,/* spear300 specific devices */ - &pmx_fsmc_2_chips, - &pmx_clcd, - &pmx_telecom_sdio_4bit, - &pmx_gpio1, + &spear300_pmx_fsmc_2_chips, + &spear300_pmx_clcd, + &spear300_pmx_telecom_sdio_4bit, + &spear300_pmx_gpio1, };static struct amba_device *amba_devs[]__initdata = {
@@ -52,13 +52,7 @@ static void __init spear300_evb_init(void)unsigned int i;/* call spear300 machine init function */ -spear300_init (); - -/* padmux initialization */ - pmx_driver.mode = &photo_frame_mode; - pmx_driver.devs = pmx_devs; - pmx_driver.devs_count =ARRAY_SIZE (pmx_devs); -spear300_pmx_init (); +spear300_init (&photo_frame_mode, pmx_devs,ARRAY_SIZE (pmx_devs));/* Add Platform Devices */ platform_add_devices (plat_devs,ARRAY_SIZE (plat_devs));
arch/arm/mach-spear3xx/spear310.c +15 -14
@@ -29,7 +29,7 @@ struct pmx_dev_mode pmx_emi_cs_0_1_4_5_modes[] = { }, }; -struct pmx_dev pmx_emi_cs_0_1_4_5 = { +struct pmx_dev spear310_pmx_emi_cs_0_1_4_5 = { .name ="emi_cs_0_1_4_5" , .modes = pmx_emi_cs_0_1_4_5_modes, .mode_count =ARRAY_SIZE (pmx_emi_cs_0_1_4_5_modes),
@@ -43,7 +43,7 @@ struct pmx_dev_mode pmx_emi_cs_2_3_modes[] = { }, }; -struct pmx_dev pmx_emi_cs_2_3 = { +struct pmx_dev spear310_pmx_emi_cs_2_3 = { .name ="emi_cs_2_3" , .modes = pmx_emi_cs_2_3_modes, .mode_count =ARRAY_SIZE (pmx_emi_cs_2_3_modes),
@@ -57,7 +57,7 @@ struct pmx_dev_mode pmx_uart1_modes[] = { }, }; -struct pmx_dev pmx_uart1 = { +struct pmx_dev spear310_pmx_uart1 = { .name ="uart1" , .modes = pmx_uart1_modes, .mode_count =ARRAY_SIZE (pmx_uart1_modes),
@@ -71,7 +71,7 @@ struct pmx_dev_mode pmx_uart2_modes[] = { }, }; -struct pmx_dev pmx_uart2 = { +struct pmx_dev spear310_pmx_uart2 = { .name ="uart2" , .modes = pmx_uart2_modes, .mode_count =ARRAY_SIZE (pmx_uart2_modes),
@@ -85,7 +85,7 @@ struct pmx_dev_mode pmx_uart3_4_5_modes[] = { }, }; -struct pmx_dev pmx_uart3_4_5 = { +struct pmx_dev spear310_pmx_uart3_4_5 = { .name ="uart3_4_5" , .modes = pmx_uart3_4_5_modes, .mode_count =ARRAY_SIZE (pmx_uart3_4_5_modes),
@@ -99,7 +99,7 @@ struct pmx_dev_mode pmx_fsmc_modes[] = { }, }; -struct pmx_dev pmx_fsmc = { +struct pmx_dev spear310_pmx_fsmc = { .name ="fsmc" , .modes = pmx_fsmc_modes, .mode_count =ARRAY_SIZE (pmx_fsmc_modes),
@@ -113,7 +113,7 @@ struct pmx_dev_mode pmx_rs485_0_1_modes[] = { }, }; -struct pmx_dev pmx_rs485_0_1 = { +struct pmx_dev spear310_pmx_rs485_0_1 = { .name ="rs485_0_1" , .modes = pmx_rs485_0_1_modes, .mode_count =ARRAY_SIZE (pmx_rs485_0_1_modes),
@@ -127,7 +127,7 @@ struct pmx_dev_mode pmx_tdm0_modes[] = { }, }; -struct pmx_dev pmx_tdm0 = { +struct pmx_dev spear310_pmx_tdm0 = { .name ="tdm0" , .modes = pmx_tdm0_modes, .mode_count =ARRAY_SIZE (pmx_tdm0_modes),
@@ -135,7 +135,7 @@ struct pmx_dev pmx_tdm0 = { };/* pmx driver structure */ -struct pmx_driver pmx_driver = { +static struct pmx_driver pmx_driver = { .mux_reg = {.offset =PAD_MUX_CONFIG_REG , .mask =0x00007fff }, };
@@ -258,7 +258,8 @@ static struct spear_shirq shirq_intrcomm_ras = { };/* spear310 routines */ -void __init spear310_init (void ) +void __init spear310_init (struct pmx_mode *pmx_mode,struct pmx_dev **pmx_devs, +u8 pmx_dev_count) {void __iomem *base;int ret =0 ;
@@ -293,10 +294,10 @@ void __init spear310_init(void)if (ret)printk (KERN_ERR "Error registering Shared IRQ 4\n" ); } -} -void spear310_pmx_init (void ) -{ + pmx_driver.mode = pmx_mode; + pmx_driver.devs = pmx_devs; + pmx_driver.devs_count = pmx_dev_count;spear_pmx_init (&pmx_driver,SPEAR310_SOC_CONFIG_BASE , -SPEAR310_SOC_CONFIG_SIZE ); +SPEAR310_SOC_CONFIG_SIZE ); }
arch/arm/mach-spear3xx/spear310_evb.c +18 -24
56 lines not on this page · raw message
arch/arm/mach-spear3xx/spear320.c +29 -28
207 lines not on this page · raw message
arch/arm/mach-spear3xx/spear320_evb.c +15 -21
@@ -19,22 +19,22 @@/* padmux devices to enable */ static struct pmx_dev *pmx_devs[] = {/* spear3xx specific devices */ - &pmx_i2c, - &pmx_ssp, - &pmx_mii, - &pmx_uart0, + &spear3xx_pmx_i2c, + &spear3xx_pmx_ssp, + &spear3xx_pmx_mii, + &spear3xx_pmx_uart0,/* spear320 specific devices */ - &pmx_fsmc, - &pmx_sdio, - &pmx_i2s, - &pmx_uart1, - &pmx_uart2, - &pmx_can, - &pmx_pwm0, - &pmx_pwm1, - &pmx_pwm2, - &pmx_mii1, + &spear320_pmx_fsmc, + &spear320_pmx_sdio, + &spear320_pmx_i2s, + &spear320_pmx_uart1, + &spear320_pmx_uart2, + &spear320_pmx_can, + &spear320_pmx_pwm0, + &spear320_pmx_pwm1, + &spear320_pmx_pwm2, + &spear320_pmx_mii1, };static struct amba_device *amba_devs[]__initdata = {
@@ -56,13 +56,7 @@ static void __init spear320_evb_init(void)unsigned int i;/* call spear320 machine init function */ -spear320_init (); - -/* padmux initialization */ - pmx_driver.mode = &auto_net_mii_mode; - pmx_driver.devs = pmx_devs; - pmx_driver.devs_count =ARRAY_SIZE (pmx_devs); -spear320_pmx_init (); +spear320_init (&auto_net_mii_mode, pmx_devs,ARRAY_SIZE (pmx_devs));/* Add Platform Devices */ platform_add_devices (plat_devs,ARRAY_SIZE (plat_devs));
arch/arm/mach-spear3xx/spear3xx.c +30 -30
240 lines not on this page · raw message
Signature · 1 line
1.5.5
PATCH 3/5 SPEAr3xx: Rework pmx_dev code to remove conflicts
Quoted 46 lines · Ryan Mallon
Prefix the
pmx_devsto remove naming conflicts between the three SPEAr3xx platforms. Also makepmx_driverstatic to each platform and rework the init code to pass the devices rather than export thepmx_driverstructure.Signed-off-by Ryan Mallon <[email protected]>--- arch/arm/mach-spear3xx/include/mach/generic.h | 135 ++++++++++++------------- arch/arm/mach-spear3xx/spear300.c | 39 ++++---- arch/arm/mach-spear3xx/spear300_evb.c | 26 ++--- arch/arm/mach-spear3xx/spear310.c | 29 +++--- arch/arm/mach-spear3xx/spear310_evb.c | 42 ++++----- arch/arm/mach-spear3xx/spear320.c | 57 ++++++----- arch/arm/mach-spear3xx/spear320_evb.c | 36 +++---- arch/arm/mach-spear3xx/spear3xx.c | 60 ++++++------ 8 files changed, 202 insertions(+), 222 deletions(-)arch/arm/mach-spear3xx/include/mach/generic.h +6
-15@@ -60,21 +60,21 @@ void spear_pmx_init(struct pmx_driver *pmx_driver, uint base, uint size);#define PMX_TIMER_1_2_MASK (1 << 0)/* pad mux devices */ -extern struct pmx_dev pmx_firda; -extern struct pmx_dev pmx_i2c; -extern struct pmx_dev pmx_ssp_cs; -extern struct pmx_dev pmx_ssp; -extern struct pmx_dev pmx_mii; -extern struct pmx_dev pmx_gpio_pin0; -extern struct pmx_dev pmx_gpio_pin1; -extern struct pmx_dev pmx_gpio_pin2; -extern struct pmx_dev pmx_gpio_pin3; -extern struct pmx_dev pmx_gpio_pin4; -extern struct pmx_dev pmx_gpio_pin5; -extern struct pmx_dev pmx_uart0_modem; -extern struct pmx_dev pmx_uart0; -extern struct pmx_dev pmx_timer_3_4; -extern struct pmx_dev pmx_timer_1_2; +extern struct pmx_dev spear3xx_pmx_firda; +extern struct pmx_dev spear3xx_pmx_i2c; +extern struct pmx_dev spear3xx_pmx_ssp_cs; +extern struct pmx_dev spear3xx_pmx_ssp; +extern struct pmx_dev spear3xx_pmx_mii; +extern struct pmx_dev spear3xx_pmx_gpio_pin0;
arch/arm/mach-spear3xx/include/mach/generic.h void spear_pmx_init(struct pmx_driver *pmx_driver, uint base, uint size); · line 78
Quoted 10 lines
arch/arm/mach-spear3xx/include/mach/generic.h +9
-0+extern struct pmx_dev spear3xx_pmx_gpio_pin1; +extern struct pmx_dev spear3xx_pmx_gpio_pin2; +extern struct pmx_dev spear3xx_pmx_gpio_pin3; +extern struct pmx_dev spear3xx_pmx_gpio_pin4; +extern struct pmx_dev spear3xx_pmx_gpio_pin5; +extern struct pmx_dev spear3xx_pmx_uart0_modem; +extern struct pmx_dev spear3xx_pmx_uart0; +extern struct pmx_dev spear3xx_pmx_timer_3_4; +extern struct pmx_dev spear3xx_pmx_timer_1_2;
same here. I don't understand why any conflicts will be there.
[snip...]
Quoted 22 lines
arch/arm/mach-spear3xx/include/mach/generic.h +1
-1/* pmx driver structure */ -struct pmx_driver pmx_driver = { +static struct pmx_driver pmx_driver = {arch/arm/mach-spear3xx/include/mach/generic.h +2
-2.mode_reg = {.offset = MODE_CONFIG_REG, .mask = 0x00000007}, .mux_reg = {.offset = PAD_MUX_CONFIG_REG, .mask = 0x00007fff}, };@@ -511,7 +511,8 @@ static struct spear_shirq shirq_intrcomm_ras = { };/* spear320 routines */ -void __init spear320_init (void ) +void __init spear320_init (struct pmx_mode *pmx_mode,struct pmx_dev **pmx_devs, +u8 pmx_dev_count) {void __iomem *base;int ret =0 ;@@ -540,10 +541,10 @@ void __init spear320_init(void)if (ret)printk (KERN_ERR "Error registering Shared IRQ 4\n" ); } -}
arch/arm/mach-spear3xx/include/mach/generic.h void __init spear320_init(void) · line 550
Quoted 10 lines
arch/arm/mach-spear3xx/include/mach/generic.h +4
-3-void spear320_pmx_init (void ) -{ + pmx_driver.mode = pmx_mode; + pmx_driver.devs = pmx_devs; + pmx_driver.devs_count = pmx_dev_count;spear_pmx_init (&pmx_driver,SPEAR320_SOC_CONFIG_BASE , -SPEAR320_SOC_CONFIG_SIZE ); +SPEAR320_SOC_CONFIG_SIZE ); }
This part looks fine.
Quoted 9 lines
arch/arm/mach-spear3xx/spear320_evb.c +0
-0@@ -19,22 +19,22 @@static struct amba_device *amba_devs[]__initdata = {@@ -56,13 +56,7 @@ static void __init spear320_evb_init(void)unsigned int i;
arch/arm/mach-spear3xx/spear320_evb.c static void __init spear320_evb_init(void) · line 59
Quoted 10 lines
arch/arm/mach-spear3xx/spear320_evb.c +1
-7/* call spear320 machine init function */ -spear320_init (); - -/* padmux initialization */ - pmx_driver.mode = &auto_net_mii_mode; - pmx_driver.devs = pmx_devs; - pmx_driver.devs_count =ARRAY_SIZE (pmx_devs); -spear320_pmx_init (); +spear320_init (&auto_net_mii_mode, pmx_devs,ARRAY_SIZE (pmx_devs));
this is also fine.
PATCH 4/5 SPEAr3xx: Rework KConfig to allow all boards to be compiled in
In reply to Ryan MallonNow that all three SPEAr3xx platforms can be built into one kernel, rework KConfig to allow this. Move everything into one KConfig file while we are here.
--- arch/arm/mach-spear3xx/Kconfig | 30 ++++++++++++++++++++---------- arch/arm/mach-spear3xx/Kconfig300 | 17 ----------------- arch/arm/mach-spear3xx/Kconfig310 | 17 ----------------- arch/arm/mach-spear3xx/Kconfig320 | 17 ----------------- 4 files changed, 20 insertions(+), 61 deletions(-) delete mode 100644 arch/arm/mach-spear3xx/Kconfig300 delete mode 100644 arch/arm/mach-spear3xx/Kconfig310 delete mode 100644 arch/arm/mach-spear3xx/Kconfig320
arch/arm/mach-spear3xx/Kconfig +20 -10
@@ -4,9 +4,26 @@ if ARCH_SPEAR3XX -choice - prompt "SPEAr3XX Family" - default MACH_SPEAR300 +menu "SPEAr3xx Implementations" +config BOARD_SPEAR300_EVB + bool "SPEAr300 Evaluation Board" + select MACH_SPEAR300 + help + Supports ST SPEAr300 Evaluation Board + +config BOARD_SPEAR310_EVB + bool "SPEAr310 Evaluation Board" + select MACH_SPEAR310 + help + Supports ST SPEAr310 Evaluation Board + +config BOARD_SPEAR320_EVB + bool "SPEAr320 Evaluation Board" + select MACH_SPEAR320 + help + Supports ST SPEAr320 Evaluation Board + +endmenu config MACH_SPEAR300 bool "SPEAr300"
@@ -23,11 +40,4 @@ config MACH_SPEAR320 help Supports ST SPEAr320 Machine -endchoice - -# Adding SPEAr3XX machine specific configuration files -source "arch/arm/mach-spear3xx/Kconfig300" -source "arch/arm/mach-spear3xx/Kconfig310" -source "arch/arm/mach-spear3xx/Kconfig320" - endif #ARCH_SPEAR3XX
arch/arm/mach-spear3xx/Kconfig300 deleted +0 -17
@@ -1,17 +0,0 @@ -# -# SPEAr300 machine configuration file -# - -if MACH_SPEAR300 - -choice - prompt "SPEAr300 Boards" - default BOARD_SPEAR300_EVB - -config BOARD_SPEAR300_EVB - bool "SPEAr300 Evaluation Board" - help - Supports ST SPEAr300 Evaluation Board -endchoice - -endif #MACH_SPEAR300
arch/arm/mach-spear3xx/Kconfig310 deleted +0 -17
@@ -1,17 +0,0 @@ -# -# SPEAr310 machine configuration file -# - -if MACH_SPEAR310 - -choice - prompt "SPEAr310 Boards" - default BOARD_SPEAR310_EVB - -config BOARD_SPEAR310_EVB - bool "SPEAr310 Evaluation Board" - help - Supports ST SPEAr310 Evaluation Board -endchoice - -endif #MACH_SPEAR310
arch/arm/mach-spear3xx/Kconfig320 deleted +0 -17
@@ -1,17 +0,0 @@ -# -# SPEAr320 machine configuration file -# - -if MACH_SPEAR320 - -choice - prompt "SPEAr320 Boards" - default BOARD_SPEAR320_EVB - -config BOARD_SPEAR320_EVB - bool "SPEAr320 Evaluation Board" - help - Supports ST SPEAr320 Evaluation Board -endchoice - -endif #MACH_SPEAR320
Signature · 1 line
1.5.5
PATCH 5/5 SPEAr3xx: Replace defconfigs with single unfied defconfig
In reply to Ryan MallonWe only need one defconfig for SPEAr3xx now since we can build all three boards into one kernel.
--- arch/arm/configs/spear300_defconfig | 773 ---------------------------------- arch/arm/configs/spear310_defconfig | 775 ----------------------------------- arch/arm/configs/spear320_defconfig | 775 ----------------------------------- arch/arm/configs/spear3xx_defconfig | 775 +++++++++++++++++++++++++++++++++++ 4 files changed, 775 insertions(+), 2323 deletions(-) delete mode 100644 arch/arm/configs/spear300_defconfig delete mode 100644 arch/arm/configs/spear310_defconfig delete mode 100644 arch/arm/configs/spear320_defconfig create mode 100644 arch/arm/configs/spear3xx_defconfig
arch/arm/configs/spear300_defconfig deleted +0 -773
@@ -1,773 +0,0 @@ -# -# Automatically generated make config: don't edit -# Linux kernel version: 2.6.32 -# Tue Mar 23 14:36:23 2010 -# -CONFIG_ARM=y -CONFIG_SYS_SUPPORTS_APM_EMULATION=y -CONFIG_GENERIC_GPIO=y -CONFIG_GENERIC_TIME=y -CONFIG_GENERIC_CLOCKEVENTS=y -CONFIG_GENERIC_HARDIRQS=y -CONFIG_STACKTRACE_SUPPORT=y -CONFIG_HAVE_LATENCYTOP_SUPPORT=y -CONFIG_LOCKDEP_SUPPORT=y -CONFIG_TRACE_IRQFLAGS_SUPPORT=y -CONFIG_HARDIRQS_SW_RESEND=y -CONFIG_GENERIC_IRQ_PROBE=y -CONFIG_RWSEM_GENERIC_SPINLOCK=y -CONFIG_GENERIC_HWEIGHT=y -CONFIG_GENERIC_CALIBRATE_DELAY=y -CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y -CONFIG_VECTORS_BASE=0xffff0000 -CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" -CONFIG_CONSTRUCTORS=y - -# -# General setup -# -CONFIG_EXPERIMENTAL=y -CONFIG_BROKEN_ON_SMP=y -CONFIG_INIT_ENV_ARG_LIMIT=32 -CONFIG_LOCALVERSION="" -CONFIG_LOCALVERSION_AUTO=y -CONFIG_SWAP=y -CONFIG_SYSVIPC=y -CONFIG_SYSVIPC_SYSCTL=y -CONFIG_BSD_PROCESS_ACCT=y -# CONFIG_BSD_PROCESS_ACCT_V3 is not set - -# -# RCU Subsystem -# -CONFIG_TREE_RCU=y -# CONFIG_TREE_PREEMPT_RCU is not set -# CONFIG_RCU_TRACE is not set -CONFIG_RCU_FANOUT=32 -# CONFIG_RCU_FANOUT_EXACT is not set -# CONFIG_TREE_RCU_TRACE is not set -# CONFIG_IKCONFIG is not set -CONFIG_LOG_BUF_SHIFT=17 -# CONFIG_GROUP_SCHED is not set -# CONFIG_CGROUPS is not set -# CONFIG_SYSFS_DEPRECATED_V2 is not set -# CONFIG_RELAY is not set -CONFIG_NAMESPACES=y -# CONFIG_UTS_NS is not set -# CONFIG_IPC_NS is not set -# CONFIG_USER_NS is not set -# CONFIG_PID_NS is not set -CONFIG_BLK_DEV_INITRD=y -CONFIG_INITRAMFS_SOURCE="" -CONFIG_RD_GZIP=y -CONFIG_RD_BZIP2=y -CONFIG_RD_LZMA=y -CONFIG_CC_OPTIMIZE_FOR_SIZE=y -CONFIG_SYSCTL=y -CONFIG_ANON_INODES=y -# CONFIG_EMBEDDED is not set -CONFIG_UID16=y -CONFIG_SYSCTL_SYSCALL=y -CONFIG_KALLSYMS=y -# CONFIG_KALLSYMS_ALL is not set -CONFIG_KALLSYMS_EXTRA_PASS=y -CONFIG_HOTPLUG=y -CONFIG_PRINTK=y -CONFIG_BUG=y -CONFIG_ELF_CORE=y -CONFIG_BASE_FULL=y -CONFIG_FUTEX=y -CONFIG_EPOLL=y -CONFIG_SIGNALFD=y -CONFIG_TIMERFD=y -CONFIG_EVENTFD=y -CONFIG_SHMEM=y -CONFIG_AIO=y - -# -# Kernel Performance Events And Counters -# -CONFIG_VM_EVENT_COUNTERS=y -CONFIG_SLUB_DEBUG=y -CONFIG_COMPAT_BRK=y -# CONFIG_SLAB is not set -CONFIG_SLUB=y -# CONFIG_SLOB is not set -# CONFIG_PROFILING is not set -CONFIG_HAVE_OPROFILE=y -# CONFIG_KPROBES is not set -CONFIG_HAVE_KPROBES=y -CONFIG_HAVE_KRETPROBES=y -CONFIG_HAVE_CLK=y - -# -# GCOV-based kernel profiling -# -# CONFIG_GCOV_KERNEL is not set -# CONFIG_SLOW_WORK is not set -CONFIG_HAVE_GENERIC_DMA_COHERENT=y -CONFIG_SLABINFO=y -CONFIG_RT_MUTEXES=y -CONFIG_BASE_SMALL=0 -CONFIG_MODULES=y -# CONFIG_MODULE_FORCE_LOAD is not set -CONFIG_MODULE_UNLOAD=y -# CONFIG_MODULE_FORCE_UNLOAD is not set -CONFIG_MODVERSIONS=y -# CONFIG_MODULE_SRCVERSION_ALL is not set -CONFIG_BLOCK=y -CONFIG_LBDAF=y -CONFIG_BLK_DEV_BSG=y -# CONFIG_BLK_DEV_INTEGRITY is not set - -# -# IO Schedulers -# -CONFIG_IOSCHED_NOOP=y -CONFIG_IOSCHED_AS=y -CONFIG_IOSCHED_DEADLINE=y -CONFIG_IOSCHED_CFQ=y -# CONFIG_DEFAULT_AS is not set -# CONFIG_DEFAULT_DEADLINE is not set -CONFIG_DEFAULT_CFQ=y -# CONFIG_DEFAULT_NOOP is not set -CONFIG_DEFAULT_IOSCHED="cfq" -# CONFIG_FREEZER is not set - -# -# System Type -# -CONFIG_MMU=y -# CONFIG_ARCH_AAEC2000 is not set -# CONFIG_ARCH_INTEGRATOR is not set -# CONFIG_ARCH_REALVIEW is not set -# CONFIG_ARCH_VERSATILE is not set -# CONFIG_ARCH_AT91 is not set -# CONFIG_ARCH_CLPS711X is not set -# CONFIG_ARCH_GEMINI is not set -# CONFIG_ARCH_EBSA110 is not set -# CONFIG_ARCH_EP93XX is not set -# CONFIG_ARCH_FOOTBRIDGE is not set -# CONFIG_ARCH_MXC is not set -# CONFIG_ARCH_STMP3XXX is not set -# CONFIG_ARCH_NETX is not set -# CONFIG_ARCH_H720X is not set -# CONFIG_ARCH_NOMADIK is not set -# CONFIG_ARCH_IOP13XX is not set -# CONFIG_ARCH_IOP32X is not set -# CONFIG_ARCH_IOP33X is not set -# CONFIG_ARCH_IXP23XX is not set -# CONFIG_ARCH_IXP2000 is not set -# CONFIG_ARCH_IXP4XX is not set -# CONFIG_ARCH_L7200 is not set -# CONFIG_ARCH_KIRKWOOD is not set -# CONFIG_ARCH_LOKI is not set -# CONFIG_ARCH_MV78XX0 is not set -# CONFIG_ARCH_ORION5X is not set -# CONFIG_ARCH_MMP is not set -# CONFIG_ARCH_KS8695 is not set -# CONFIG_ARCH_NS9XXX is not set -# CONFIG_ARCH_W90X900 is not set -# CONFIG_ARCH_PNX4008 is not set -# CONFIG_ARCH_PXA is not set -# CONFIG_ARCH_MSM is not set -# CONFIG_ARCH_RPC is not set -# CONFIG_ARCH_SA1100 is not set -# CONFIG_ARCH_S3C2410 is not set -# CONFIG_ARCH_S3C64XX is not set -# CONFIG_ARCH_S5PC1XX is not set -# CONFIG_ARCH_SHARK is not set -# CONFIG_ARCH_LH7A40X is not set -# CONFIG_ARCH_U300 is not set -# CONFIG_ARCH_DAVINCI is not set -# CONFIG_ARCH_OMAP is not set -# CONFIG_ARCH_BCMRING is not set -CONFIG_PLAT_SPEAR=y -CONFIG_ARCH_SPEAR3XX=y -# CONFIG_ARCH_SPEAR6XX is not set -CONFIG_MACH_SPEAR300=y -# CONFIG_MACH_SPEAR310 is not set -# CONFIG_MACH_SPEAR320 is not set -CONFIG_BOARD_SPEAR300_EVB=y - -# -# Processor Type -# -CONFIG_CPU_32=y -CONFIG_CPU_ARM926T=y -CONFIG_CPU_32v5=y -CONFIG_CPU_ABRT_EV5TJ=y -CONFIG_CPU_PABRT_LEGACY=y -CONFIG_CPU_CACHE_VIVT=y -CONFIG_CPU_COPY_V4WB=y -CONFIG_CPU_TLB_V4WBI=y -CONFIG_CPU_CP15=y -CONFIG_CPU_CP15_MMU=y - -# -# Processor Features -# -CONFIG_ARM_THUMB=y -# CONFIG_CPU_ICACHE_DISABLE is not set -# CONFIG_CPU_DCACHE_DISABLE is not set -# CONFIG_CPU_DCACHE_WRITETHROUGH is not set -# CONFIG_CPU_CACHE_ROUND_ROBIN is not set -CONFIG_ARM_L1_CACHE_SHIFT=5 -CONFIG_ARM_VIC=y -CONFIG_ARM_VIC_NR=2 -CONFIG_COMMON_CLKDEV=y - -# -# Bus support -# -CONFIG_ARM_AMBA=y -# CONFIG_PCI_SYSCALL is not set -# CONFIG_ARCH_SUPPORTS_MSI is not set -# CONFIG_PCCARD is not set - -# -# Kernel Features -# -# CONFIG_NO_HZ is not set -# CONFIG_HIGH_RES_TIMERS is not set -CONFIG_GENERIC_CLOCKEVENTS_BUILD=y -CONFIG_VMSPLIT_3G=y -# CONFIG_VMSPLIT_2G is not set -# CONFIG_VMSPLIT_1G is not set -CONFIG_PAGE_OFFSET=0xC0000000 -CONFIG_PREEMPT_NONE=y -# CONFIG_PREEMPT_VOLUNTARY is not set -# CONFIG_PREEMPT is not set -CONFIG_HZ=100 -# CONFIG_AEABI is not set -# CONFIG_ARCH_SPARSEMEM_DEFAULT is not set -# CONFIG_ARCH_SELECT_MEMORY_MODEL is not set -# CONFIG_HIGHMEM is not set -CONFIG_SELECT_MEMORY_MODEL=y -CONFIG_FLATMEM_MANUAL=y -# CONFIG_DISCONTIGMEM_MANUAL is not set -# CONFIG_SPARSEMEM_MANUAL is not set -CONFIG_FLATMEM=y -CONFIG_FLAT_NODE_MEM_MAP=y -CONFIG_PAGEFLAGS_EXTENDED=y -CONFIG_SPLIT_PTLOCK_CPUS=4096 -# CONFIG_PHYS_ADDR_T_64BIT is not set -CONFIG_ZONE_DMA_FLAG=0 -CONFIG_VIRT_TO_BUS=y -CONFIG_HAVE_MLOCK=y -CONFIG_HAVE_MLOCKED_PAGE_BIT=y -# CONFIG_KSM is not set -CONFIG_DEFAULT_MMAP_MIN_ADDR=4096 -CONFIG_ALIGNMENT_TRAP=y -# CONFIG_UACCESS_WITH_MEMCPY is not set - -# -# Boot options -# -CONFIG_ZBOOT_ROM_TEXT=0 -CONFIG_ZBOOT_ROM_BSS=0 -CONFIG_CMDLINE="" -# CONFIG_XIP_KERNEL is not set -# CONFIG_KEXEC is not set - -# -# CPU Power Management -# -# CONFIG_CPU_IDLE is not set - -# -# Floating point emulation -# - -# -# At least one emulation must be selected -# -# CONFIG_FPE_NWFPE is not set -# CONFIG_FPE_FASTFPE is not set -# CONFIG_VFP is not set - -# -# Userspace binary formats -# -CONFIG_BINFMT_ELF=y -# CONFIG_CORE_DUMP_DEFAULT_ELF_HEADERS is not set -CONFIG_HAVE_AOUT=y -# CONFIG_BINFMT_AOUT is not set -CONFIG_BINFMT_MISC=y - -# -# Power management options -# -# CONFIG_PM is not set -CONFIG_ARCH_SUSPEND_POSSIBLE=y -# CONFIG_NET is not set - -# -# Device Drivers -# - -# -# Generic Driver Options -# -CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" -# CONFIG_DEVTMPFS is not set -CONFIG_STANDALONE=y -CONFIG_PREVENT_FIRMWARE_BUILD=y -CONFIG_FW_LOADER=y -CONFIG_FIRMWARE_IN_KERNEL=y -CONFIG_EXTRA_FIRMWARE="" -# CONFIG_DEBUG_DRIVER is not set -# CONFIG_DEBUG_DEVRES is not set -# CONFIG_SYS_HYPERVISOR is not set -# CONFIG_MTD is not set -# CONFIG_PARPORT is not set -CONFIG_BLK_DEV=y -# CONFIG_BLK_DEV_COW_COMMON is not set -# CONFIG_BLK_DEV_LOOP is not set -CONFIG_BLK_DEV_RAM=y -CONFIG_BLK_DEV_RAM_COUNT=16 -CONFIG_BLK_DEV_RAM_SIZE=16384 -# CONFIG_BLK_DEV_XIP is not set -# CONFIG_CDROM_PKTCDVD is not set -CONFIG_MISC_DEVICES=y -# CONFIG_ENCLOSURE_SERVICES is not set -# CONFIG_C2PORT is not set - -# -# EEPROM support -# -# CONFIG_EEPROM_93CX6 is not set -CONFIG_HAVE_IDE=y -# CONFIG_IDE is not set - -# -# SCSI device support -# -# CONFIG_RAID_ATTRS is not set -# CONFIG_SCSI is not set -# CONFIG_SCSI_DMA is not set -# CONFIG_SCSI_NETLINK is not set -# CONFIG_ATA is not set -# CONFIG_MD is not set -# CONFIG_PHONE is not set - -# -# Input device support -# -CONFIG_INPUT=y -CONFIG_INPUT_FF_MEMLESS=y -# CONFIG_INPUT_POLLDEV is not set - -# -# Userland interfaces -# -CONFIG_INPUT_MOUSEDEV=y -# CONFIG_INPUT_MOUSEDEV_PSAUX is not set -CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024 -CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768 -# CONFIG_INPUT_JOYDEV is not set -# CONFIG_INPUT_EVDEV is not set -# CONFIG_INPUT_EVBUG is not set - -# -# Input Device Drivers -# -# CONFIG_INPUT_KEYBOARD is not set -# CONFIG_INPUT_MOUSE is not set -# CONFIG_INPUT_JOYSTICK is not set -# CONFIG_INPUT_TABLET is not set -# CONFIG_INPUT_TOUCHSCREEN is not set -# CONFIG_INPUT_MISC is not set - -# -# Hardware I/O ports -# -CONFIG_SERIO=y -CONFIG_SERIO_SERPORT=y -# CONFIG_SERIO_AMBAKMI is not set -# CONFIG_SERIO_RAW is not set -# CONFIG_GAMEPORT is not set - -# -# Character devices -# -CONFIG_VT=y -CONFIG_CONSOLE_TRANSLATIONS=y -CONFIG_VT_CONSOLE=y -CONFIG_HW_CONSOLE=y -# CONFIG_VT_HW_CONSOLE_BINDING is not set -CONFIG_DEVKMEM=y -# CONFIG_SERIAL_NONSTANDARD is not set - -# -# Serial drivers -# -# CONFIG_SERIAL_8250 is not set - -# -# Non-8250 serial port support -# -# CONFIG_SERIAL_AMBA_PL010 is not set -CONFIG_SERIAL_AMBA_PL011=y -CONFIG_SERIAL_AMBA_PL011_CONSOLE=y -CONFIG_SERIAL_CORE=y -CONFIG_SERIAL_CORE_CONSOLE=y -CONFIG_UNIX98_PTYS=y -# CONFIG_DEVPTS_MULTIPLE_INSTANCES is not set -# CONFIG_LEGACY_PTYS is not set -# CONFIG_IPMI_HANDLER is not set -# CONFIG_HW_RANDOM is not set -# CONFIG_R3964 is not set -CONFIG_RAW_DRIVER=y -CONFIG_MAX_RAW_DEVS=8192 -# CONFIG_TCG_TPM is not set -# CONFIG_I2C is not set -# CONFIG_SPI is not set - -# -# PPS support -# -# CONFIG_PPS is not set -CONFIG_ARCH_REQUIRE_GPIOLIB=y -CONFIG_GPIOLIB=y -# CONFIG_DEBUG_GPIO is not set -CONFIG_GPIO_SYSFS=y - -# -# Memory mapped GPIO expanders: -# -CONFIG_GPIO_PL061=y - -# -# I2C GPIO expanders: -# - -# -# PCI GPIO expanders: -# - -# -# SPI GPIO expanders: -# - -# -# AC97 GPIO expanders: -# -# CONFIG_W1 is not set -# CONFIG_POWER_SUPPLY is not set -# CONFIG_HWMON is not set -# CONFIG_THERMAL is not set -# CONFIG_WATCHDOG is not set -CONFIG_SSB_POSSIBLE=y - -# -# Sonics Silicon Backplane -# -# CONFIG_SSB is not set - -# -# Multifunction device drivers -# -# CONFIG_MFD_CORE is not set -# CONFIG_MFD_SM501 is not set -# CONFIG_MFD_ASIC3 is not set -# CONFIG_HTC_EGPIO is not set -# CONFIG_HTC_PASIC3 is not set -# CONFIG_MFD_TMIO is not set -# CONFIG_MFD_T7L66XB is not set -# CONFIG_MFD_TC6387XB is not set -# CONFIG_MFD_TC6393XB is not set -# CONFIG_REGULATOR is not set -# CONFIG_MEDIA_SUPPORT is not set - -# -# Graphics support -# -# CONFIG_VGASTATE is not set -# CONFIG_VIDEO_OUTPUT_CONTROL is not set -# CONFIG_FB is not set -# CONFIG_BACKLIGHT_LCD_SUPPORT is not set - -# -# Display device support -# -# CONFIG_DISPLAY_SUPPORT is not set - -# -# Console display driver support -# -# CONFIG_VGA_CONSOLE is not set -CONFIG_DUMMY_CONSOLE=y -# CONFIG_SOUND is not set -# CONFIG_HID_SUPPORT is not set -# CONFIG_USB_SUPPORT is not set -# CONFIG_MMC is not set -# CONFIG_MEMSTICK is not set -# CONFIG_NEW_LEDS is not set -# CONFIG_ACCESSIBILITY is not set -CONFIG_RTC_LIB=y -# CONFIG_RTC_CLASS is not set -# CONFIG_DMADEVICES is not set -# CONFIG_AUXDISPLAY is not set -# CONFIG_UIO is not set - -# -# TI VLYNQ -# -# CONFIG_STAGING is not set - -# -# File systems -# -CONFIG_EXT2_FS=y -CONFIG_EXT2_FS_XATTR=y -# CONFIG_EXT2_FS_POSIX_ACL is not set -CONFIG_EXT2_FS_SECURITY=y -# CONFIG_EXT2_FS_XIP is not set -CONFIG_EXT3_FS=y -# CONFIG_EXT3_DEFAULTS_TO_ORDERED is not set -CONFIG_EXT3_FS_XATTR=y -# CONFIG_EXT3_FS_POSIX_ACL is not set -CONFIG_EXT3_FS_SECURITY=y -# CONFIG_EXT4_FS is not set -CONFIG_JBD=y -# CONFIG_JBD_DEBUG is not set -CONFIG_FS_MBCACHE=y -# CONFIG_REISERFS_FS is not set -# CONFIG_JFS_FS is not set -# CONFIG_FS_POSIX_ACL is not set -# CONFIG_XFS_FS is not set -# CONFIG_GFS2_FS is not set -# CONFIG_BTRFS_FS is not set -# CONFIG_NILFS2_FS is not set -CONFIG_FILE_LOCKING=y -CONFIG_FSNOTIFY=y -CONFIG_DNOTIFY=y -# CONFIG_INOTIFY is not set -CONFIG_INOTIFY_USER=y -# CONFIG_QUOTA is not set -# CONFIG_AUTOFS_FS is not set -CONFIG_AUTOFS4_FS=m -# CONFIG_FUSE_FS is not set - -# -# Caches -# -# CONFIG_FSCACHE is not set - -# -# CD-ROM/DVD Filesystems -# -# CONFIG_ISO9660_FS is not set -# CONFIG_UDF_FS is not set - -# -# DOS/FAT/NT Filesystems -# -CONFIG_FAT_FS=m -CONFIG_MSDOS_FS=m -CONFIG_VFAT_FS=m -CONFIG_FAT_DEFAULT_CODEPAGE=437 -CONFIG_FAT_DEFAULT_IOCHARSET="ascii" -# CONFIG_NTFS_FS is not set - -# -# Pseudo filesystems -# -CONFIG_PROC_FS=y -CONFIG_PROC_SYSCTL=y -CONFIG_PROC_PAGE_MONITOR=y -CONFIG_SYSFS=y -CONFIG_TMPFS=y -# CONFIG_TMPFS_POSIX_ACL is not set -# CONFIG_HUGETLB_PAGE is not set -# CONFIG_CONFIGFS_FS is not set -CONFIG_MISC_FILESYSTEMS=y -# CONFIG_ADFS_FS is not set -# CONFIG_AFFS_FS is not set -# CONFIG_HFS_FS is not set -# CONFIG_HFSPLUS_FS is not set -# CONFIG_BEFS_FS is not set -# CONFIG_BFS_FS is not set -# CONFIG_EFS_FS is not set -# CONFIG_SQUASHFS is not set -# CONFIG_VXFS_FS is not set -# CONFIG_MINIX_FS is not set -# CONFIG_OMFS_FS is not set -# CONFIG_HPFS_FS is not set -# CONFIG_QNX4FS_FS is not set -# CONFIG_ROMFS_FS is not set -# CONFIG_SYSV_FS is not set -# CONFIG_UFS_FS is not set - -# -# Partition Types -# -CONFIG_PARTITION_ADVANCED=y -# CONFIG_ACORN_PARTITION is not set -# CONFIG_OSF_PARTITION is not set -# CONFIG_AMIGA_PARTITION is not set -# CONFIG_ATARI_PARTITION is not set -# CONFIG_MAC_PARTITION is not set -CONFIG_MSDOS_PARTITION=y -# CONFIG_BSD_DISKLABEL is not set -# CONFIG_MINIX_SUBPARTITION is not set -# CONFIG_SOLARIS_X86_PARTITION is not set -# CONFIG_UNIXWARE_DISKLABEL is not set -# CONFIG_LDM_PARTITION is not set -# CONFIG_SGI_PARTITION is not set -# CONFIG_ULTRIX_PARTITION is not set -# CONFIG_SUN_PARTITION is not set -# CONFIG_KARMA_PARTITION is not set -# CONFIG_EFI_PARTITION is not set -# CONFIG_SYSV68_PARTITION is not set -CONFIG_NLS=y -CONFIG_NLS_DEFAULT="utf8" -CONFIG_NLS_CODEPAGE_437=y -# CONFIG_NLS_CODEPAGE_737 is not set -# CONFIG_NLS_CODEPAGE_775 is not set -# CONFIG_NLS_CODEPAGE_850 is not set -# CONFIG_NLS_CODEPAGE_852 is not set -# CONFIG_NLS_CODEPAGE_855 is not set -# CONFIG_NLS_CODEPAGE_857 is not set -# CONFIG_NLS_CODEPAGE_860 is not set -# CONFIG_NLS_CODEPAGE_861 is not set -# CONFIG_NLS_CODEPAGE_862 is not set -# CONFIG_NLS_CODEPAGE_863 is not set -# CONFIG_NLS_CODEPAGE_864 is not set -# CONFIG_NLS_CODEPAGE_865 is not set -# CONFIG_NLS_CODEPAGE_866 is not set -# CONFIG_NLS_CODEPAGE_869 is not set -# CONFIG_NLS_CODEPAGE_936 is not set -# CONFIG_NLS_CODEPAGE_950 is not set -# CONFIG_NLS_CODEPAGE_932 is not set -# CONFIG_NLS_CODEPAGE_949 is not set -# CONFIG_NLS_CODEPAGE_874 is not set -# CONFIG_NLS_ISO8859_8 is not set -# CONFIG_NLS_CODEPAGE_1250 is not set -# CONFIG_NLS_CODEPAGE_1251 is not set -CONFIG_NLS_ASCII=m -# CONFIG_NLS_ISO8859_1 is not set -# CONFIG_NLS_ISO8859_2 is not set -# CONFIG_NLS_ISO8859_3 is not set -# CONFIG_NLS_ISO8859_4 is not set -# CONFIG_NLS_ISO8859_5 is not set -# CONFIG_NLS_ISO8859_6 is not set -# CONFIG_NLS_ISO8859_7 is not set -# CONFIG_NLS_ISO8859_9 is not set -# CONFIG_NLS_ISO8859_13 is not set -# CONFIG_NLS_ISO8859_14 is not set -# CONFIG_NLS_ISO8859_15 is not set -# CONFIG_NLS_KOI8_R is not set -# CONFIG_NLS_KOI8_U is not set -# CONFIG_NLS_UTF8 is not set - -# -# Kernel hacking -# -# CONFIG_PRINTK_TIME is not set -CONFIG_ENABLE_WARN_DEPRECATED=y -CONFIG_ENABLE_MUST_CHECK=y -CONFIG_FRAME_WARN=1024 -CONFIG_MAGIC_SYSRQ=y -# CONFIG_STRIP_ASM_SYMS is not set -# CONFIG_UNUSED_SYMBOLS is not set -CONFIG_DEBUG_FS=y -# CONFIG_HEADERS_CHECK is not set -CONFIG_DEBUG_KERNEL=y -# CONFIG_DEBUG_SHIRQ is not set -CONFIG_DETECT_SOFTLOCKUP=y -# CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC is not set -CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC_VALUE=0 -CONFIG_DETECT_HUNG_TASK=y -# CONFIG_BOOTPARAM_HUNG_TASK_PANIC is not set -CONFIG_BOOTPARAM_HUNG_TASK_PANIC_VALUE=0 -CONFIG_SCHED_DEBUG=y -# CONFIG_SCHEDSTATS is not set -# CONFIG_TIMER_STATS is not set -# CONFIG_DEBUG_OBJECTS is not set -# CONFIG_SLUB_DEBUG_ON is not set -# CONFIG_SLUB_STATS is not set -# CONFIG_DEBUG_KMEMLEAK is not set -# CONFIG_DEBUG_RT_MUTEXES is not set -# CONFIG_RT_MUTEX_TESTER is not set -CONFIG_DEBUG_SPINLOCK=y -# CONFIG_DEBUG_MUTEXES is not set -# CONFIG_DEBUG_LOCK_ALLOC is not set -# CONFIG_PROVE_LOCKING is not set -# CONFIG_LOCK_STAT is not set -CONFIG_DEBUG_SPINLOCK_SLEEP=y -# CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set -# CONFIG_DEBUG_KOBJECT is not set -CONFIG_DEBUG_BUGVERBOSE=y -CONFIG_DEBUG_INFO=y -# CONFIG_DEBUG_VM is not set -# CONFIG_DEBUG_WRITECOUNT is not set -CONFIG_DEBUG_MEMORY_INIT=y -# CONFIG_DEBUG_LIST is not set -# CONFIG_DEBUG_SG is not set -# CONFIG_DEBUG_NOTIFIERS is not set -# CONFIG_DEBUG_CREDENTIALS is not set -CONFIG_FRAME_POINTER=y -# CONFIG_BOOT_PRINTK_DELAY is not set -# CONFIG_RCU_TORTURE_TEST is not set -CONFIG_RCU_CPU_STALL_DETECTOR=y -# CONFIG_BACKTRACE_SELF_TEST is not set -# CONFIG_DEBUG_BLOCK_EXT_DEVT is not set -# CONFIG_DEBUG_FORCE_WEAK_PER_CPU is not set -# CONFIG_FAULT_INJECTION is not set -# CONFIG_LATENCYTOP is not set -# CONFIG_SYSCTL_SYSCALL_CHECK is not set -# CONFIG_PAGE_POISONING is not set -CONFIG_HAVE_FUNCTION_TRACER=y -CONFIG_TRACING_SUPPORT=y -CONFIG_FTRACE=y -# CONFIG_FUNCTION_TRACER is not set -# CONFIG_IRQSOFF_TRACER is not set -# CONFIG_SCHED_TRACER is not set -# CONFIG_ENABLE_DEFAULT_TRACERS is not set -# CONFIG_BOOT_TRACER is not set -CONFIG_BRANCH_PROFILE_NONE=y -# CONFIG_PROFILE_ANNOTATED_BRANCHES is not set -# CONFIG_PROFILE_ALL_BRANCHES is not set -# CONFIG_STACK_TRACER is not set -# CONFIG_KMEMTRACE is not set -# CONFIG_WORKQUEUE_TRACER is not set -# CONFIG_BLK_DEV_IO_TRACE is not set -# CONFIG_DYNAMIC_DEBUG is not set -# CONFIG_SAMPLES is not set -CONFIG_HAVE_ARCH_KGDB=y -# CONFIG_KGDB is not set -# CONFIG_DEBUG_USER is not set -# CONFIG_DEBUG_ERRORS is not set -# CONFIG_DEBUG_STACK_USAGE is not set -# CONFIG_DEBUG_LL is not set - -# -# Security options -# -# CONFIG_KEYS is not set -# CONFIG_SECURITY is not set -# CONFIG_SECURITYFS is not set -# CONFIG_SECURITY_FILE_CAPABILITIES is not set -# CONFIG_CRYPTO is not set -# CONFIG_BINARY_PRINTF is not set - -# -# Library routines -# -CONFIG_GENERIC_FIND_LAST_BIT=y -# CONFIG_CRC_CCITT is not set -# CONFIG_CRC16 is not set -# CONFIG_CRC_T10DIF is not set -# CONFIG_CRC_ITU_T is not set -# CONFIG_CRC32 is not set -# CONFIG_CRC7 is not set -# CONFIG_LIBCRC32C is not set -CONFIG_ZLIB_INFLATE=y -CONFIG_DECOMPRESS_GZIP=y -CONFIG_DECOMPRESS_BZIP2=y -CONFIG_DECOMPRESS_LZMA=y -CONFIG_HAS_IOMEM=y -CONFIG_HAS_IOPORT=y -CONFIG_HAS_DMA=y
arch/arm/configs/spear310_defconfig deleted +0 -775
775 lines not on this page · raw message
arch/arm/configs/spear320_defconfig deleted +0 -775
775 lines not on this page · raw message
arch/arm/configs/spear3xx_defconfig new file +775 -0
677 lines not on this page · raw message
The rest of this diff is not shown. View the raw message.
Signature · 1 line
1.5.5
Part of the diff is not shown here. View the raw message.
cover SPEAr3xx: Unify build of SPEAr3xx platforms
In reply to Ryan MallonQuoted 5 lines · Ryan Mallon
Rework the SPEAr3xx code to allow all three SPEAr3xx platforms to be built into a single kernel.
I do not have access to any SPEAr3xx hardware, so the patch series is build tested only.
Any interest in this patch series, or anybody with hardware that is able to test it?
Patch 1/5 is a simple cleanup patch which makes a bunch of local structures static, so it doesn't change functionality. Patch 5/5 can be dropped until the path forward for cleaning up the defconfigs has been decided. The other patches should not change the functionality if only one of the platforms is compiled in, but should also allow all three SPEAr3xx platforms to be built and run in a single kernel.
~Ryan
Signature · 7 lines
Bluewater Systems Ltd - ARM Technology Solution Centre Ryan Mallon 5 Amuri Park, 404 Barbadoes St ryan at bluewatersys.com PO Box 13 889, Christchurch 8013 http://www.bluewatersys.com New Zealand Phone: +64 3 3779127 Freecall: Australia 1800 148 751 Fax: +64 3 3779135 USA 1800 261 2934
cover SPEAr3xx: Unify build of SPEAr3xx platforms
In reply to Ryan MallonQuoted 33 lines · Ryan Mallon
Rework the SPEAr3xx code to allow all three SPEAr3xx platforms to be built into a single kernel.
I do not have access to any SPEAr3xx hardware, so the patch series is build tested only.
Ryan Mallon (5):
SPEAr3xx: Make local structres static
SPEAR3xx: Rename register/irq defines to remove naming conflicts
SPEAr3xx: Reworkpmx_devcode to remove conflicts
SPEAr3xx: Rework KConfig to allow all boards to be compiled in
SPEAr3xx: Replace defconfigs with single unfied defconfigarch/arm/configs/spear300_defconfig | 773 ----------------------- arch/arm/configs/spear310_defconfig | 775 ------------------------ arch/arm/configs/spear320_defconfig | 775 ------------------------ arch/arm/configs/spear3xx_defconfig | 775 ++++++++++++++++++++++++ arch/arm/mach-spear3xx/Kconfig | 30 +- arch/arm/mach-spear3xx/Kconfig300 | 17 - arch/arm/mach-spear3xx/Kconfig310 | 17 - arch/arm/mach-spear3xx/Kconfig320 | 17 - arch/arm/mach-spear3xx/include/mach/generic.h | 139 ++--- arch/arm/mach-spear3xx/include/mach/irqs.h | 195 +++--- arch/arm/mach-spear3xx/include/mach/spear300.h | 26 +- arch/arm/mach-spear3xx/include/mach/spear310.h | 44 +- arch/arm/mach-spear3xx/include/mach/spear320.h | 50 +- arch/arm/mach-spear3xx/spear300.c | 135 ++-- arch/arm/mach-spear3xx/spear300_evb.c | 26 +- arch/arm/mach-spear3xx/spear310.c | 137 +++-- arch/arm/mach-spear3xx/spear310_evb.c | 42 +- arch/arm/mach-spear3xx/spear320.c | 247 ++++---- arch/arm/mach-spear3xx/spear320_evb.c | 36 +- arch/arm/mach-spear3xx/spear3xx.c | 124 ++--
Quoted 10 lines
20 files changed, 1387 insertions(+), 2993 deletions(-) delete mode 100644 arch/arm/configs/spear300_defconfig delete mode 100644 arch/arm/configs/spear310_defconfig delete mode 100644 arch/arm/configs/spear320_defconfig create mode 100644 arch/arm/configs/spear3xx_defconfig delete mode 100644 arch/arm/mach-spear3xx/Kconfig300 delete mode 100644 arch/arm/mach-spear3xx/Kconfig310 delete mode 100644 arch/arm/mach-spear3xx/Kconfig320
Ryan,
Patches looks fine to me, but i need to test them before i Ack them. Please give me some time to do that, currently i am very busy in some other activities.
viresh.
cover SPEAr3xx: Unify build of SPEAr3xx platforms
Quoted 14 lines · Viresh KUMAR
Quoted 6 lines · Ryan Mallon
Rework the SPEAr3xx code to allow all three SPEAr3xx platforms to be built into a single kernel.
I do not have access to any SPEAr3xx hardware, so the patch series is build tested only.
Quoted 6 lines
Ryan Mallon (5):
SPEAr3xx: Make local structres static
SPEAR3xx: Rename register/irq defines to remove naming conflicts
SPEAr3xx: Reworkpmx_devcode to remove conflicts
SPEAr3xx: Rework KConfig to allow all boards to be compiled in
SPEAr3xx: Replace defconfigs with single unfied defconfig
Quoted 7 lines
Ryan,
Patches looks fine to me, but i need to test them before i Ack them. Please give me some time to do that, currently i am very busy in some other activities.
viresh.
Thanks, let me know if you need help with the code at all.
~Ryan