public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH 0/9] Update support for CM-T35
@ 2011-04-05  7:08 Igor Grinberg
  2011-04-05  7:08 ` [U-Boot] [PATCH 1/9] OMAP3: CM-T35: Move DECLARE_GLOBAL_DATA_PTR to file scope Igor Grinberg
                   ` (9 more replies)
  0 siblings, 10 replies; 13+ messages in thread
From: Igor Grinberg @ 2011-04-05  7:08 UTC (permalink / raw)
  To: u-boot

This patch serie s based on the latest U-Boot release (v2011.03) and
updates support for Compulab CM-T35 board:
1) Some clean up
2) MMC/SD Card fix
3) Add Green Status LED
4) Add support for CM-T3730 which is basically the same board, but
   has TI's DM3730 SoC and therefore some changes are required

Igor Grinberg (9):
  OMAP3: CM-T35: Move DECLARE_GLOBAL_DATA_PTR to file scope
  OMAP3: CM-T35: update config
  OMAP3: CM-T35: update board files header information
  OMAP3: CM-T35: update MAINTAINERS file
  OMAP3: CM-T35: add MMC1 pinmux
  OMAP3: CM-T35: fix mmc
  OMAP3: CM-T35: remove redundand i2c initialization
  OMAP3: CM-T35: enable the green LED
  OMAP3: CM-T35: Add support for CM-T3730

 MAINTAINERS              |    8 ++--
 board/cm_t35/Makefile    |    2 +-
 board/cm_t35/cm_t35.c    |  116 ++++++++++++++++++++++++++++++++--------------
 board/cm_t35/leds.c      |   45 ++++++++++++++++++
 include/configs/cm_t35.h |   41 +++++++++++-----
 5 files changed, 160 insertions(+), 52 deletions(-)
 create mode 100644 board/cm_t35/leds.c

-- 
1.7.3.4

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

* [U-Boot] [PATCH 1/9] OMAP3: CM-T35: Move DECLARE_GLOBAL_DATA_PTR to file scope
  2011-04-05  7:08 [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
@ 2011-04-05  7:08 ` Igor Grinberg
  2011-04-05  7:08 ` [U-Boot] [PATCH 2/9] OMAP3: CM-T35: update config Igor Grinberg
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 13+ messages in thread
From: Igor Grinberg @ 2011-04-05  7:08 UTC (permalink / raw)
  To: u-boot


Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
---
 board/cm_t35/cm_t35.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/board/cm_t35/cm_t35.c b/board/cm_t35/cm_t35.c
index 459df0b..2eb9dac 100644
--- a/board/cm_t35/cm_t35.c
+++ b/board/cm_t35/cm_t35.c
@@ -41,6 +41,8 @@
 #include <asm/arch/sys_proto.h>
 #include <asm/mach-types.h>
 
+DECLARE_GLOBAL_DATA_PTR;
+
 const omap3_sysinfo sysinfo = {
 	DDR_DISCRETE,
 	"CM-T35 board",
@@ -73,8 +75,6 @@ static u32 gpmc_nand_config[GPMC_MAX_REG] = {
  */
 int board_init(void)
 {
-	DECLARE_GLOBAL_DATA_PTR;
-
 	gpmc_init(); /* in SRAM or SDRAM, finish GPMC */
 
 	enable_gpmc_cs_config(gpmc_nand_config, &gpmc_cfg->cs[0],
-- 
1.7.3.4

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

* [U-Boot] [PATCH 2/9] OMAP3: CM-T35: update config
  2011-04-05  7:08 [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
  2011-04-05  7:08 ` [U-Boot] [PATCH 1/9] OMAP3: CM-T35: Move DECLARE_GLOBAL_DATA_PTR to file scope Igor Grinberg
@ 2011-04-05  7:08 ` Igor Grinberg
  2011-04-05  7:08 ` [U-Boot] [PATCH 3/9] OMAP3: CM-T35: update board files header information Igor Grinberg
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 13+ messages in thread
From: Igor Grinberg @ 2011-04-05  7:08 UTC (permalink / raw)
  To: u-boot


Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
---
 include/configs/cm_t35.h |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/include/configs/cm_t35.h b/include/configs/cm_t35.h
index 510c6d4..ec6a1a3 100644
--- a/include/configs/cm_t35.h
+++ b/include/configs/cm_t35.h
@@ -244,10 +244,13 @@
 		"fi; " \
 	"else run nandboot; fi"
 
-#define CONFIG_AUTO_COMPLETE		1
 /*
  * Miscellaneous configurable options
  */
+#define CONFIG_AUTO_COMPLETE
+#define CONFIG_CMDLINE_EDITING
+#define CONFIG_TIMESTAMP
+#define CONFIG_SYS_AUTOLOAD     "no"
 #define CONFIG_SYS_LONGHELP		/* undef to save memory */
 #define CONFIG_SYS_HUSH_PARSER		/* use "hush" command parser */
 #define CONFIG_SYS_PROMPT_HUSH_PS2	"> "
-- 
1.7.3.4

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

* [U-Boot] [PATCH 3/9] OMAP3: CM-T35: update board files header information
  2011-04-05  7:08 [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
  2011-04-05  7:08 ` [U-Boot] [PATCH 1/9] OMAP3: CM-T35: Move DECLARE_GLOBAL_DATA_PTR to file scope Igor Grinberg
  2011-04-05  7:08 ` [U-Boot] [PATCH 2/9] OMAP3: CM-T35: update config Igor Grinberg
@ 2011-04-05  7:08 ` Igor Grinberg
  2011-04-05  7:08 ` [U-Boot] [PATCH 4/9] OMAP3: CM-T35: update MAINTAINERS file Igor Grinberg
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 13+ messages in thread
From: Igor Grinberg @ 2011-04-05  7:08 UTC (permalink / raw)
  To: u-boot


Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
---
 board/cm_t35/cm_t35.c    |    8 ++++----
 include/configs/cm_t35.h |    6 +++---
 2 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/board/cm_t35/cm_t35.c b/board/cm_t35/cm_t35.c
index 2eb9dac..5c8d569 100644
--- a/board/cm_t35/cm_t35.c
+++ b/board/cm_t35/cm_t35.c
@@ -1,8 +1,9 @@
 /*
- * (C) Copyright 2010
+ * (C) Copyright 2011
  * CompuLab, Ltd. <www.compulab.co.il>
  *
- * Author: Mike Rapoport <mike@compulab.co.il>
+ * Authors: Mike Rapoport <mike@compulab.co.il>
+ *	    Igor Grinberg <grinberg@compulab.co.il>
  *
  * Derived from omap3evm and Beagle Board by
  *	Manikandan Pillai <mani.pillai@ti.com>
@@ -24,8 +25,7 @@
  *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
+ * Foundation, Inc.
  */
 
 #include <common.h>
diff --git a/include/configs/cm_t35.h b/include/configs/cm_t35.h
index ec6a1a3..5624abd 100644
--- a/include/configs/cm_t35.h
+++ b/include/configs/cm_t35.h
@@ -1,7 +1,8 @@
 /*
- * (C) Copyright 2010
+ * (C) Copyright 2011
  * CompuLab, Ltd.
  * Mike Rapoport <mike@compulab.co.il>
+ * Igor Grinberg <grinberg@compulab.co.il>
  *
  * Based on omap3_beagle.h
  * (C) Copyright 2006-2008
@@ -26,8 +27,7 @@
  *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
+ * Foundation, Inc.
  */
 
 #ifndef __CONFIG_H
-- 
1.7.3.4

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

* [U-Boot] [PATCH 4/9] OMAP3: CM-T35: update MAINTAINERS file
  2011-04-05  7:08 [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
                   ` (2 preceding siblings ...)
  2011-04-05  7:08 ` [U-Boot] [PATCH 3/9] OMAP3: CM-T35: update board files header information Igor Grinberg
@ 2011-04-05  7:08 ` Igor Grinberg
  2011-04-05  7:08 ` [U-Boot] [PATCH 5/9] OMAP3: CM-T35: add MMC1 pinmux Igor Grinberg
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 13+ messages in thread
From: Igor Grinberg @ 2011-04-05  7:08 UTC (permalink / raw)
  To: u-boot


Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
Acked-by: Mike Rapoport <mike@compulab.co.il>
---
 MAINTAINERS |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/MAINTAINERS b/MAINTAINERS
index 4756f14..bcd0fc9 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -646,6 +646,10 @@ Marius Gr
 	impa7		ARM720T (EP7211)
 	ep7312		ARM720T (EP7312)
 
+Igor Grinberg <grinberg@compulab.co.il>
+
+	cm-t35		ARM ARMV7 (OMAP3xx Soc)
+
 Kshitij Gupta <kshitij@ti.com>
 
 	omap1510inn	ARM925T
@@ -763,10 +767,6 @@ Stelian Pop <stelian.pop@leadtechdesign.com>
 	at91sam9263ek	ARM926EJS (AT91SAM9263 SoC)
 	at91sam9rlek	ARM926EJS (AT91SAM9RL SoC)
 
-Mike Rapoport <mike@compulab.co.il>
-
-	cm_t35		ARM ARMV7 (OMAP3xx SoC)
-
 Tom Rix <Tom.Rix@windriver.com>
 
 	omap3_zoom2	ARM ARMV7 (OMAP3xx SoC)
-- 
1.7.3.4

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

* [U-Boot] [PATCH 5/9] OMAP3: CM-T35: add MMC1 pinmux
  2011-04-05  7:08 [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
                   ` (3 preceding siblings ...)
  2011-04-05  7:08 ` [U-Boot] [PATCH 4/9] OMAP3: CM-T35: update MAINTAINERS file Igor Grinberg
@ 2011-04-05  7:08 ` Igor Grinberg
  2011-04-05  7:08 ` [U-Boot] [PATCH 6/9] OMAP3: CM-T35: fix mmc Igor Grinberg
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 13+ messages in thread
From: Igor Grinberg @ 2011-04-05  7:08 UTC (permalink / raw)
  To: u-boot


Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
---
 board/cm_t35/cm_t35.c |   12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)

diff --git a/board/cm_t35/cm_t35.c b/board/cm_t35/cm_t35.c
index 5c8d569..3b6f7ef 100644
--- a/board/cm_t35/cm_t35.c
+++ b/board/cm_t35/cm_t35.c
@@ -258,6 +258,18 @@ void set_muxconf_regs(void)
 	MUX_VAL(CP(JTAG_TCK),		(IEN  | PTD | DIS | M0)); /*JTAG_TCK*/
 	MUX_VAL(CP(JTAG_TMS),		(IEN  | PTD | DIS | M0)); /*JTAG_TMS*/
 	MUX_VAL(CP(JTAG_TDI),		(IEN  | PTD | DIS | M0)); /*JTAG_TDI*/
+
+	/* MMC1 */
+	MUX_VAL(CP(MMC1_CLK),		(IDIS | PTU | EN  | M0)); /*MMC1_CLK*/
+	MUX_VAL(CP(MMC1_CMD),		(IEN  | PTU | EN  | M0)); /*MMC1_CMD*/
+	MUX_VAL(CP(MMC1_DAT0),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT0*/
+	MUX_VAL(CP(MMC1_DAT1),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT1*/
+	MUX_VAL(CP(MMC1_DAT2),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT2*/
+	MUX_VAL(CP(MMC1_DAT3),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT3*/
+	MUX_VAL(CP(MMC1_DAT4),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT4*/
+	MUX_VAL(CP(MMC1_DAT5),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT5*/
+	MUX_VAL(CP(MMC1_DAT6),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT6*/
+	MUX_VAL(CP(MMC1_DAT7),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT7*/
 }
 
 #ifdef CONFIG_GENERIC_MMC
-- 
1.7.3.4

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

* [U-Boot] [PATCH 6/9] OMAP3: CM-T35: fix mmc
  2011-04-05  7:08 [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
                   ` (4 preceding siblings ...)
  2011-04-05  7:08 ` [U-Boot] [PATCH 5/9] OMAP3: CM-T35: add MMC1 pinmux Igor Grinberg
@ 2011-04-05  7:08 ` Igor Grinberg
  2011-04-05  7:08 ` [U-Boot] [PATCH 7/9] OMAP3: CM-T35: remove redundand i2c initialization Igor Grinberg
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 13+ messages in thread
From: Igor Grinberg @ 2011-04-05  7:08 UTC (permalink / raw)
  To: u-boot

Use CONFIG_OMAP3_MMC in cm-t35 configuration file.

Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
---
 board/cm_t35/cm_t35.c    |    7 -------
 include/configs/cm_t35.h |    3 +--
 2 files changed, 1 insertions(+), 9 deletions(-)

diff --git a/board/cm_t35/cm_t35.c b/board/cm_t35/cm_t35.c
index 3b6f7ef..23efacc 100644
--- a/board/cm_t35/cm_t35.c
+++ b/board/cm_t35/cm_t35.c
@@ -272,13 +272,6 @@ void set_muxconf_regs(void)
 	MUX_VAL(CP(MMC1_DAT7),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT7*/
 }
 
-#ifdef CONFIG_GENERIC_MMC
-int board_mmc_init(bd_t *bis)
-{
-	return omap_mmc_init(0);
-}
-#endif
-
 /*
  * Routine: setup_net_chip_gmpc
  * Description: Setting up the configuration GPMC registers specific to the
diff --git a/include/configs/cm_t35.h b/include/configs/cm_t35.h
index 5624abd..3692810 100644
--- a/include/configs/cm_t35.h
+++ b/include/configs/cm_t35.h
@@ -110,9 +110,8 @@
 #define CONFIG_BAUDRATE			115200
 #define CONFIG_SYS_BAUDRATE_TABLE	{4800, 9600, 19200, 38400, 57600,\
 					115200}
-#define CONFIG_GENERIC_MMC		1
 #define CONFIG_MMC			1
-#define CONFIG_OMAP_HSMMC		1
+#define CONFIG_OMAP3_MMC		1
 #define CONFIG_DOS_PARTITION		1
 
 /* DDR - I use Micron DDR */
-- 
1.7.3.4

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

* [U-Boot] [PATCH 7/9] OMAP3: CM-T35: remove redundand i2c initialization
  2011-04-05  7:08 [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
                   ` (5 preceding siblings ...)
  2011-04-05  7:08 ` [U-Boot] [PATCH 6/9] OMAP3: CM-T35: fix mmc Igor Grinberg
@ 2011-04-05  7:08 ` Igor Grinberg
  2011-04-05  7:08 ` [U-Boot] [PATCH 8/9] OMAP3: CM-T35: enable the green LED Igor Grinberg
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 13+ messages in thread
From: Igor Grinberg @ 2011-04-05  7:08 UTC (permalink / raw)
  To: u-boot


Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
---
 board/cm_t35/cm_t35.c |    6 +-----
 1 files changed, 1 insertions(+), 5 deletions(-)

diff --git a/board/cm_t35/cm_t35.c b/board/cm_t35/cm_t35.c
index 23efacc..bf54061 100644
--- a/board/cm_t35/cm_t35.c
+++ b/board/cm_t35/cm_t35.c
@@ -90,14 +90,10 @@ int board_init(void)
 
 /*
  * Routine: misc_init_r
- * Description: Init I2C and display die ID
+ * Description: display die ID
  */
 int misc_init_r(void)
 {
-#ifdef CONFIG_DRIVER_OMAP34XX_I2C
-	i2c_init(CONFIG_SYS_I2C_SPEED, CONFIG_SYS_I2C_SLAVE);
-#endif
-
 	dieid_num_r();
 
 	return 0;
-- 
1.7.3.4

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

* [U-Boot] [PATCH 8/9] OMAP3: CM-T35: enable the green LED
  2011-04-05  7:08 [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
                   ` (6 preceding siblings ...)
  2011-04-05  7:08 ` [U-Boot] [PATCH 7/9] OMAP3: CM-T35: remove redundand i2c initialization Igor Grinberg
@ 2011-04-05  7:08 ` Igor Grinberg
  2011-04-05  7:08 ` [U-Boot] [PATCH 9/9] OMAP3: CM-T35: Add support for CM-T3730 Igor Grinberg
  2011-04-10  6:32 ` [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
  9 siblings, 0 replies; 13+ messages in thread
From: Igor Grinberg @ 2011-04-05  7:08 UTC (permalink / raw)
  To: u-boot


Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
---
 board/cm_t35/Makefile    |    2 +-
 board/cm_t35/cm_t35.c    |    7 ++++++-
 board/cm_t35/leds.c      |   45 +++++++++++++++++++++++++++++++++++++++++++++
 include/configs/cm_t35.h |   15 +++++++++++++++
 4 files changed, 67 insertions(+), 2 deletions(-)
 create mode 100644 board/cm_t35/leds.c

diff --git a/board/cm_t35/Makefile b/board/cm_t35/Makefile
index 862b8dc..83d7a56 100644
--- a/board/cm_t35/Makefile
+++ b/board/cm_t35/Makefile
@@ -25,7 +25,7 @@ include $(TOPDIR)/config.mk
 
 LIB	= $(obj)lib$(BOARD).o
 
-COBJS	:= cm_t35.o
+COBJS	:= cm_t35.o leds.o
 
 SRCS	:= $(COBJS:.o=.c)
 OBJS	:= $(addprefix $(obj),$(COBJS))
diff --git a/board/cm_t35/cm_t35.c b/board/cm_t35/cm_t35.c
index bf54061..cfdc4df 100644
--- a/board/cm_t35/cm_t35.c
+++ b/board/cm_t35/cm_t35.c
@@ -29,6 +29,7 @@
  */
 
 #include <common.h>
+#include <status_led.h>
 #include <netdev.h>
 #include <net.h>
 #include <i2c.h>
@@ -85,6 +86,10 @@ int board_init(void)
 	/* boot param addr */
 	gd->bd->bi_boot_params = (OMAP34XX_SDRC_CS0 + 0x100);
 
+#if defined(CONFIG_STATUS_LED) && defined(STATUS_LED_BOOT)
+	status_led_set(STATUS_LED_BOOT, STATUS_LED_ON);
+#endif
+
 	return 0;
 }
 
@@ -249,7 +254,7 @@ void set_muxconf_regs(void)
 	MUX_VAL(CP(SYS_NIRQ),		(IEN  | PTU | EN  | M0)); /*SYS_nIRQ*/
 	MUX_VAL(CP(SYS_OFF_MODE),	(IEN  | PTD | DIS | M0)); /*OFF_MODE*/
 	MUX_VAL(CP(SYS_CLKOUT1),	(IEN  | PTD | DIS | M0)); /*CLKOUT1*/
-	MUX_VAL(CP(SYS_CLKOUT2),	(IDIS | PTD | DIS | M4)); /*green LED*/
+	MUX_VAL(CP(SYS_CLKOUT2),	(IDIS | PTU | DIS | M4)); /*green LED*/
 	MUX_VAL(CP(JTAG_nTRST),		(IEN  | PTD | DIS | M0)); /*JTAG_nTRST*/
 	MUX_VAL(CP(JTAG_TCK),		(IEN  | PTD | DIS | M0)); /*JTAG_TCK*/
 	MUX_VAL(CP(JTAG_TMS),		(IEN  | PTD | DIS | M0)); /*JTAG_TMS*/
diff --git a/board/cm_t35/leds.c b/board/cm_t35/leds.c
new file mode 100644
index 0000000..71c5b0d
--- /dev/null
+++ b/board/cm_t35/leds.c
@@ -0,0 +1,45 @@
+/*
+ * (C) Copyright 2011
+ * CompuLab, Ltd. <www.compulab.co.il>
+ *
+ * Author: Igor Grinberg <grinberg@compulab.co.il>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc.
+ */
+#include <common.h>
+#include <status_led.h>
+#include <asm/arch/gpio.h>
+
+static unsigned int leds[] = { GREEN_LED_GPIO };
+
+void __led_init(led_id_t mask, int state)
+{
+	if (omap_request_gpio(leds[mask]) != 0) {
+		printf("%s: failed requesting GPIO%u\n", __func__, leds[mask]);
+		return;
+	}
+
+	omap_set_gpio_direction(leds[mask], 0);
+}
+
+void __led_set(led_id_t mask, int state)
+{
+	omap_set_gpio_dataout(leds[mask], state == STATUS_LED_ON);
+}
+
+void __led_toggle(led_id_t mask)
+{
+	omap_set_gpio_dataout(leds[mask], !omap_get_gpio_datain(leds[mask]));
+}
diff --git a/include/configs/cm_t35.h b/include/configs/cm_t35.h
index 3692810..c259640 100644
--- a/include/configs/cm_t35.h
+++ b/include/configs/cm_t35.h
@@ -351,4 +351,19 @@ extern unsigned int boot_flash_type;
 					 CONFIG_SYS_INIT_RAM_SIZE -	\
 					 GENERATED_GBL_DATA_SIZE)
 
+/* Status LED */
+#define CONFIG_STATUS_LED		1 /* Status LED enabled */
+#define CONFIG_BOARD_SPECIFIC_LED	1
+#define STATUS_LED_GREEN		0
+#define STATUS_LED_BIT			STATUS_LED_GREEN
+#define STATUS_LED_STATE		STATUS_LED_ON
+#define STATUS_LED_PERIOD		(CONFIG_SYS_HZ / 2)
+#define STATUS_LED_BOOT			STATUS_LED_BIT
+#define GREEN_LED_GPIO			186 /* CM-T35 Green LED is GPIO186 */
+
+/* GPIO banks */
+#ifdef CONFIG_STATUS_LED
+#define CONFIG_OMAP3_GPIO_6		1 /* GPIO186 is in GPIO bank 6  */
+#endif
+
 #endif /* __CONFIG_H */
-- 
1.7.3.4

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

* [U-Boot] [PATCH 9/9] OMAP3: CM-T35: Add support for CM-T3730
  2011-04-05  7:08 [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
                   ` (7 preceding siblings ...)
  2011-04-05  7:08 ` [U-Boot] [PATCH 8/9] OMAP3: CM-T35: enable the green LED Igor Grinberg
@ 2011-04-05  7:08 ` Igor Grinberg
  2011-04-10  6:32 ` [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
  9 siblings, 0 replies; 13+ messages in thread
From: Igor Grinberg @ 2011-04-05  7:08 UTC (permalink / raw)
  To: u-boot

CM-T3730 is exactly the same board as CM-T35, but it has
TI DM3730 SoC onboard and therefore some changes have to take place

Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
---
 board/cm_t35/cm_t35.c    |   78 ++++++++++++++++++++++++++++++++++-----------
 include/configs/cm_t35.h |   12 +++---
 2 files changed, 65 insertions(+), 25 deletions(-)

diff --git a/board/cm_t35/cm_t35.c b/board/cm_t35/cm_t35.c
index cfdc4df..f82111b 100644
--- a/board/cm_t35/cm_t35.c
+++ b/board/cm_t35/cm_t35.c
@@ -46,7 +46,7 @@ DECLARE_GLOBAL_DATA_PTR;
 
 const omap3_sysinfo sysinfo = {
 	DDR_DISCRETE,
-	"CM-T35 board",
+	"CM-T3x board",
 	"NAND",
 };
 
@@ -82,7 +82,11 @@ int board_init(void)
 			      CONFIG_SYS_NAND_BASE, GPMC_SIZE_16M);
 
 	/* board id for Linux */
-	gd->bd->bi_arch_number = MACH_TYPE_CM_T35;
+	if (get_cpu_family() == CPU_OMAP34XX)
+		gd->bd->bi_arch_number = MACH_TYPE_CM_T35;
+	else
+		gd->bd->bi_arch_number = MACH_TYPE_CM_T3730;
+
 	/* boot param addr */
 	gd->bd->bi_boot_params = (OMAP34XX_SDRC_CS0 + 0x100);
 
@@ -110,7 +114,7 @@ int misc_init_r(void)
  *		hardware. Many pins need to be moved from protect to primary
  *		mode.
  */
-void set_muxconf_regs(void)
+static void cm_t3x_set_common_muxconf(void)
 {
 	/* SDRC */
 	MUX_VAL(CP(SDRC_D0),		(IEN  | PTD | DIS | M0)); /*SDRC_D0*/
@@ -185,7 +189,7 @@ void set_muxconf_regs(void)
 	/* SB-T35 Ethernet */
 	MUX_VAL(CP(GPMC_NCS4),		(IEN  | PTU | EN  | M0)); /*GPMC_nCS4*/
 
-	/* CM-T35 Ethernet */
+	/* CM-T3x Ethernet */
 	MUX_VAL(CP(GPMC_NCS5),		(IDIS | PTU | DIS | M0)); /*GPMC_nCS5*/
 	MUX_VAL(CP(GPMC_CLK),		(IEN  | PTD | DIS | M4)); /*GPIO_59*/
 	MUX_VAL(CP(GPMC_NADV_ALE),	(IDIS | PTD | DIS | M0)); /*nADV_ALE*/
@@ -201,12 +205,6 @@ void set_muxconf_regs(void)
 	MUX_VAL(CP(DSS_HSYNC),		(IDIS | PTD | DIS | M0)); /*DSS_HSYNC*/
 	MUX_VAL(CP(DSS_VSYNC),		(IDIS | PTD | DIS | M0)); /*DSS_VSYNC*/
 	MUX_VAL(CP(DSS_ACBIAS),		(IDIS | PTD | DIS | M0)); /*DSS_ACBIAS*/
-	MUX_VAL(CP(DSS_DATA0),		(IDIS | PTD | DIS | M0)); /*DSS_DATA0*/
-	MUX_VAL(CP(DSS_DATA1),		(IDIS | PTD | DIS | M0)); /*DSS_DATA1*/
-	MUX_VAL(CP(DSS_DATA2),		(IDIS | PTD | DIS | M0)); /*DSS_DATA2*/
-	MUX_VAL(CP(DSS_DATA3),		(IDIS | PTD | DIS | M0)); /*DSS_DATA3*/
-	MUX_VAL(CP(DSS_DATA4),		(IDIS | PTD | DIS | M0)); /*DSS_DATA4*/
-	MUX_VAL(CP(DSS_DATA5),		(IDIS | PTD | DIS | M0)); /*DSS_DATA5*/
 	MUX_VAL(CP(DSS_DATA6),		(IDIS | PTD | DIS | M0)); /*DSS_DATA6*/
 	MUX_VAL(CP(DSS_DATA7),		(IDIS | PTD | DIS | M0)); /*DSS_DATA7*/
 	MUX_VAL(CP(DSS_DATA8),		(IDIS | PTD | DIS | M0)); /*DSS_DATA8*/
@@ -219,12 +217,6 @@ void set_muxconf_regs(void)
 	MUX_VAL(CP(DSS_DATA15),		(IDIS | PTD | DIS | M0)); /*DSS_DATA15*/
 	MUX_VAL(CP(DSS_DATA16),		(IDIS | PTD | DIS | M0)); /*DSS_DATA16*/
 	MUX_VAL(CP(DSS_DATA17),		(IDIS | PTD | DIS | M0)); /*DSS_DATA17*/
-	MUX_VAL(CP(DSS_DATA18),		(IDIS | PTD | DIS | M0)); /*DSS_DATA18*/
-	MUX_VAL(CP(DSS_DATA19),		(IDIS | PTD | DIS | M0)); /*DSS_DATA19*/
-	MUX_VAL(CP(DSS_DATA20),		(IDIS | PTD | DIS | M0)); /*DSS_DATA20*/
-	MUX_VAL(CP(DSS_DATA21),		(IDIS | PTD | DIS | M0)); /*DSS_DATA21*/
-	MUX_VAL(CP(DSS_DATA22),		(IDIS | PTD | DIS | M0)); /*DSS_DATA22*/
-	MUX_VAL(CP(DSS_DATA23),		(IDIS | PTD | DIS | M0)); /*DSS_DATA23*/
 
 	/* serial interface */
 	MUX_VAL(CP(UART3_RX_IRRX),	(IEN  | PTD | DIS | M0)); /*UART3_RX*/
@@ -267,12 +259,60 @@ void set_muxconf_regs(void)
 	MUX_VAL(CP(MMC1_DAT1),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT1*/
 	MUX_VAL(CP(MMC1_DAT2),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT2*/
 	MUX_VAL(CP(MMC1_DAT3),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT3*/
+}
+
+static void cm_t35_set_muxconf(void)
+{
+	/* DSS */
+	MUX_VAL(CP(DSS_DATA0),		(IDIS | PTD | DIS | M0)); /*DSS_DATA0*/
+	MUX_VAL(CP(DSS_DATA1),		(IDIS | PTD | DIS | M0)); /*DSS_DATA1*/
+	MUX_VAL(CP(DSS_DATA2),		(IDIS | PTD | DIS | M0)); /*DSS_DATA2*/
+	MUX_VAL(CP(DSS_DATA3),		(IDIS | PTD | DIS | M0)); /*DSS_DATA3*/
+	MUX_VAL(CP(DSS_DATA4),		(IDIS | PTD | DIS | M0)); /*DSS_DATA4*/
+	MUX_VAL(CP(DSS_DATA5),		(IDIS | PTD | DIS | M0)); /*DSS_DATA5*/
+
+	MUX_VAL(CP(DSS_DATA18),         (IDIS | PTD | DIS | M0)); /*DSS_DATA18*/
+	MUX_VAL(CP(DSS_DATA19),         (IDIS | PTD | DIS | M0)); /*DSS_DATA19*/
+	MUX_VAL(CP(DSS_DATA20),         (IDIS | PTD | DIS | M0)); /*DSS_DATA20*/
+	MUX_VAL(CP(DSS_DATA21),         (IDIS | PTD | DIS | M0)); /*DSS_DATA21*/
+	MUX_VAL(CP(DSS_DATA22),         (IDIS | PTD | DIS | M0)); /*DSS_DATA22*/
+	MUX_VAL(CP(DSS_DATA23),         (IDIS | PTD | DIS | M0)); /*DSS_DATA23*/
+
+	/* MMC1 */
 	MUX_VAL(CP(MMC1_DAT4),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT4*/
 	MUX_VAL(CP(MMC1_DAT5),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT5*/
 	MUX_VAL(CP(MMC1_DAT6),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT6*/
 	MUX_VAL(CP(MMC1_DAT7),		(IEN  | PTU | EN  | M0)); /*MMC1_DAT7*/
 }
 
+static void cm_t3730_set_muxconf(void)
+{
+	/* DSS */
+	MUX_VAL(CP(DSS_DATA18),		(IDIS | PTD | DIS | M3)); /*DSS_DATA0*/
+	MUX_VAL(CP(DSS_DATA19),		(IDIS | PTD | DIS | M3)); /*DSS_DATA1*/
+	MUX_VAL(CP(DSS_DATA20),		(IDIS | PTD | DIS | M3)); /*DSS_DATA2*/
+	MUX_VAL(CP(DSS_DATA21),		(IDIS | PTD | DIS | M3)); /*DSS_DATA3*/
+	MUX_VAL(CP(DSS_DATA22),		(IDIS | PTD | DIS | M3)); /*DSS_DATA4*/
+	MUX_VAL(CP(DSS_DATA23),		(IDIS | PTD | DIS | M3)); /*DSS_DATA5*/
+
+	MUX_VAL(CP(SYS_BOOT0),		(IDIS | PTD | DIS | M3)); /*DSS_DATA18*/
+	MUX_VAL(CP(SYS_BOOT1),		(IDIS | PTD | DIS | M3)); /*DSS_DATA19*/
+	MUX_VAL(CP(SYS_BOOT3),		(IDIS | PTD | DIS | M3)); /*DSS_DATA20*/
+	MUX_VAL(CP(SYS_BOOT4),		(IDIS | PTD | DIS | M3)); /*DSS_DATA21*/
+	MUX_VAL(CP(SYS_BOOT5),		(IDIS | PTD | DIS | M3)); /*DSS_DATA22*/
+	MUX_VAL(CP(SYS_BOOT6),		(IDIS | PTD | DIS | M3)); /*DSS_DATA23*/
+}
+
+void set_muxconf_regs(void)
+{
+	cm_t3x_set_common_muxconf();
+
+	if (get_cpu_family() == CPU_OMAP34XX)
+		cm_t35_set_muxconf();
+	else
+		cm_t3730_set_muxconf();
+}
+
 /*
  * Routine: setup_net_chip_gmpc
  * Description: Setting up the configuration GPMC registers specific to the
@@ -283,7 +323,7 @@ static void setup_net_chip_gmpc(void)
 	struct ctrl *ctrl_base = (struct ctrl *)OMAP34XX_CTRL_BASE;
 
 	enable_gpmc_cs_config(gpmc_net_config, &gpmc_cfg->cs[5],
-			      CM_T35_SMC911X_BASE, GPMC_SIZE_16M);
+			      CM_T3X_SMC911X_BASE, GPMC_SIZE_16M);
 	enable_gpmc_cs_config(gpmc_net_config, &gpmc_cfg->cs[4],
 			      SB_T35_SMC911X_BASE, GPMC_SIZE_16M);
 
@@ -362,9 +402,9 @@ int board_eth_init(bd_t *bis)
 
 	rc1 = handle_mac_address();
 	if (rc1)
-		printf("CM-T35: No MAC address found\n");
+		printf("CM-T3x: No MAC address found\n");
 
-	rc1 = smc911x_initialize(0, CM_T35_SMC911X_BASE);
+	rc1 = smc911x_initialize(0, CM_T3X_SMC911X_BASE);
 	if (rc1 > 0)
 		rc++;
 
diff --git a/include/configs/cm_t35.h b/include/configs/cm_t35.h
index c259640..b8dffbb 100644
--- a/include/configs/cm_t35.h
+++ b/include/configs/cm_t35.h
@@ -10,7 +10,7 @@
  * Richard Woodruff <r-woodruff2@ti.com>
  * Syed Mohammed Khasim <x0khasim@ti.com>
  *
- * Configuration settings for the CompuLab CM-T35 board
+ * Configuration settings for the CompuLab CM-T35 and CM-T3730 boards
  *
  * See file CREDITS for list of people who contributed to this
  * project.
@@ -40,7 +40,7 @@
 #define CONFIG_OMAP		1	/* in a TI OMAP core */
 #define CONFIG_OMAP34XX		1	/* which is a 34XX */
 #define CONFIG_OMAP3430		1	/* which is in a 3430 */
-#define CONFIG_CM_T35		1	/* working with CM-T35 */
+#define CONFIG_CM_T3X		1	/* working with CM-T35 and CM-T3730 */
 
 #define CONFIG_SYS_TEXT_BASE	0x80008000
 
@@ -253,7 +253,7 @@
 #define CONFIG_SYS_LONGHELP		/* undef to save memory */
 #define CONFIG_SYS_HUSH_PARSER		/* use "hush" command parser */
 #define CONFIG_SYS_PROMPT_HUSH_PS2	"> "
-#define CONFIG_SYS_PROMPT		"CM-T35 # "
+#define CONFIG_SYS_PROMPT		"CM-T3x # "
 #define CONFIG_SYS_CBSIZE		256	/* Console I/O Buffer Size */
 /* Print Buffer Size */
 #define CONFIG_SYS_PBSIZE		(CONFIG_SYS_CBSIZE + \
@@ -338,9 +338,9 @@ extern unsigned int boot_flash_type;
 #define CONFIG_NET_MULTI
 #define CONFIG_SMC911X
 #define CONFIG_SMC911X_32_BIT
-#define CM_T35_SMC911X_BASE	0x2C000000
-#define SB_T35_SMC911X_BASE	(CM_T35_SMC911X_BASE + (16 << 20))
-#define CONFIG_SMC911X_BASE	CM_T35_SMC911X_BASE
+#define CM_T3X_SMC911X_BASE	0x2C000000
+#define SB_T35_SMC911X_BASE	(CM_T3X_SMC911X_BASE + (16 << 20))
+#define CONFIG_SMC911X_BASE	CM_T3X_SMC911X_BASE
 #endif /* (CONFIG_CMD_NET) */
 
 /* additions for new relocation code, must be added to all boards */
-- 
1.7.3.4

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

* [U-Boot] [PATCH 0/9] Update support for CM-T35
  2011-04-05  7:08 [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
                   ` (8 preceding siblings ...)
  2011-04-05  7:08 ` [U-Boot] [PATCH 9/9] OMAP3: CM-T35: Add support for CM-T3730 Igor Grinberg
@ 2011-04-10  6:32 ` Igor Grinberg
  2011-04-17  6:01   ` Igor Grinberg
  9 siblings, 1 reply; 13+ messages in thread
From: Igor Grinberg @ 2011-04-10  6:32 UTC (permalink / raw)
  To: u-boot

Ping!


Wolfgang,


should I have also send this to Albert or/and Sandeep?



On 04/05/11 10:08, Igor Grinberg wrote:

> This patch serie s based on the latest U-Boot release (v2011.03) and
> updates support for Compulab CM-T35 board:
> 1) Some clean up
> 2) MMC/SD Card fix
> 3) Add Green Status LED
> 4) Add support for CM-T3730 which is basically the same board, but
>    has TI's DM3730 SoC and therefore some changes are required
>
> Igor Grinberg (9):
>   OMAP3: CM-T35: Move DECLARE_GLOBAL_DATA_PTR to file scope
>   OMAP3: CM-T35: update config
>   OMAP3: CM-T35: update board files header information
>   OMAP3: CM-T35: update MAINTAINERS file
>   OMAP3: CM-T35: add MMC1 pinmux
>   OMAP3: CM-T35: fix mmc
>   OMAP3: CM-T35: remove redundand i2c initialization
>   OMAP3: CM-T35: enable the green LED
>   OMAP3: CM-T35: Add support for CM-T3730
>
>  MAINTAINERS              |    8 ++--
>  board/cm_t35/Makefile    |    2 +-
>  board/cm_t35/cm_t35.c    |  116 ++++++++++++++++++++++++++++++++--------------
>  board/cm_t35/leds.c      |   45 ++++++++++++++++++
>  include/configs/cm_t35.h |   41 +++++++++++-----
>  5 files changed, 160 insertions(+), 52 deletions(-)
>  create mode 100644 board/cm_t35/leds.c
>

-- 
Regards,
Igor.

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

* [U-Boot] [PATCH 0/9] Update support for CM-T35
  2011-04-10  6:32 ` [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
@ 2011-04-17  6:01   ` Igor Grinberg
  2011-04-18 21:56     ` Paulraj, Sandeep
  0 siblings, 1 reply; 13+ messages in thread
From: Igor Grinberg @ 2011-04-17  6:01 UTC (permalink / raw)
  To: u-boot

Hi Wolfgang, Albert, Sandeep,


On 04/10/11 09:32, Igor Grinberg wrote:
> Ping!
>
>
> Wolfgang,
>
>
> should I have also send this to Albert or/and Sandeep?
>
>
>
> On 04/05/11 10:08, Igor Grinberg wrote:
>
>> This patch serie s based on the latest U-Boot release (v2011.03) and
>> updates support for Compulab CM-T35 board:
>> 1) Some clean up
>> 2) MMC/SD Card fix
>> 3) Add Green Status LED
>> 4) Add support for CM-T3730 which is basically the same board, but
>>    has TI's DM3730 SoC and therefore some changes are required
>>
>> Igor Grinberg (9):
>>   OMAP3: CM-T35: Move DECLARE_GLOBAL_DATA_PTR to file scope
>>   OMAP3: CM-T35: update config
>>   OMAP3: CM-T35: update board files header information
>>   OMAP3: CM-T35: update MAINTAINERS file
>>   OMAP3: CM-T35: add MMC1 pinmux
>>   OMAP3: CM-T35: fix mmc
>>   OMAP3: CM-T35: remove redundand i2c initialization
>>   OMAP3: CM-T35: enable the green LED
>>   OMAP3: CM-T35: Add support for CM-T3730
>>
>>  MAINTAINERS              |    8 ++--
>>  board/cm_t35/Makefile    |    2 +-
>>  board/cm_t35/cm_t35.c    |  116 ++++++++++++++++++++++++++++++++--------------
>>  board/cm_t35/leds.c      |   45 ++++++++++++++++++
>>  include/configs/cm_t35.h |   41 +++++++++++-----
>>  5 files changed, 160 insertions(+), 52 deletions(-)
>>  create mode 100644 board/cm_t35/leds.c

It has been almost two weeks...
Do you have any comments?
If not, then who should take these in?

-- 
Regards,
Igor.

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

* [U-Boot] [PATCH 0/9] Update support for CM-T35
  2011-04-17  6:01   ` Igor Grinberg
@ 2011-04-18 21:56     ` Paulraj, Sandeep
  0 siblings, 0 replies; 13+ messages in thread
From: Paulraj, Sandeep @ 2011-04-18 21:56 UTC (permalink / raw)
  To: u-boot



> >
> >> This patch serie s based on the latest U-Boot release (v2011.03) and
> >> updates support for Compulab CM-T35 board:
> >> 1) Some clean up
> >> 2) MMC/SD Card fix
> >> 3) Add Green Status LED
> >> 4) Add support for CM-T3730 which is basically the same board, but
> >>    has TI's DM3730 SoC and therefore some changes are required
> >>
> >> Igor Grinberg (9):
> >>   OMAP3: CM-T35: Move DECLARE_GLOBAL_DATA_PTR to file scope
> >>   OMAP3: CM-T35: update config
> >>   OMAP3: CM-T35: update board files header information
> >>   OMAP3: CM-T35: update MAINTAINERS file
> >>   OMAP3: CM-T35: add MMC1 pinmux
> >>   OMAP3: CM-T35: fix mmc
> >>   OMAP3: CM-T35: remove redundand i2c initialization
> >>   OMAP3: CM-T35: enable the green LED
> >>   OMAP3: CM-T35: Add support for CM-T3730
> >>
> >>  MAINTAINERS              |    8 ++--
> >>  board/cm_t35/Makefile    |    2 +-
> >>  board/cm_t35/cm_t35.c    |  116 ++++++++++++++++++++++++++++++++------
> --------

Thanks

Pushed the series

--Sandeep

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

end of thread, other threads:[~2011-04-18 21:56 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-04-05  7:08 [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
2011-04-05  7:08 ` [U-Boot] [PATCH 1/9] OMAP3: CM-T35: Move DECLARE_GLOBAL_DATA_PTR to file scope Igor Grinberg
2011-04-05  7:08 ` [U-Boot] [PATCH 2/9] OMAP3: CM-T35: update config Igor Grinberg
2011-04-05  7:08 ` [U-Boot] [PATCH 3/9] OMAP3: CM-T35: update board files header information Igor Grinberg
2011-04-05  7:08 ` [U-Boot] [PATCH 4/9] OMAP3: CM-T35: update MAINTAINERS file Igor Grinberg
2011-04-05  7:08 ` [U-Boot] [PATCH 5/9] OMAP3: CM-T35: add MMC1 pinmux Igor Grinberg
2011-04-05  7:08 ` [U-Boot] [PATCH 6/9] OMAP3: CM-T35: fix mmc Igor Grinberg
2011-04-05  7:08 ` [U-Boot] [PATCH 7/9] OMAP3: CM-T35: remove redundand i2c initialization Igor Grinberg
2011-04-05  7:08 ` [U-Boot] [PATCH 8/9] OMAP3: CM-T35: enable the green LED Igor Grinberg
2011-04-05  7:08 ` [U-Boot] [PATCH 9/9] OMAP3: CM-T35: Add support for CM-T3730 Igor Grinberg
2011-04-10  6:32 ` [U-Boot] [PATCH 0/9] Update support for CM-T35 Igor Grinberg
2011-04-17  6:01   ` Igor Grinberg
2011-04-18 21:56     ` Paulraj, Sandeep

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox