All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] Added board-3630.c file.
@ 2009-10-26  7:43 Pais, Allen
  2009-10-26 11:10 ` Menon, Nishanth
  2009-10-26 14:48 ` G, Manjunath Kondaiah
  0 siblings, 2 replies; 9+ messages in thread
From: Pais, Allen @ 2009-10-26  7:43 UTC (permalink / raw)
  To: linux-omap

>From 553ee2299d0ea6493e8587e7cc832361646f81a7 Mon Sep 17 00:00:00 2001
From: Allen Pais <allen.pais@ti.com>
Date: Mon, 26 Oct 2009 12:50:17 +0530
Subject: [PATCH 1/2] Added board-3630.c file.

The following sequence of patch set is to adds minimal OMAP3630 board support to OMAP GIT. 
This patch is tested on TI's OMAP3630 SDP.

OMAP 3630 is an ARM Cortex A8 based Multimedia Application processor. For more 
information please visit:
http://focus.ti.com/general/docs/wtbu/wtbuproductcontent.tsp?templateId=6123&navigation 
Id=12836&contentId=52606

Signed-off-by: Allen Pais <allen.pais@ti.com>
---
 arch/arm/mach-omap2/board-3630sdp.c |  188 +++++++++++++++++++++++++++++++++++
 1 files changed, 188 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/mach-omap2/board-3630sdp.c

diff --git a/arch/arm/mach-omap2/board-3630sdp.c b/arch/arm/mach-omap2/board-3630sdp.c
new file mode 100644
index 0000000..d3ddbd1
--- /dev/null
+++ b/arch/arm/mach-omap2/board-3630sdp.c
@@ -0,0 +1,188 @@
+/*
+ *  linux/arch/arm/mach-omap2/board-3630sdp.c
+ *  Copyright (C) 2007 Texas Instruments
+ *  Modified from mach-omap2/board-generic.c
+ *  Initial code: Allen Pais
+ *  
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License version 2 as
+ *  published by the Free Software Foundation.
+ */
+
+#include <linux/kernel.h>
+#include <linux/init.h>
+#include <linux/platform_device.h>
+#include <linux/input.h>
+#include <linux/input/matrix_keypad.h>
+#include <linux/gpio.h>
+#include <linux/i2c/twl4030.h>
+#include <linux/regulator/machine.h>
+
+#include <asm/mach-types.h>
+#include <asm/mach/arch.h>
+
+#include <plat/common.h>
+#include <plat/usb.h>
+
+#include "mmc-twl4030.h"
+#include "sdram-micron-mt46h32m32lf-6.h"
+
+/* 3630SDP has Qwerty keyboard*/
+static int board_keymap[] = {
+	KEY(0, 0, KEY_E),
+	KEY(1, 0, KEY_R),
+	KEY(2, 0, KEY_T),
+	KEY(3, 0, KEY_HOME),
+	KEY(6, 0, KEY_I),
+	KEY(7, 0, KEY_LEFTSHIFT),
+	KEY(0, 1, KEY_D),
+	KEY(1, 1, KEY_F),
+	KEY(2, 1, KEY_G),
+	KEY(3, 1, KEY_SEND),
+	KEY(6, 1, KEY_K),
+	KEY(7, 1, KEY_ENTER),
+	KEY(0, 2, KEY_X),
+	KEY(1, 2, KEY_C),
+	KEY(2, 2, KEY_V),
+	KEY(3, 2, KEY_END),
+	KEY(6, 2, KEY_DOT),
+	KEY(7, 2, KEY_CAPSLOCK),
+	KEY(0, 3, KEY_Z),
+	KEY(1, 3, KEY_KPPLUS),
+	KEY(2, 3, KEY_B),
+	KEY(3, 3, KEY_F1),
+	KEY(6, 3, KEY_O),
+	KEY(7, 3, KEY_SPACE),
+	KEY(0, 4, KEY_W),
+	KEY(1, 4, KEY_Y),
+	KEY(2, 4, KEY_U),
+	KEY(3, 4, KEY_F2),
+	KEY(4, 4, KEY_VOLUMEUP),
+	KEY(6, 4, KEY_L),
+	KEY(7, 4, KEY_LEFT),
+	KEY(0, 5, KEY_S),
+	KEY(1, 5, KEY_H),
+	KEY(2, 5, KEY_J),
+	KEY(3, 5, KEY_F3),
+	KEY(5, 5, KEY_VOLUMEDOWN),
+	KEY(6, 5, KEY_M),
+	KEY(4, 5, KEY_ENTER),
+	KEY(7, 5, KEY_RIGHT),
+	KEY(0, 6, KEY_Q),
+	KEY(1, 6, KEY_A),
+	KEY(2, 6, KEY_N),
+	KEY(3, 6, KEY_BACKSPACE),
+	KEY(6, 6, KEY_P),
+	KEY(7, 6, KEY_UP),
+	KEY(6, 7, KEY_SELECT),
+	KEY(7, 7, KEY_DOWN),
+	KEY(0, 7, KEY_PROG1),	/*MACRO 1 <User defined> */
+	KEY(1, 7, KEY_PROG2),	/*MACRO 2 <User defined> */
+	KEY(2, 7, KEY_PROG3),	/*MACRO 3 <User defined> */
+	KEY(3, 7, KEY_PROG4),	/*MACRO 4 <User defined> */
+	0
+};
+
+static struct matrix_keymap_data board_map_data = {
+	.keymap			= board_keymap,
+	.keymap_size		= ARRAY_SIZE(board_keymap),
+};
+
+static struct twl4030_keypad_data sdp3630_kp_twl4030_data = {
+	.keymap_data	= &board_map_data,
+	.rows		= 8,
+	.cols		= 8,
+	.rep		= 1,
+};
+
+static struct omap_board_config_kernel sdp3630_config[] __initdata = {
+};
+
+
+static int sdp3630_batt_table[] = {
+/* 0 C*/
+30800, 29500, 28300, 27100,
+26000, 24900, 23900, 22900, 22000, 21100, 20300, 19400, 18700, 17900,
+17200, 16500, 15900, 15300, 14700, 14100, 13600, 13100, 12600, 12100,
+11600, 11200, 10800, 10400, 10000, 9630,  9280,  8950,  8620,  8310,
+8020,  7730,  7460,  7200,  6950,  6710,  6470,  6250,  6040,  5830,
+5640,  5450,  5260,  5090,  4920,  4760,  4600,  4450,  4310,  4170,
+4040,  3910,  3790,  3670,  3550
+};
+
+static struct twl4030_bci_platform_data sdp3630_bci_data = {
+	.battery_tmp_tbl	= sdp3630_batt_table,
+	.tblsize		= ARRAY_SIZE(sdp3630_batt_table),
+};
+
+static struct twl4030_usb_data sdp3630_usb_data = {
+	.usb_mode	= T2_USB_MODE_ULPI,
+};
+
+static void __init omap_sdp3630_init_irq(void)
+{
+	omap_board_config = sdp3630_config;
+	omap_board_config_size = ARRAY_SIZE(sdp3630_config);
+	omap2_init_common_hw(mt46h32m32lf6_sdrc_params,
+				 mt46h32m32lf6_sdrc_params);
+	omap_init_irq();
+	omap_gpio_init();
+}
+
+static struct twl4030_madc_platform_data sdp3630_madc_data = {
+	.irq_line	= 1,
+};
+
+static struct twl4030_platform_data sdp3630_twldata = {
+	.irq_base	= TWL4030_IRQ_BASE,
+	.irq_end	= TWL4030_IRQ_END,
+
+	/* platform_data for children goes here */
+	.bci		= &sdp3630_bci_data,
+	.madc		= &sdp3630_madc_data,
+	.usb		= &sdp3630_usb_data,
+	.keypad		= &sdp3630_kp_twl4030_data,
+
+};
+
+static struct i2c_board_info __initdata sdp3630_i2c_boardinfo[] = {
+	{
+		I2C_BOARD_INFO("twl4030", 0x48),
+		.flags		= I2C_CLIENT_WAKE,
+		.irq		= INT_34XX_SYS_NIRQ,
+		.platform_data	= &sdp3630_twldata,
+	},
+};
+
+static int __init omap_i2c_init(void)
+{
+	omap_register_i2c_bus(1, 2600, sdp3630_i2c_boardinfo,
+			ARRAY_SIZE(sdp3630_i2c_boardinfo));
+	omap_register_i2c_bus(2, 400, NULL, 0);
+	omap_register_i2c_bus(3, 400, NULL, 0);
+	return 0;
+}
+
+static void __init omap_sdp3630_init(void)
+{
+	omap_i2c_init();
+	omap_serial_init();
+	usb_musb_init();
+}
+
+static void __init omap_sdp3630_map_io(void)
+{
+	omap2_set_globals_343x();
+	omap2_map_common_io();
+}
+
+MACHINE_START(OMAP_3630SDP, "OMAP SDP3630 board")
+	.phys_io	= 0x48000000,
+	.io_pg_offst	= ((0xfa000000) >> 18) & 0xfffc,
+	.boot_params	= 0x80000100,
+	.map_io		= omap_sdp3630_map_io,
+	.init_irq	= omap_sdp3630_init_irq,
+	.init_machine	= omap_sdp3630_init,
+	.timer		= &omap_timer,
+MACHINE_END
+
-- 
1.5.4.3

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* RE: [PATCH 1/2] Added board-3630.c file.
  2009-10-26  7:43 [PATCH 1/2] Added board-3630.c file Pais, Allen
@ 2009-10-26 11:10 ` Menon, Nishanth
  2009-10-26 11:44   ` Pais, Allen
  2009-10-26 14:48 ` G, Manjunath Kondaiah
  1 sibling, 1 reply; 9+ messages in thread
From: Menon, Nishanth @ 2009-10-26 11:10 UTC (permalink / raw)
  To: Pais, Allen, linux-omap

> -----Original Message-----
> From: linux-omap-owner@vger.kernel.org [mailto:linux-omap-
> owner@vger.kernel.org] On Behalf Of Pais, Allen
> Sent: Monday, October 26, 2009 2:43 AM
> To: linux-omap@vger.kernel.org
> Subject: [PATCH 1/2] Added board-3630.c file.
> 
> From 553ee2299d0ea6493e8587e7cc832361646f81a7 Mon Sep 17 00:00:00 2001
> From: Allen Pais <allen.pais@ti.com>
> Date: Mon, 26 Oct 2009 12:50:17 +0530
> Subject: [PATCH 1/2] Added board-3630.c file.
> 
> The following sequence of patch set is to adds minimal OMAP3630 board
> support to OMAP GIT.
> This patch is tested on TI's OMAP3630 SDP.
> 
> OMAP 3630 is an ARM Cortex A8 based Multimedia Application processor. For
> more
> information please visit:
> http://focus.ti.com/general/docs/wtbu/wtbuproductcontent.tsp?templateId=61
> 23&navigation
> Id=12836&contentId=52606
> 
> Signed-off-by: Allen Pais <allen.pais@ti.com>
> ---
>  arch/arm/mach-omap2/board-3630sdp.c |  188
> +++++++++++++++++++++++++++++++++++
>  1 files changed, 188 insertions(+), 0 deletions(-)
>  create mode 100644 arch/arm/mach-omap2/board-3630sdp.c
> 
> diff --git a/arch/arm/mach-omap2/board-3630sdp.c b/arch/arm/mach-
> omap2/board-3630sdp.c
> new file mode 100644
> index 0000000..d3ddbd1
> --- /dev/null
> +++ b/arch/arm/mach-omap2/board-3630sdp.c
> @@ -0,0 +1,188 @@
> +/*
> + *  linux/arch/arm/mach-omap2/board-3630sdp.c
> + *  Copyright (C) 2007 Texas Instruments
2007???? I don't recollect 3630 in 2007.

> + *  Modified from mach-omap2/board-generic.c
> + *  Initial code: Allen Pais
> + *
> + *  This program is free software; you can redistribute it and/or modify
> + *  it under the terms of the GNU General Public License version 2 as
> + *  published by the Free Software Foundation.
> + */
> +
> +#include <linux/kernel.h>
> +#include <linux/init.h>
> +#include <linux/platform_device.h>
> +#include <linux/input.h>
> +#include <linux/input/matrix_keypad.h>
> +#include <linux/gpio.h>
> +#include <linux/i2c/twl4030.h>
> +#include <linux/regulator/machine.h>
> +
> +#include <asm/mach-types.h>
> +#include <asm/mach/arch.h>
> +
> +#include <plat/common.h>
> +#include <plat/usb.h>
> +
> +#include "mmc-twl4030.h"
> +#include "sdram-micron-mt46h32m32lf-6.h"
> +
> +/* 3630SDP has Qwerty keyboard*/
> +static int board_keymap[] = {
> +	KEY(0, 0, KEY_E),
> +	KEY(1, 0, KEY_R),
> +	KEY(2, 0, KEY_T),
> +	KEY(3, 0, KEY_HOME),
> +	KEY(6, 0, KEY_I),
> +	KEY(7, 0, KEY_LEFTSHIFT),
> +	KEY(0, 1, KEY_D),
> +	KEY(1, 1, KEY_F),
> +	KEY(2, 1, KEY_G),
> +	KEY(3, 1, KEY_SEND),
> +	KEY(6, 1, KEY_K),
> +	KEY(7, 1, KEY_ENTER),
> +	KEY(0, 2, KEY_X),
> +	KEY(1, 2, KEY_C),
> +	KEY(2, 2, KEY_V),
> +	KEY(3, 2, KEY_END),
> +	KEY(6, 2, KEY_DOT),
> +	KEY(7, 2, KEY_CAPSLOCK),
> +	KEY(0, 3, KEY_Z),
> +	KEY(1, 3, KEY_KPPLUS),
> +	KEY(2, 3, KEY_B),
> +	KEY(3, 3, KEY_F1),
> +	KEY(6, 3, KEY_O),
> +	KEY(7, 3, KEY_SPACE),
> +	KEY(0, 4, KEY_W),
> +	KEY(1, 4, KEY_Y),
> +	KEY(2, 4, KEY_U),
> +	KEY(3, 4, KEY_F2),
> +	KEY(4, 4, KEY_VOLUMEUP),
> +	KEY(6, 4, KEY_L),
> +	KEY(7, 4, KEY_LEFT),
> +	KEY(0, 5, KEY_S),
> +	KEY(1, 5, KEY_H),
> +	KEY(2, 5, KEY_J),
> +	KEY(3, 5, KEY_F3),
> +	KEY(5, 5, KEY_VOLUMEDOWN),
> +	KEY(6, 5, KEY_M),
> +	KEY(4, 5, KEY_ENTER),
> +	KEY(7, 5, KEY_RIGHT),
> +	KEY(0, 6, KEY_Q),
> +	KEY(1, 6, KEY_A),
> +	KEY(2, 6, KEY_N),
> +	KEY(3, 6, KEY_BACKSPACE),
> +	KEY(6, 6, KEY_P),
> +	KEY(7, 6, KEY_UP),
> +	KEY(6, 7, KEY_SELECT),
> +	KEY(7, 7, KEY_DOWN),
> +	KEY(0, 7, KEY_PROG1),	/*MACRO 1 <User defined> */
> +	KEY(1, 7, KEY_PROG2),	/*MACRO 2 <User defined> */
> +	KEY(2, 7, KEY_PROG3),	/*MACRO 3 <User defined> */
> +	KEY(3, 7, KEY_PROG4),	/*MACRO 4 <User defined> */
> +	0
> +};

NAK. Could we follow the same issue with zoom2 -> break the keypad into a
Separate one and use it instead? Same for all reused zoom2 components..

> +
> +static struct matrix_keymap_data board_map_data = {
> +	.keymap			= board_keymap,
> +	.keymap_size		= ARRAY_SIZE(board_keymap),
> +};
> +
> +static struct twl4030_keypad_data sdp3630_kp_twl4030_data = {
> +	.keymap_data	= &board_map_data,
> +	.rows		= 8,
> +	.cols		= 8,
> +	.rep		= 1,
> +};
> +
> +static struct omap_board_config_kernel sdp3630_config[] __initdata = {
> +};
> +
> +
> +static int sdp3630_batt_table[] = {
> +/* 0 C*/
> +30800, 29500, 28300, 27100,
> +26000, 24900, 23900, 22900, 22000, 21100, 20300, 19400, 18700, 17900,
> +17200, 16500, 15900, 15300, 14700, 14100, 13600, 13100, 12600, 12100,
> +11600, 11200, 10800, 10400, 10000, 9630,  9280,  8950,  8620,  8310,
> +8020,  7730,  7460,  7200,  6950,  6710,  6470,  6250,  6040,  5830,
> +5640,  5450,  5260,  5090,  4920,  4760,  4600,  4450,  4310,  4170,
> +4040,  3910,  3790,  3670,  3550
> +};
> +
> +static struct twl4030_bci_platform_data sdp3630_bci_data = {
> +	.battery_tmp_tbl	= sdp3630_batt_table,
> +	.tblsize		= ARRAY_SIZE(sdp3630_batt_table),
> +};
> +
> +static struct twl4030_usb_data sdp3630_usb_data = {
> +	.usb_mode	= T2_USB_MODE_ULPI,
> +};
> +
> +static void __init omap_sdp3630_init_irq(void)
> +{
> +	omap_board_config = sdp3630_config;
> +	omap_board_config_size = ARRAY_SIZE(sdp3630_config);
> +	omap2_init_common_hw(mt46h32m32lf6_sdrc_params,
> +				 mt46h32m32lf6_sdrc_params);
> +	omap_init_irq();
> +	omap_gpio_init();
> +}
> +
> +static struct twl4030_madc_platform_data sdp3630_madc_data = {
> +	.irq_line	= 1,
> +};
> +
> +static struct twl4030_platform_data sdp3630_twldata = {
> +	.irq_base	= TWL4030_IRQ_BASE,
> +	.irq_end	= TWL4030_IRQ_END,
> +
> +	/* platform_data for children goes here */
> +	.bci		= &sdp3630_bci_data,
> +	.madc		= &sdp3630_madc_data,
> +	.usb		= &sdp3630_usb_data,
> +	.keypad		= &sdp3630_kp_twl4030_data,
> +
> +};
> +
> +static struct i2c_board_info __initdata sdp3630_i2c_boardinfo[] = {
> +	{
> +		I2C_BOARD_INFO("twl4030", 0x48),
> +		.flags		= I2C_CLIENT_WAKE,
> +		.irq		= INT_34XX_SYS_NIRQ,
> +		.platform_data	= &sdp3630_twldata,
> +	},
> +};
> +
> +static int __init omap_i2c_init(void)
> +{
> +	omap_register_i2c_bus(1, 2600, sdp3630_i2c_boardinfo,
> +			ARRAY_SIZE(sdp3630_i2c_boardinfo));
> +	omap_register_i2c_bus(2, 400, NULL, 0);
> +	omap_register_i2c_bus(3, 400, NULL, 0);
> +	return 0;
> +}
> +
> +static void __init omap_sdp3630_init(void)
> +{
> +	omap_i2c_init();
> +	omap_serial_init();
> +	usb_musb_init();
> +}
> +
> +static void __init omap_sdp3630_map_io(void)
> +{
> +	omap2_set_globals_343x();
> +	omap2_map_common_io();
> +}
> +
> +MACHINE_START(OMAP_3630SDP, "OMAP SDP3630 board")
> +	.phys_io	= 0x48000000,
> +	.io_pg_offst	= ((0xfa000000) >> 18) & 0xfffc,
> +	.boot_params	= 0x80000100,
> +	.map_io		= omap_sdp3630_map_io,
> +	.init_irq	= omap_sdp3630_init_irq,
> +	.init_machine	= omap_sdp3630_init,
> +	.timer		= &omap_timer,
> +MACHINE_END
> +
> --
> 1.5.4.3
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html


Regards,
Nishanth Menon


^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: [PATCH 1/2] Added board-3630.c file.
  2009-10-26 11:10 ` Menon, Nishanth
@ 2009-10-26 11:44   ` Pais, Allen
  2009-10-28 17:13     ` Pandita, Vikram
  0 siblings, 1 reply; 9+ messages in thread
From: Pais, Allen @ 2009-10-26 11:44 UTC (permalink / raw)
  To: Menon, Nishanth, linux-omap; +Cc: Pais, Allen

 

-----Original Message-----
From: linux-omap-owner@vger.kernel.org [mailto:linux-omap-owner@vger.kernel.org] On Behalf Of Menon, Nishanth
Sent: Monday, October 26, 2009 4:40 PM
To: Pais, Allen; linux-omap@vger.kernel.org
Subject: RE: [PATCH 1/2] Added board-3630.c file.

> -----Original Message-----
> From: linux-omap-owner@vger.kernel.org [mailto:linux-omap- 
> owner@vger.kernel.org] On Behalf Of Pais, Allen
> Sent: Monday, October 26, 2009 2:43 AM
> To: linux-omap@vger.kernel.org
> Subject: [PATCH 1/2] Added board-3630.c file.
> 
> From 553ee2299d0ea6493e8587e7cc832361646f81a7 Mon Sep 17 00:00:00 2001
> From: Allen Pais <allen.pais@ti.com>
> Date: Mon, 26 Oct 2009 12:50:17 +0530
> Subject: [PATCH 1/2] Added board-3630.c file.
> 
> The following sequence of patch set is to adds minimal OMAP3630 board 
> support to OMAP GIT.
> This patch is tested on TI's OMAP3630 SDP.
> 
> OMAP 3630 is an ARM Cortex A8 based Multimedia Application processor. 
> For more information please visit:
> http://focus.ti.com/general/docs/wtbu/wtbuproductcontent.tsp?templateI
> d=61
> 23&navigation
> Id=12836&contentId=52606
> 
> Signed-off-by: Allen Pais <allen.pais@ti.com>
> ---
>  arch/arm/mach-omap2/board-3630sdp.c |  188
> +++++++++++++++++++++++++++++++++++
>  1 files changed, 188 insertions(+), 0 deletions(-)  create mode 
> 100644 arch/arm/mach-omap2/board-3630sdp.c
> 
> diff --git a/arch/arm/mach-omap2/board-3630sdp.c b/arch/arm/mach- 
> omap2/board-3630sdp.c new file mode 100644 index 0000000..d3ddbd1
> --- /dev/null
> +++ b/arch/arm/mach-omap2/board-3630sdp.c
> @@ -0,0 +1,188 @@
> +/*
> + *  linux/arch/arm/mach-omap2/board-3630sdp.c
> + *  Copyright (C) 2007 Texas Instruments
2007???? I don't recollect 3630 in 2007.

> + *  Modified from mach-omap2/board-generic.c
> + *  Initial code: Allen Pais
> + *
> + *  This program is free software; you can redistribute it and/or 
> + modify
> + *  it under the terms of the GNU General Public License version 2 as
> + *  published by the Free Software Foundation.
> + */
> +
> +#include <linux/kernel.h>
> +#include <linux/init.h>
> +#include <linux/platform_device.h>
> +#include <linux/input.h>
> +#include <linux/input/matrix_keypad.h> #include <linux/gpio.h> 
> +#include <linux/i2c/twl4030.h> #include <linux/regulator/machine.h>
> +
> +#include <asm/mach-types.h>
> +#include <asm/mach/arch.h>
> +
> +#include <plat/common.h>
> +#include <plat/usb.h>
> +
> +#include "mmc-twl4030.h"
> +#include "sdram-micron-mt46h32m32lf-6.h"
> +
> +/* 3630SDP has Qwerty keyboard*/
> +static int board_keymap[] = {
> +	KEY(0, 0, KEY_E),
> +	KEY(1, 0, KEY_R),
> +	KEY(2, 0, KEY_T),
> +	KEY(3, 0, KEY_HOME),
> +	KEY(6, 0, KEY_I),
> +	KEY(7, 0, KEY_LEFTSHIFT),
> +	KEY(0, 1, KEY_D),
> +	KEY(1, 1, KEY_F),
> +	KEY(2, 1, KEY_G),
> +	KEY(3, 1, KEY_SEND),
> +	KEY(6, 1, KEY_K),
> +	KEY(7, 1, KEY_ENTER),
> +	KEY(0, 2, KEY_X),
> +	KEY(1, 2, KEY_C),
> +	KEY(2, 2, KEY_V),
> +	KEY(3, 2, KEY_END),
> +	KEY(6, 2, KEY_DOT),
> +	KEY(7, 2, KEY_CAPSLOCK),
> +	KEY(0, 3, KEY_Z),
> +	KEY(1, 3, KEY_KPPLUS),
> +	KEY(2, 3, KEY_B),
> +	KEY(3, 3, KEY_F1),
> +	KEY(6, 3, KEY_O),
> +	KEY(7, 3, KEY_SPACE),
> +	KEY(0, 4, KEY_W),
> +	KEY(1, 4, KEY_Y),
> +	KEY(2, 4, KEY_U),
> +	KEY(3, 4, KEY_F2),
> +	KEY(4, 4, KEY_VOLUMEUP),
> +	KEY(6, 4, KEY_L),
> +	KEY(7, 4, KEY_LEFT),
> +	KEY(0, 5, KEY_S),
> +	KEY(1, 5, KEY_H),
> +	KEY(2, 5, KEY_J),
> +	KEY(3, 5, KEY_F3),
> +	KEY(5, 5, KEY_VOLUMEDOWN),
> +	KEY(6, 5, KEY_M),
> +	KEY(4, 5, KEY_ENTER),
> +	KEY(7, 5, KEY_RIGHT),
> +	KEY(0, 6, KEY_Q),
> +	KEY(1, 6, KEY_A),
> +	KEY(2, 6, KEY_N),
> +	KEY(3, 6, KEY_BACKSPACE),
> +	KEY(6, 6, KEY_P),
> +	KEY(7, 6, KEY_UP),
> +	KEY(6, 7, KEY_SELECT),
> +	KEY(7, 7, KEY_DOWN),
> +	KEY(0, 7, KEY_PROG1),	/*MACRO 1 <User defined> */
> +	KEY(1, 7, KEY_PROG2),	/*MACRO 2 <User defined> */
> +	KEY(2, 7, KEY_PROG3),	/*MACRO 3 <User defined> */
> +	KEY(3, 7, KEY_PROG4),	/*MACRO 4 <User defined> */
> +	0
> +};

NAK. Could we follow the same issue with zoom2 -> break the keypad into a Separate one and use it instead? Same for all reused zoom2 components..

[Allen] Yes, we should do that. Not only for keypad but also
For display panel and touch screen so that sdp3630, zoom3 and
Zoom2 could use the same code, without having to duplicate
Code.

> +
> +static struct matrix_keymap_data board_map_data = {
> +	.keymap			= board_keymap,
> +	.keymap_size		= ARRAY_SIZE(board_keymap),
> +};
> +
> +static struct twl4030_keypad_data sdp3630_kp_twl4030_data = {
> +	.keymap_data	= &board_map_data,
> +	.rows		= 8,
> +	.cols		= 8,
> +	.rep		= 1,
> +};
> +
> +static struct omap_board_config_kernel sdp3630_config[] __initdata = 
> +{ };
> +
> +
> +static int sdp3630_batt_table[] = {
> +/* 0 C*/
> +30800, 29500, 28300, 27100,
> +26000, 24900, 23900, 22900, 22000, 21100, 20300, 19400, 18700, 17900, 
> +17200, 16500, 15900, 15300, 14700, 14100, 13600, 13100, 12600, 12100, 
> +11600, 11200, 10800, 10400, 10000, 9630,  9280,  8950,  8620,  8310, 
> +8020,  7730,  7460,  7200,  6950,  6710,  6470,  6250,  6040,  5830, 
> +5640,  5450,  5260,  5090,  4920,  4760,  4600,  4450,  4310,  4170, 
> +4040,  3910,  3790,  3670,  3550 };
> +
> +static struct twl4030_bci_platform_data sdp3630_bci_data = {
> +	.battery_tmp_tbl	= sdp3630_batt_table,
> +	.tblsize		= ARRAY_SIZE(sdp3630_batt_table),
> +};
> +
> +static struct twl4030_usb_data sdp3630_usb_data = {
> +	.usb_mode	= T2_USB_MODE_ULPI,
> +};
> +
> +static void __init omap_sdp3630_init_irq(void) {
> +	omap_board_config = sdp3630_config;
> +	omap_board_config_size = ARRAY_SIZE(sdp3630_config);
> +	omap2_init_common_hw(mt46h32m32lf6_sdrc_params,
> +				 mt46h32m32lf6_sdrc_params);
> +	omap_init_irq();
> +	omap_gpio_init();
> +}
> +
> +static struct twl4030_madc_platform_data sdp3630_madc_data = {
> +	.irq_line	= 1,
> +};
> +
> +static struct twl4030_platform_data sdp3630_twldata = {
> +	.irq_base	= TWL4030_IRQ_BASE,
> +	.irq_end	= TWL4030_IRQ_END,
> +
> +	/* platform_data for children goes here */
> +	.bci		= &sdp3630_bci_data,
> +	.madc		= &sdp3630_madc_data,
> +	.usb		= &sdp3630_usb_data,
> +	.keypad		= &sdp3630_kp_twl4030_data,
> +
> +};
> +
> +static struct i2c_board_info __initdata sdp3630_i2c_boardinfo[] = {
> +	{
> +		I2C_BOARD_INFO("twl4030", 0x48),
> +		.flags		= I2C_CLIENT_WAKE,
> +		.irq		= INT_34XX_SYS_NIRQ,
> +		.platform_data	= &sdp3630_twldata,
> +	},
> +};
> +
> +static int __init omap_i2c_init(void) {
> +	omap_register_i2c_bus(1, 2600, sdp3630_i2c_boardinfo,
> +			ARRAY_SIZE(sdp3630_i2c_boardinfo));
> +	omap_register_i2c_bus(2, 400, NULL, 0);
> +	omap_register_i2c_bus(3, 400, NULL, 0);
> +	return 0;
> +}
> +
> +static void __init omap_sdp3630_init(void) {
> +	omap_i2c_init();
> +	omap_serial_init();
> +	usb_musb_init();
> +}
> +
> +static void __init omap_sdp3630_map_io(void) {
> +	omap2_set_globals_343x();
> +	omap2_map_common_io();
> +}
> +
> +MACHINE_START(OMAP_3630SDP, "OMAP SDP3630 board")
> +	.phys_io	= 0x48000000,
> +	.io_pg_offst	= ((0xfa000000) >> 18) & 0xfffc,
> +	.boot_params	= 0x80000100,
> +	.map_io		= omap_sdp3630_map_io,
> +	.init_irq	= omap_sdp3630_init_irq,
> +	.init_machine	= omap_sdp3630_init,
> +	.timer		= &omap_timer,
> +MACHINE_END
> +
> --
> 1.5.4.3
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" 
> in the body of a message to majordomo@vger.kernel.org More majordomo 
> info at  http://vger.kernel.org/majordomo-info.html


Regards,
Nishanth Menon

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@vger.kernel.org More majordomo info at  http://vger.kernel.org/majordomo-info.html


- Allen

^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: [PATCH 1/2] Added board-3630.c file.
  2009-10-26  7:43 [PATCH 1/2] Added board-3630.c file Pais, Allen
  2009-10-26 11:10 ` Menon, Nishanth
@ 2009-10-26 14:48 ` G, Manjunath Kondaiah
  2009-10-28 17:15   ` Pandita, Vikram
  1 sibling, 1 reply; 9+ messages in thread
From: G, Manjunath Kondaiah @ 2009-10-26 14:48 UTC (permalink / raw)
  To: Pais, Allen, linux-omap


> +static int __init omap_i2c_init(void)
> +{
> +	omap_register_i2c_bus(1, 2600, sdp3630_i2c_boardinfo,
> +			ARRAY_SIZE(sdp3630_i2c_boardinfo));
> +	omap_register_i2c_bus(2, 400, NULL, 0);
> +	omap_register_i2c_bus(3, 400, NULL, 0);
> +	return 0;
> +}

If sdp3630 board is using TWL5030/GAIA, then you need to reduce I2C speed.
http://patchwork.kernel.org/patch/52760/

-Manjunath

^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: [PATCH 1/2] Added board-3630.c file.
  2009-10-26 11:44   ` Pais, Allen
@ 2009-10-28 17:13     ` Pandita, Vikram
  2009-10-28 21:24       ` Menon, Nishanth
  0 siblings, 1 reply; 9+ messages in thread
From: Pandita, Vikram @ 2009-10-28 17:13 UTC (permalink / raw)
  To: Pais, Allen, Menon, Nishanth, linux-omap



>-----Original Message-----
>From: linux-omap-owner@vger.kernel.org [mailto:linux-omap-owner@vger.kernel.org] On Behalf Of Pais,
>Sent: Monday, October 26, 2009 4:40 PM
>To: Pais, Allen; linux-omap@vger.kernel.org
>Subject: RE: [PATCH 1/2] Added board-3630.c file.

>> Signed-off-by: Allen Pais <allen.pais@ti.com>
>> ---
>>  arch/arm/mach-omap2/board-3630sdp.c |  188
>> +++++++++++++++++++++++++++++++++++
>>  1 files changed, 188 insertions(+), 0 deletions(-)  create mode
>> 100644 arch/arm/mach-omap2/board-3630sdp.c
>>
>> diff --git a/arch/arm/mach-omap2/board-3630sdp.c b/arch/arm/mach-
>> omap2/board-3630sdp.c new file mode 100644 index 0000000..d3ddbd1
>> --- /dev/null
>> +++ b/arch/arm/mach-omap2/board-3630sdp.c
>> @@ -0,0 +1,188 @@
>> +/*
>> +
>
>NAK. Could we follow the same issue with zoom2 -> break the keypad into a Separate one and use it
>instead? Same for all reused zoom2 components..
>
>[Allen] Yes, we should do that. Not only for keypad but also
>For display panel and touch screen so that sdp3630, zoom3 and
>Zoom2 could use the same code, without having to duplicate
>Code.

We just got the same image for zoom3 boot on SDP3630 (after mach-type change)
The peripheral set is almost >90% same: same keypad, same display, same RAM, same NAND.

I see a good amount of re-use possible here. 
Here is how we could do it:

Board-zoom2.c 
Split into:
	Board-zoom2.c
	Board-zoom-peripheral.c [reuse]

3630 zoom3 uses:
	Board-zoom3.c
	Board-zoom-peripheral.c [reuse]

3630 SDP uses:
	Board-3630sdp.c
	Board-zoom-peripheral.c [reuse]


Will give a first pass at this split up and post patches.

>
>> +
>> +static struct matrix_keymap_data board_map_data = {

^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: [PATCH 1/2] Added board-3630.c file.
  2009-10-26 14:48 ` G, Manjunath Kondaiah
@ 2009-10-28 17:15   ` Pandita, Vikram
  0 siblings, 0 replies; 9+ messages in thread
From: Pandita, Vikram @ 2009-10-28 17:15 UTC (permalink / raw)
  To: G, Manjunath Kondaiah, Pais, Allen, linux-omap



>-----Original Message-----
>From: linux-omap-owner@vger.kernel.org [mailto:linux-omap-owner@vger.kernel.org] On Behalf Of G,
>Manjunath Kondaiah
>Sent: Monday, October 26, 2009 9:49 AM
>To: Pais, Allen; linux-omap@vger.kernel.org
>Subject: RE: [PATCH 1/2] Added board-3630.c file.
>
>
>> +static int __init omap_i2c_init(void)
>> +{
>> +	omap_register_i2c_bus(1, 2600, sdp3630_i2c_boardinfo,
>> +			ARRAY_SIZE(sdp3630_i2c_boardinfo));
>> +	omap_register_i2c_bus(2, 400, NULL, 0);
>> +	omap_register_i2c_bus(3, 400, NULL, 0);
>> +	return 0;
>> +}
>
>If sdp3630 board is using TWL5030/GAIA, then you need to reduce I2C speed.
>http://patchwork.kernel.org/patch/52760/

Very valid point.

>
>-Manjunath--
>To unsubscribe from this list: send the line "unsubscribe linux-omap" in
>the body of a message to majordomo@vger.kernel.org
>More majordomo info at  http://vger.kernel.org/majordomo-info.html


^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: [PATCH 1/2] Added board-3630.c file.
  2009-10-28 17:13     ` Pandita, Vikram
@ 2009-10-28 21:24       ` Menon, Nishanth
  2009-10-28 21:39         ` Pandita, Vikram
  0 siblings, 1 reply; 9+ messages in thread
From: Menon, Nishanth @ 2009-10-28 21:24 UTC (permalink / raw)
  To: Pandita, Vikram, Pais, Allen, linux-omap

> -----Original Message-----
> From: Pandita, Vikram
> Sent: Wednesday, October 28, 2009 7:14 PM
> To: Pais, Allen; Menon, Nishanth; linux-omap@vger.kernel.org
> Subject: RE: [PATCH 1/2] Added board-3630.c file.
> 
> 
> 
> >-----Original Message-----
> >From: linux-omap-owner@vger.kernel.org [mailto:linux-omap-
> owner@vger.kernel.org] On Behalf Of Pais,
> >Sent: Monday, October 26, 2009 4:40 PM
> >To: Pais, Allen; linux-omap@vger.kernel.org
> >Subject: RE: [PATCH 1/2] Added board-3630.c file.
> 
> >> Signed-off-by: Allen Pais <allen.pais@ti.com>
> >> ---
> >>  arch/arm/mach-omap2/board-3630sdp.c |  188
> >> +++++++++++++++++++++++++++++++++++
> >>  1 files changed, 188 insertions(+), 0 deletions(-)  create mode
> >> 100644 arch/arm/mach-omap2/board-3630sdp.c
> >>
> >> diff --git a/arch/arm/mach-omap2/board-3630sdp.c b/arch/arm/mach-
> >> omap2/board-3630sdp.c new file mode 100644 index 0000000..d3ddbd1
> >> --- /dev/null
> >> +++ b/arch/arm/mach-omap2/board-3630sdp.c
> >> @@ -0,0 +1,188 @@
> >> +/*
> >> +
> >
> >NAK. Could we follow the same issue with zoom2 -> break the keypad into a
> Separate one and use it
> >instead? Same for all reused zoom2 components..
> >
> >[Allen] Yes, we should do that. Not only for keypad but also
> >For display panel and touch screen so that sdp3630, zoom3 and
> >Zoom2 could use the same code, without having to duplicate
> >Code.
> 
> We just got the same image for zoom3 boot on SDP3630 (after mach-type
> change)
> The peripheral set is almost >90% same: same keypad, same display, same
> RAM, same NAND.
Ok zoom2,zoom3,sdp3630 -> might be good to compare. Here is a quick attempt:
Peripheral    zoom2    zoom3    sdp3630
NAND          A         B       B
SDRAM         A         B       B
Keypad        A         A       A
Camera        A         A       A
LCD Display   A         A       A
Power         A         A       A
HDMI          A         A       ??
Audio         A         A       ??
Voltage resources??
LEDs          A         A       A
OPPs          A         B       B
.... others?? ...
NOTE: I am just using A and B to show the types of devices. So the files registering the same type would probably be shared.. could you expand this list?

> 
> I see a good amount of re-use possible here.
> Here is how we could do it:
> 
> Board-zoom2.c
> Split into:
> 	Board-zoom2.c
> 	Board-zoom-peripheral.c [reuse]
> 
> 3630 zoom3 uses:
> 	Board-zoom3.c
> 	Board-zoom-peripheral.c [reuse]
> 
> 3630 SDP uses:
> 	Board-3630sdp.c
> 	Board-zoom-peripheral.c [reuse]
> 
> 
> Will give a first pass at this split up and post patches.
> 
Thanks..

Regards,
Nishanth Menon


^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: [PATCH 1/2] Added board-3630.c file.
  2009-10-28 21:24       ` Menon, Nishanth
@ 2009-10-28 21:39         ` Pandita, Vikram
  2009-10-28 22:10           ` Menon, Nishanth
  0 siblings, 1 reply; 9+ messages in thread
From: Pandita, Vikram @ 2009-10-28 21:39 UTC (permalink / raw)
  To: Menon, Nishanth, Pais, Allen, linux-omap, Taliaferro, Steve


Nishanth

>-----Original Message-----
>From: Menon, Nishanth
>> From: Pandita, Vikram
>> >From: linux-omap-owner@vger.kernel.org [mailto:linux-omap-
>> owner@vger.kernel.org] On Behalf Of Pais,
>> >Sent: Monday, October 26, 2009 4:40 PM
>> >To: Pais, Allen; linux-omap@vger.kernel.org
>> >Subject: RE: [PATCH 1/2] Added board-3630.c file.
>>
>> >> Signed-off-by: Allen Pais <allen.pais@ti.com>
>> >> ---
>> >>  arch/arm/mach-omap2/board-3630sdp.c |  188
>> >> +++++++++++++++++++++++++++++++++++
>> >>  1 files changed, 188 insertions(+), 0 deletions(-)  create mode
>> >> 100644 arch/arm/mach-omap2/board-3630sdp.c
>> >>
>> >> diff --git a/arch/arm/mach-omap2/board-3630sdp.c b/arch/arm/mach-
>> >> omap2/board-3630sdp.c new file mode 100644 index 0000000..d3ddbd1
>> >> --- /dev/null
>> >> +++ b/arch/arm/mach-omap2/board-3630sdp.c
>> >> @@ -0,0 +1,188 @@
>> >> +/*
>> >> +
>> >
>> >NAK. Could we follow the same issue with zoom2 -> break the keypad into a
>> Separate one and use it
>> >instead? Same for all reused zoom2 components..
>> >
>> >[Allen] Yes, we should do that. Not only for keypad but also
>> >For display panel and touch screen so that sdp3630, zoom3 and
>> >Zoom2 could use the same code, without having to duplicate
>> >Code.
>>
>> We just got the same image for zoom3 boot on SDP3630 (after mach-type
>> change)
>> The peripheral set is almost >90% same: same keypad, same display, same
>> RAM, same NAND.
>Ok zoom2,zoom3,sdp3630 -> might be good to compare. Here is a quick attempt:
>Peripheral    zoom2    zoom3    sdp3630

I was making that list already. Good to see you thinking on same lines.
However your list does not match with mine and I tried to confirm the changes looking at h/w.
Here is the list, in the order of impact:


Peripheral    zoom2    zoom3    sdp3630
Ethernet	  A		A	  B **(may not be same)
NOR		  n/a	     n/a	  B ** different
Onenand	  n/a	     n/a	  B ** diffferent
HDMI          A         A       B **(Need to verify: not there on i2c3)
NAND          A         A       A (same nand)
SDRAM         A         A       A (same sdram)
Keypad        A         A       A (same twl) 
Camera        A         A       A (same sensor can be mounted: can check further)
LCD Display   A         A       A (same wvga display)
Power         A         A       A (same chip level)
Audio         A         A       A (its the same)
Voltage resources??			(not sure what you mean?)
LEDs          A         A       B (LEDs are board specific, can reside in separate board file)
OPPs          A         A       A (same chip feature)


>.... others?? ...
>NOTE: I am just using A and B to show the types of devices. So the files registering the same type
>would probably be shared.. could you expand this list?
>
>>
>> I see a good amount of re-use possible here.
>> Here is how we could do it:
>>
>> Board-zoom2.c
>> Split into:
>> 	Board-zoom2.c
>> 	Board-zoom-peripheral.c [reuse]
>>
>> 3630 zoom3 uses:
>> 	Board-zoom3.c
>> 	Board-zoom-peripheral.c [reuse]
>>
>> 3630 SDP uses:
>> 	Board-3630sdp.c
>> 	Board-zoom-peripheral.c [reuse]
>>
>>
>> Will give a first pass at this split up and post patches.
>>
>Thanks..
>
>Regards,
>Nishanth Menon


^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: [PATCH 1/2] Added board-3630.c file.
  2009-10-28 21:39         ` Pandita, Vikram
@ 2009-10-28 22:10           ` Menon, Nishanth
  0 siblings, 0 replies; 9+ messages in thread
From: Menon, Nishanth @ 2009-10-28 22:10 UTC (permalink / raw)
  To: Pandita, Vikram, Pais, Allen, linux-omap, Taliaferro, Steve


> From: Pandita, Vikram
> Sent: Wednesday, October 28, 2009 11:39 PM
[...]
> I was making that list already. Good to see you thinking on same lines.
> However your list does not match with mine and I tried to confirm the
> changes looking at h/w.
Thanks for correcting my list.. it was mostly off the top of my head list..

> Here is the list, in the order of impact:
> 
> 
> Peripheral    zoom2    zoom3    sdp3630
> Ethernet	  A		A	  B **(may not be same)
> NOR		  n/a	     n/a	  B ** different
> Onenand	  n/a	     n/a	  B ** diffferent
> HDMI          A         A       B **(Need to verify: not there on i2c3)
> NAND          A         A       A (same nand)
> SDRAM         A         A       A (same sdram)
Correction      A         B       B (sdram is now 512Meg)

> Keypad        A         A       A (same twl)
> Camera        A         A       A (same sensor can be mounted: can check
> further)
> LCD Display   A         A       A (same wvga display)
> Power         A         A       A (same chip level)
> Audio         A         A       A (its the same)
> Voltage resources??			(not sure what you mean?)
Vaux resources etc... mostly deltas in terms of which twl resource drives what device.. are the maps exactly the same? Are the power scripts for suspend/resume/reset etc the same?

> LEDs          A         A       B (LEDs are board specific, can reside in
> separate board file)
> OPPs          A         A       A (same chip feature)
> 
> 
[...]


Regards,
Nishanth Menon

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2009-10-28 22:10 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-10-26  7:43 [PATCH 1/2] Added board-3630.c file Pais, Allen
2009-10-26 11:10 ` Menon, Nishanth
2009-10-26 11:44   ` Pais, Allen
2009-10-28 17:13     ` Pandita, Vikram
2009-10-28 21:24       ` Menon, Nishanth
2009-10-28 21:39         ` Pandita, Vikram
2009-10-28 22:10           ` Menon, Nishanth
2009-10-26 14:48 ` G, Manjunath Kondaiah
2009-10-28 17:15   ` Pandita, Vikram

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.