Skip to contentSkip to conversation

OMAP Consolidate common u-boot.lds to cpu layer.

PATCH New Tom Rix 2 participants 16 messages May 7, 2009 – May 16, 2009 Kbuild

lore
Share & tools
lore

Tom Rix

author
#0 lore raw

PATCH 1/6 OMAP Consolidate common u-boot.lds to cpu layer.

The u-boot.lds file is common for all omap boards.
Move a cleaned up version to the cpu layer and add makefile logic to use it.

---
 board/omap3/beagle/u-boot.lds     |   63 -------------------------------------
 board/omap3/evm/u-boot.lds        |   63 -------------------------------------
 board/omap3/overo/u-boot.lds      |   63 -------------------------------------
 board/omap3/pandora/u-boot.lds    |   63 -------------------------------------
 board/omap3/zoom1/u-boot.lds      |   63 -------------------------------------
 cpu/arm_cortexa8/omap3/config.mk  |    2 +
 cpu/arm_cortexa8/omap3/u-boot.lds |   58 ++++++++++++++++++++++++++++++++++
 7 files changed, 60 insertions(+), 315 deletions(-)
 delete mode 100644 board/omap3/beagle/u-boot.lds
 delete mode 100644 board/omap3/evm/u-boot.lds
 delete mode 100644 board/omap3/overo/u-boot.lds
 delete mode 100644 board/omap3/pandora/u-boot.lds
 delete mode 100644 board/omap3/zoom1/u-boot.lds
 create mode 100644 cpu/arm_cortexa8/omap3/u-boot.lds
board/omap3/beagle/u-boot.lds deleted +0 -63
deleted file mode 100644
index 66a8925..0000000
@@ -1,63 +0,0 @@
-/*
- * January 2004 - Changed to support H4 device
- * Copyright (c) 2004 Texas Instruments
- *
- * (C) Copyright 2002
- * Gary Jennejohn, DENX Software Engineering, <[email protected]>
- *
- * See file CREDITS for list of people who contributed to this
- * project.
- *
- * 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., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
- */
-
-OUTPUT_FORMAT("elf32-littlearm", "elf32-littlearm", "elf32-littlearm")
-OUTPUT_ARCH(arm)
-ENTRY(_start)
-SECTIONS
-{
-	. = 0x00000000;
-
-	. = ALIGN(4);
-	.text	:
-	{
-		cpu/arm_cortexa8/start.o	(.text)
-		*(.text)
-	}
-
-	. = ALIGN(4);
-	.rodata : { *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*))) }
-
-	.ARM.extab	: { *(.ARM.extab* .gnu.linkonce.armextab.*) }
-	__exidx_start = .;
-	.ARM.exidx	: { *(.ARM.exidx* .gnu.linkonce.armexidx.*) }
-	__exidx_end = .;
-
-	. = ALIGN(4);
-	.data : { *(.data) }
-
-	. = ALIGN(4);
-	.got : { *(.got) }
-
-	__u_boot_cmd_start = .;
-	.u_boot_cmd : { *(.u_boot_cmd) }
-	__u_boot_cmd_end = .;
-
-	. = ALIGN(4);
-	__bss_start = .;
-	.bss : { *(.bss) }
-	_end = .;
-}
board/omap3/evm/u-boot.lds deleted +0 -63

63 lines not on this page · raw message

board/omap3/overo/u-boot.lds deleted +0 -63

63 lines not on this page · raw message

board/omap3/pandora/u-boot.lds deleted +0 -63

63 lines not on this page · raw message

board/omap3/zoom1/u-boot.lds deleted +0 -63

63 lines not on this page · raw message

cpu/arm_cortexa8/omap3/config.mk +2 -0
index fbb753e..7fd364e 100644
@@ -34,3 +34,5 @@ PLATFORM_CPPFLAGS +=$(call cc-option)
 PLATFORM_CPPFLAGS +=$(call cc-option,-mno-thumb-interwork,)
 PLATFORM_RELFLAGS +=$(call cc-option,-mshort-load-bytes,\
 		    $(call cc-option,-malignment-traps,))
+
+LDSCRIPT := $(SRCTREE)/cpu/arm_cortexa8/omap3/u-boot.lds
cpu/arm_cortexa8/omap3/u-boot.lds new file +58 -0

58 lines not on this page · raw message

Signature · 1 line
1.6.0.5
author
#1 lore raw

PATCH 2/6 ZOOM2 Add initial support for Zoom2

Zoom2 is a new board from Texas Instruments and LogicPD

The logicpd web site is a good source for general information on this board. Please start looking here if the below links are broken.
http://www.logicpd.com

This is a pdf of the product
http://www.logicpd.com/sites/default/files/1012659A_Zoom_OMAP34x-II_MDP_Brief.pdf
This is the product description web page
http://www.logicpd.com/products/development-kits/texas-instruments-zoom%E2%84%A2-omap34x-ii-mdp

This patch provides a zoom2 base target by copying zoom1 and by making some obvious changes.

To configure, run
make omap3_zoom2_config

---
 MAINTAINERS                   |    4 +
 MAKEALL                       |    1 +
 Makefile                      |    3 +
 board/omap3/common/Makefile   |    1 +
 board/omap3/zoom2/Makefile    |   49 +++++++++
 board/omap3/zoom2/config.mk   |   33 ++++++
 board/omap3/zoom2/zoom2.c     |   76 ++++++++++++++
 board/omap3/zoom2/zoom2.h     |  149 +++++++++++++++++++++++++++
 doc/README.omap3              |   15 +++-
 include/configs/omap3_zoom2.h |  226 +++++++++++++++++++++++++++++++++++++++++
 10 files changed, 555 insertions(+), 2 deletions(-)
 create mode 100644 board/omap3/zoom2/Makefile
 create mode 100644 board/omap3/zoom2/config.mk
 create mode 100644 board/omap3/zoom2/zoom2.c
 create mode 100644 board/omap3/zoom2/zoom2.h
 create mode 100644 include/configs/omap3_zoom2.h
MAINTAINERS +4 -0
index 6bb03b4..e19fd0f 100644
@@ -615,6 +615,10 @@ Stelian Pop <[email protected]>
 	at91sam9263ek	ARM926EJS (AT91SAM9263 SoC)
 	at91sam9rlek	ARM926EJS (AT91SAM9RL SoC)
 
+Tom Rix <[email protected]>
+
+	omap3_zoom2	ARM CORTEX-A8 (OMAP3xx SoC)
+
 Stefan Roese <[email protected]>
 
 	ixdpg425	xscale
MAKEALL +1 -0
index f13c81a..46a96c0 100755
@@ -561,6 +561,7 @@ LIST_ARM_CORTEX_A8="		\
 	omap3_evm		\
 	omap3_pandora		\
 	omap3_zoom1		\
+	omap3_zoom2		\
 "
 
 #########################################################################
Makefile +3 -0
index 137c88f..9d107e6 100644
@@ -2983,6 +2983,9 @@ omap3_pandora_config :	unconfig
 omap3_zoom1_config :	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm_cortexa8 zoom1 omap3 omap3
 
+omap3_zoom2_config :	unconfig
+	@$(MKCONFIG) $(@:_config=) arm arm_cortexa8 zoom2 omap3 omap3
+
 #########################################################################
 ## XScale Systems
 #########################################################################
board/omap3/common/Makefile +1 -0
index 7b892fa..b8a0b14 100644
@@ -33,6 +33,7 @@ COBJS-$(CONFIG_OMAP3_BEAGLE) += power.o
 COBJS-$(CONFIG_OMAP3_OVERO) += power.o
 COBJS-$(CONFIG_OMAP3_PANDORA) += power.o
 COBJS-$(CONFIG_OMAP3_ZOOM1) += power.o
+COBJS-$(CONFIG_OMAP3_ZOOM2) += power.o
 
 COBJS	:= $(COBJS-y)
 SRCS	:= $(COBJS:.o=.c)
board/omap3/zoom2/Makefile new file +49 -0

49 lines not on this page · raw message

board/omap3/zoom2/config.mk new file +33 -0
new file mode 100644
index 0000000..33f394b
@@ -0,0 +1,33 @@
+#
+# (C) Copyright 2009
+# Texas Instruments, <www.ti.com>
+#
+# Zoom II uses OMAP3 (ARM-CortexA8) CPU
+# see http://www.ti.com/ for more information on Texas Instruments
+#
+# See file CREDITS for list of people who contributed to this
+# project.
+#
+# 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., 59 Temple Place, Suite 330, Boston,
+# MA 02111-1307 USA
+#
+# Physical Address:
+# 0x80000000 (bank0)
+# 0xA0000000 (bank1)
+# Linux-Kernel is expected to be at 0x80008000, entry 0x80008000
+# (mem base + reserved)
+
+# For use with external or internal boots.
+TEXT_BASE = 0x80e80000
board/omap3/zoom2/zoom2.c new file +76 -0

76 lines not on this page · raw message

board/omap3/zoom2/zoom2.h new file +149 -0

149 lines not on this page · raw message

doc/README.omap3 +13 -2
index 1ba307f..9ab0979 100644
@@ -19,6 +19,8 @@ Currently the following boards are supported:
 
 * TI/Logic PD Zoom MDK [6]
 
+* TI/Logic PD Zoom 2 [7]
+
 Toolchain
 =========
 
@@ -54,6 +56,11 @@ make
 make omap3_zoom1_config
 make
 
+* Zoom 2:
+
+make omap3_zoom2_config
+make
+
 Custom commands
 ===============
 
@@ -80,7 +87,7 @@ help
 Acknowledgements
 ================
 
-OMAP3 U-Boot is based on U-Boot tar ball [7] for BeagleBoard and EVM done by
+OMAP3 U-Boot is based on U-Boot tar ball [8] for BeagleBoard and EVM done by
 several TI employees.
 
 Links
@@ -111,6 +118,10 @@ http://openpandora.org/
 
 http://www.logicpd.com/products/devkit/ti/zoom_mobile_development_kit
 
-[7] TI OMAP3 U-Boot:
+[7] TI/Logic PD Zoom 2
+
+http://www.logicpd.com/sites/default/files/1012659A_Zoom_OMAP34x-II_MDP_Brief.pdf
+[8] TI OMAP3 U-Boot:
 
 http://beagleboard.googlecode.com/files/u-boot_beagle_revb.tar.gz
+
include/configs/omap3_zoom2.h new file +226 -0

226 lines not on this page · raw message

Signature · 1 line
1.6.0.5
author
#2 lore raw

PATCH 3/6 OMAP3 Port kernel omap gpio interface.

Port the linux kernel's omap gpio interface to u-boot. The orignal source is in linux/arch/arm/plat-omap/gpio.c

See doc/README.omap3 for instructions on use.

---
 cpu/arm_cortexa8/omap3/Makefile   |    1 +
 cpu/arm_cortexa8/omap3/gpio.c     |  185 +++++++++++++++++++++++++++++++++++++
 doc/README.omap3                  |   32 +++++++
 include/asm-arm/arch-omap3/gpio.h |   86 +++++++++++++++++
 4 files changed, 304 insertions(+), 0 deletions(-)
 create mode 100644 cpu/arm_cortexa8/omap3/gpio.c
 create mode 100644 include/asm-arm/arch-omap3/gpio.h
cpu/arm_cortexa8/omap3/Makefile +1 -0
index edf5cb2..50176ee 100644
@@ -29,6 +29,7 @@ SOBJS	:= lowlevel_init.o
 
 COBJS	+= board.o
 COBJS	+= clock.o
+COBJS	+= gpio.o
 COBJS	+= mem.o
 COBJS	+= syslib.o
 COBJS	+= sys_info.o
cpu/arm_cortexa8/omap3/gpio.c new file +185 -0

185 lines not on this page · raw message

doc/README.omap3 +32 -0
index 9ab0979..e05e816 100644
@@ -84,6 +84,38 @@ For all other commands see
 
 help
 
+Interfaces
+==========
+
+gpio
+
+To set a bit :
+
+	if (!omap_request_gpio(N)) {
+		omap_set_gpio_direction(N, 0);
+		omap_set_gpio_dataout(N, 1);
+	}
+
+To clear a bit :
+
+	if (!omap_request_gpio(N)) {
+		omap_set_gpio_direction(N, 0);
+		omap_set_gpio_dataout(N, 0);
+	}
+
+To read a bit :
+
+	if (!omap_request_gpio(N)) {
+		omap_set_gpio_direction(NULL, 1);
+		val = omap_get_gpio_datain(N);
+		omap_free_gpio(N);
+	}
+	if (val)
+		printf("GPIO N is set\n");
+	else
+		printf("GPIO N is clear\n");
+
+
 Acknowledgements
 ================
 
include/asm-arm/arch-omap3/gpio.h new file +86 -0

86 lines not on this page · raw message

Signature · 1 line
1.6.0.5
author
#3 lore raw

PATCH 4/6 ZOOM2 Add support for debug board detection.

The logicpd web site is a good source for general information on this board. Please start looking here if the below links are broken.
http://www.logicpd.com

This is a pdf of the product
http://www.logicpd.com/sites/default/files/1012659A_Zoom_OMAP34x-II_MDP_Brief.pdf

This is a pdf of the product quick start guide.
The debug board is described here.
http://support.logicpd.com/downloads/1165/

This is a wiki showing the debug board in use
https://omapzoom.org/gf/project/omapzoom/wiki/?pagename=GettingStartedWithZoomII_AKA_OMAP34XII_MDP

The zoom2 has an auxillary board that contains the serial, net, jtag and battery simulator. This change supports a runtime check if the debug board is connected.

---
 board/omap3/zoom2/Makefile      |    3 +-
 board/omap3/zoom2/debug_board.c |   59 +++++++++++++++++++++++++++++++++++++++
 2 files changed, 61 insertions(+), 1 deletions(-)
 create mode 100644 board/omap3/zoom2/debug_board.c
board/omap3/zoom2/Makefile +2 -1
index 088b8cb..b8fa5a7 100644
@@ -25,7 +25,8 @@ include $(TOPDIR)/config.mk
 
 LIB	= $(obj)lib$(BOARD).a
 
-COBJS	:= zoom2.o
+COBJS	:= zoom2.o \
+	debug_board.o
 
 SRCS	:= $(COBJS:.o=.c)
 OBJS	:= $(addprefix $(obj),$(COBJS))
board/omap3/zoom2/debug_board.c new file +59 -0

59 lines not on this page · raw message

Signature · 1 line
1.6.0.5
author
#4 lore raw

PATCH 5/6 ZOOM2 Add serial support.

Zoom2 serial is in general supplied by one of the 4 UARTS on the debug board. The default serial is from the USB connector on left side of the debug board. The USB connector will produce 2 of the 4 UARTS. On your host pick the first enumeration.

The serial port set up is the same with Zoom1.
Baud rate 115200, 8 bit data, no parity, 1 stop bit, no flow.

The kernel bootargs are
console=ttyS3,115200n8

---
 board/omap3/zoom2/Makefile       |    3 +-
 board/omap3/zoom2/zoom2.c        |   35 ++++++++++
 board/omap3/zoom2/zoom2_serial.c |  130 ++++++++++++++++++++++++++++++++++++++
 board/omap3/zoom2/zoom2_serial.h |   75 ++++++++++++++++++++++
 common/serial.c                  |    2 +
 drivers/serial/ns16550.c         |    4 +-
 include/configs/omap3_zoom2.h    |   26 ++++----
 include/serial.h                 |    7 ++
 8 files changed, 266 insertions(+), 16 deletions(-)
 create mode 100644 board/omap3/zoom2/zoom2_serial.c
 create mode 100644 board/omap3/zoom2/zoom2_serial.h
board/omap3/zoom2/Makefile +2 -1
index b8fa5a7..d27990c 100644
@@ -26,7 +26,8 @@ include $(TOPDIR)/config.mk
 LIB	= $(obj)lib$(BOARD).a
 
 COBJS	:= zoom2.o \
-	debug_board.o
+	debug_board.o \
+	zoom2_serial.o
 
 SRCS	:= $(COBJS:.o=.c)
 OBJS	:= $(addprefix $(obj),$(COBJS))
board/omap3/zoom2/zoom2.c +35 -0
index 0700c56..dd0086c 100644
@@ -30,10 +30,29 @@
  */
 #include <common.h>
 #include <asm/io.h>
+#include <asm/arch/mem.h>
 #include <asm/arch/mux.h>
 #include <asm/arch/sys_proto.h>
 #include <asm/mach-types.h>
 #include "zoom2.h"
+#include "zoom2_serial.h"
+
+/*
+ * This the the zoom2, board specific, gpmc configuration for the
+ * quad uart on the debug board.   The more general gpmc configurations
+ * are setup at the cpu level in cpu/arm_cortexa8/omap3/mem.c
+ */
+extern void enable_gpmc_config(u32 *gpmc_config, gpmc_csx_t *gpmc_cs_base,
+			       u32 base, u32 size);
+
+static u32 gpmc_serial_TL16CP754C[GPMC_MAX_REG] = {
+	0x00011000,
+	0x001F1F01,
+	0x00080803,
+	0x1D091D09,
+	0x041D1F1F,
+	0x1D0904C4, 0
+};
 
 /*
  * Routine: board_init
@@ -42,13 +61,29 @@
 int board_init (void)
 {
 	DECLARE_GLOBAL_DATA_PTR;
+	gpmc_csx_t *serial_cs_base;
+	u32 *gpmc_config;
 
 	gpmc_init ();		/* in SRAM or SDRAM, finish GPMC */
+
+	/* Configure console support on zoom2 */
+	gpmc_config = gpmc_serial_TL16CP754C;
+	serial_cs_base = (gpmc_csx_t *) (GPMC_CONFIG_CS0_BASE +
+					 (3 * GPMC_CONFIG_WIDTH));
+	enable_gpmc_config(gpmc_config,
+			   serial_cs_base,
+			   SERIAL_TL16CP754C_BASE,
+			   GPMC_SIZE_16M);
+
 	/* board id for Linux */
 	gd->bd->bi_arch_number = MACH_TYPE_OMAP_ZOOM2;
 	/* 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;
 }
 
board/omap3/zoom2/zoom2_serial.c new file +130 -0

130 lines not on this page · raw message

board/omap3/zoom2/zoom2_serial.h new file +75 -0

75 lines not on this page · raw message

common/serial.c +2 -0
index 09385d0..dd80e7c 100644
@@ -68,6 +68,8 @@ struct serial_device *__default_serial_console (void)
 #else
 #error "CONFIG_SERIAL? missing."
 #endif
+#elif defined(CONFIG_OMAP3_ZOOM2)
+		return ZOOM2_DEFAULT_SERIAL_DEVICE;
 #else
 #error No default console
 #endif
drivers/serial/ns16550.c +2 -2
index 657c9da..2fcc8c3 100644
@@ -17,7 +17,7 @@
 void NS16550_init (NS16550_t com_port, int baud_divisor)
 {
 	com_port->ier = 0x00;
-#ifdef CONFIG_OMAP
+#if defined(CONFIG_OMAP) && !defined(CONFIG_OMAP3_ZOOM2)
 	com_port->mdr1 = 0x7;	/* mode select reset TL16C750*/
 #endif
 	com_port->lcr = UART_LCR_BKSE | UART_LCRVAL;
@@ -30,7 +30,7 @@ void NS16550_init (NS16550_t com_port, int baud_divisor)
 	com_port->dll = baud_divisor & 0xff;
 	com_port->dlm = (baud_divisor >> 8) & 0xff;
 	com_port->lcr = UART_LCRVAL;
-#if defined(CONFIG_OMAP)
+#if defined(CONFIG_OMAP) && !defined(CONFIG_OMAP3_ZOOM2)
 #if defined(CONFIG_APTIX)
 	com_port->mdr1 = 3;	/* /13 mode so Aptix 6MHz can hit 115200 */
 #else
include/configs/omap3_zoom2.h +13 -13
index 8aea4cb..d9a9c1a 100644
@@ -69,26 +69,26 @@
 
 /*
  * NS16550 Configuration
+ * Zoom2 uses the TL16CP754C on the debug board
  */
-#define V_NS16550_CLK			48000000	/* 48MHz (APLL96/2) */
+#define CONFIG_SERIAL_MULTI		1
+/*
+ * 0 - 1 : first  USB with respect to the left edge of the debug board
+ * 2 - 3 : second USB with respect to the left edge of the debug board
+ */
+#define ZOOM2_DEFAULT_SERIAL_DEVICE	(&zoom2_serial_device0)
+
+#define V_NS16550_CLK			(1843200)	/* 1.8432 Mhz */
 
 #define CONFIG_SYS_NS16550
-#define CONFIG_SYS_NS16550_SERIAL
-#define CONFIG_SYS_NS16550_REG_SIZE	(-4)
+#define CONFIG_SYS_NS16550_REG_SIZE	(-2)
 #define CONFIG_SYS_NS16550_CLK		V_NS16550_CLK
-
-/*
- * select serial console configuration
- */
-#define CONFIG_CONS_INDEX		3
-#define CONFIG_SYS_NS16550_COM3		OMAP34XX_UART3
-#define CONFIG_SERIAL3			3	/* UART3 */
+#define CONFIG_BAUDRATE			115200
+#define CONFIG_SYS_BAUDRATE_TABLE	{115200}
 
 /* allow to overwrite serial and ethaddr */
 #define CONFIG_ENV_OVERWRITE
-#define CONFIG_BAUDRATE			115200
-#define CONFIG_SYS_BAUDRATE_TABLE	{4800, 9600, 19200, 38400, 57600,\
-					115200}
+
 #define CONFIG_MMC			1
 #define CONFIG_OMAP3_MMC		1
 #define CONFIG_DOS_PARTITION		1
include/serial.h +7 -0
index e3d8b36..aca5221 100644
@@ -42,6 +42,13 @@ extern struct serial_device s3c24xx_serial1_device;
 extern struct serial_device s3c24xx_serial2_device;
 #endif
 
+#if defined(CONFIG_OMAP3_ZOOM2)
+extern struct serial_device zoom2_serial_device0;
+extern struct serial_device zoom2_serial_device1;
+extern struct serial_device zoom2_serial_device2;
+extern struct serial_device zoom2_serial_device3;
+#endif
+
 extern struct serial_device serial_ffuart_device;
 extern struct serial_device serial_btuart_device;
 extern struct serial_device serial_stuart_device;
Signature · 1 line
1.6.0.5
author
#5 lore raw

PATCH 6/6 ZOOM2 Add led support.

This patch controls the large LED on the top left of the zoom2.

---
 board/omap3/zoom2/Makefile    |    8 ++-
 board/omap3/zoom2/led.c       |  129 +++++++++++++++++++++++++++++++++++++++++
 board/omap3/zoom2/zoom2.c     |    4 +-
 include/configs/omap3_zoom2.h |   16 +++++
 4 files changed, 153 insertions(+), 4 deletions(-)
 create mode 100644 board/omap3/zoom2/led.c
board/omap3/zoom2/Makefile +5 -3
index d27990c..2feafbe 100644
@@ -25,10 +25,12 @@ include $(TOPDIR)/config.mk
 
 LIB	= $(obj)lib$(BOARD).a
 
-COBJS	:= zoom2.o \
-	debug_board.o \
-	zoom2_serial.o
+COBJS-y := $(BOARD).o
+COBJS-y += debug_board.o
+COBJS-y += zoom2_serial.o
+COBJS-$(CONFIG_STATUS_LED) += led.o
 
+COBJS	:= $(sort $(COBJS-y))
 SRCS	:= $(COBJS:.o=.c)
 OBJS	:= $(addprefix $(obj),$(COBJS))
 
board/omap3/zoom2/led.c new file +129 -0

129 lines not on this page · raw message

board/omap3/zoom2/zoom2.c +3 -1
index dd0086c..f4ec38d 100644
@@ -29,6 +29,9 @@
  * MA 02111-1307 USA
  */
 #include <common.h>
+#ifdef CONFIG_STATUS_LED
+#include <status_led.h>
+#endif
 #include <asm/io.h>
 #include <asm/arch/mem.h>
 #include <asm/arch/mux.h>
@@ -83,7 +86,6 @@ int board_init (void)
 #if defined(CONFIG_STATUS_LED) && defined(STATUS_LED_BOOT)
 	status_led_set (STATUS_LED_BOOT, STATUS_LED_ON);
 #endif
-
 	return 0;
 }
 
include/configs/omap3_zoom2.h +16 -0
index d9a9c1a..1d696b6 100644
@@ -93,6 +93,22 @@
 #define CONFIG_OMAP3_MMC		1
 #define CONFIG_DOS_PARTITION		1
 
+/* Status LED */
+#define CONFIG_STATUS_LED		1 /* Status LED enabled	*/
+#define CONFIG_BOARD_SPECIFIC_LED	1
+#define STATUS_LED_BLUE			0
+#define STATUS_LED_RED			1
+/* Blue */
+#define STATUS_LED_BIT			STATUS_LED_BLUE
+#define STATUS_LED_STATE		STATUS_LED_ON
+#define STATUS_LED_PERIOD		(CONFIG_SYS_HZ / 2)
+/* Red */
+#define STATUS_LED_BIT1			STATUS_LED_RED
+#define STATUS_LED_STATE1		STATUS_LED_OFF
+#define STATUS_LED_PERIOD1		(CONFIG_SYS_HZ / 2)
+/* Optional value */
+#define STATUS_LED_BOOT			STATUS_LED_BIT
+
 /* commands to include */
 #include <config_cmd_default.h>
 
Signature · 1 line
1.6.0.5
#7 lore raw

PATCH 5/6 ZOOM2 Add serial support.

In reply to Tom Rix
Quoted 61 lines · Tom Rix

Zoom2 serial is in general supplied by one of the 4 UARTS on the debug board. The default serial is from the USB connector on left side of the debug board. The USB connector will produce 2 of the 4 UARTS. On your host pick the first enumeration.

The serial port set up is the same with Zoom1.
Baud rate 115200, 8 bit data, no parity, 1 stop bit, no flow.

The kernel bootargs are
console=ttyS3,115200n8

---
 board/omap3/zoom2/Makefile       |    3 +-
 board/omap3/zoom2/zoom2.c        |   35 ++++++++++
 board/omap3/zoom2/zoom2_serial.c |  130 ++++++++++++++++++++++++++++++++++++++
 board/omap3/zoom2/zoom2_serial.h |   75 ++++++++++++++++++++++
 common/serial.c                  |    2 +
 drivers/serial/ns16550.c         |    4 +-
 include/configs/omap3_zoom2.h    |   26 ++++----
 include/serial.h                 |    7 ++
 8 files changed, 266 insertions(+), 16 deletions(-)
 create mode 100644 board/omap3/zoom2/zoom2_serial.c
 create mode 100644 board/omap3/zoom2/zoom2_serial.h
board/omap3/zoom2/Makefile +2 -1
index b8fa5a7..d27990c 100644
@@ -26,7 +26,8 @@ include $(TOPDIR)/config.mk
 LIB	= $(obj)lib$(BOARD).a
 
 COBJS	:= zoom2.o \
-	debug_board.o
+	debug_board.o \
+	zoom2_serial.o
 
 SRCS	:= $(COBJS:.o=.c)
 OBJS	:= $(addprefix $(obj),$(COBJS))
board/omap3/zoom2/zoom2.c +10 -0
index 0700c56..dd0086c 100644
@@ -30,10 +30,29 @@
  */
 #include <common.h>
 #include <asm/io.h>
+#include <asm/arch/mem.h>
 #include <asm/arch/mux.h>
 #include <asm/arch/sys_proto.h>
 #include <asm/mach-types.h>
 #include "zoom2.h"
+#include "zoom2_serial.h"
+
+/*
+ * This the the zoom2, board specific, gpmc configuration for the
+ * quad uart on the debug board.   The more general gpmc configurations
+ * are setup at the cpu level in cpu/arm_cortexa8/omap3/mem.c
+ */
+extern void enable_gpmc_config(u32 *gpmc_config, gpmc_csx_t *gpmc_cs_base,
+			       u32 base, u32 size);

board/omap3/zoom2/zoom2.c line 56

Quoted 10 lines
board/omap3/zoom2/zoom2.c +9 -0
+
+static u32 gpmc_serial_TL16CP754C[GPMC_MAX_REG] = {
+	0x00011000,
+	0x001F1F01,
+	0x00080803,
+	0x1D091D09,
+	0x041D1F1F,
+	0x1D0904C4, 0
+};
 

Any chance to have comment at least about these value?

Best Regards,
J.

author
#8 lore raw

PATCH 5/6 ZOOM2 Add serial support.

Quoted 67 lines · Jean-Christophe PLAGNIOL-VILLARD
Quoted 65 lines · Tom Rix

Zoom2 serial is in general supplied by one of the 4 UARTS on the debug board. The default serial is from the USB connector on left side of the debug board. The USB connector will produce 2 of the 4 UARTS. On your host pick the first enumeration.

The serial port set up is the same with Zoom1.
Baud rate 115200, 8 bit data, no parity, 1 stop bit, no flow.

The kernel bootargs are
console=ttyS3,115200n8

---
 board/omap3/zoom2/Makefile       |    3 +-
 board/omap3/zoom2/zoom2.c        |   35 ++++++++++
 board/omap3/zoom2/zoom2_serial.c |  130 ++++++++++++++++++++++++++++++++++++++
 board/omap3/zoom2/zoom2_serial.h |   75 ++++++++++++++++++++++
 common/serial.c                  |    2 +
 drivers/serial/ns16550.c         |    4 +-
 include/configs/omap3_zoom2.h    |   26 ++++----
 include/serial.h                 |    7 ++
 8 files changed, 266 insertions(+), 16 deletions(-)
 create mode 100644 board/omap3/zoom2/zoom2_serial.c
 create mode 100644 board/omap3/zoom2/zoom2_serial.h
board/omap3/zoom2/Makefile +2 -1
index b8fa5a7..d27990c 100644
@@ -26,7 +26,8 @@ include $(TOPDIR)/config.mk
 LIB	= $(obj)lib$(BOARD).a
 
 COBJS	:= zoom2.o \
-	debug_board.o
+	debug_board.o \
+	zoom2_serial.o
 
 SRCS	:= $(COBJS:.o=.c)
 OBJS	:= $(addprefix $(obj),$(COBJS))
board/omap3/zoom2/zoom2.c +14 -0
index 0700c56..dd0086c 100644
@@ -30,10 +30,29 @@
  */
 #include <common.h>
 #include <asm/io.h>
+#include <asm/arch/mem.h>
 #include <asm/arch/mux.h>
 #include <asm/arch/sys_proto.h>
 #include <asm/mach-types.h>
 #include "zoom2.h"
+#include "zoom2_serial.h"
+
+/*
+ * This the the zoom2, board specific, gpmc configuration for the
+ * quad uart on the debug board.   The more general gpmc configurations
+ * are setup at the cpu level in cpu/arm_cortexa8/omap3/mem.c
+ */
+extern void enable_gpmc_config(u32 *gpmc_config, gpmc_csx_t *gpmc_cs_base,
+			       u32 base, u32 size);
+
+static u32 gpmc_serial_TL16CP754C[GPMC_MAX_REG] = {
+	0x00011000,
+	0x001F1F01,
Quoted 9 lines

board/omap3/zoom2/zoom2.c

Quoted 7 lines
board/omap3/zoom2/zoom2.c +5 -0
+	0x00080803,
+	0x1D091D09,
+	0x041D1F1F,
+	0x1D0904C4, 0
+};
 
 

Any chance to have comment at least about these value?

Sorry. I was given these numbers. I asked and did not get a reply. I will ask again.

Quoted 3 lines

Best Regards,
J.

author
#9 lore raw

PATCH 5/6 ZOOM2 Add serial support.

In reply to Jean-Christophe PLAGNIOL-VILLARD
Quoted 25 lines · Jean-Christophe PLAGNIOL-VILLARD
Quoted 11 lines · Tom Rix

Zoom2 serial is in general supplied by one of the 4 UARTS on the debug board. The default serial is from the USB connector on left side of the debug board.

board/omap3/zoom2/zoom2.c +6 -0
+/*
+ * This the the zoom2, board specific, gpmc configuration for the
+ * quad uart on the debug board.   The more general gpmc configurations
+ * are setup at the cpu level in cpu/arm_cortexa8/omap3/mem.c
+ */
+extern void enable_gpmc_config(u32 *gpmc_config, gpmc_csx_t *gpmc_cs_base,

board/omap3/zoom2/zoom2.c line 55

Quoted 10 lines
board/omap3/zoom2/zoom2.c +10 -0
+			       u32 base, u32 size);
+
+static u32 gpmc_serial_TL16CP754C[GPMC_MAX_REG] = {
+	0x00011000,
+	0x001F1F01,
+	0x00080803,
+	0x1D091D09,
+	0x041D1F1F,
+	0x1D0904C4, 0
+};

Any chance to have comment at least about these value?

Quoted 3 lines

Best Regards,
J.

I have not gotten a response for a better comment.

Can I have a pass on this ?

Tom

#10 lore raw

PATCH 5/6 ZOOM2 Add serial support.

Quoted 26 lines · Tom
Quoted 15 lines · Jean-Christophe PLAGNIOL-VILLARD
Quoted 13 lines · Tom Rix

Zoom2 serial is in general supplied by one of the 4 UARTS on the debug board. The default serial is from the USB connector on left side of the debug board.

board/omap3/zoom2/zoom2.c +10 -0
+/*
+ * This the the zoom2, board specific, gpmc configuration for the
+ * quad uart on the debug board.   The more general gpmc configurations
+ * are setup at the cpu level in cpu/arm_cortexa8/omap3/mem.c
+ */
+extern void enable_gpmc_config(u32 *gpmc_config, gpmc_csx_t *gpmc_cs_base,
+			       u32 base, u32 size);
+
+static u32 gpmc_serial_TL16CP754C[GPMC_MAX_REG] = {
+	0x00011000,
Quoted 9 lines

board/omap3/zoom2/zoom2.c line 55

Quoted 7 lines
board/omap3/zoom2/zoom2.c +6 -0
+	0x001F1F01,
+	0x00080803,
+	0x1D091D09,
+	0x041D1F1F,
+	0x1D0904C4, 0
+};

Any chance to have comment at least about these value?

Quoted 3 lines

I have not gotten a response for a better comment.

Can I have a pass on this ?

ok but add a comment in the code and the commit to explain why you can not provide comment about these values

Best Regards,
J.

author
#11 lore raw

PATCH 5/6 ZOOM2 Add serial support.

Quoted 31 lines · Jean-Christophe PLAGNIOL-VILLARD
Quoted 29 lines · Tom
Quoted 27 lines · Jean-Christophe PLAGNIOL-VILLARD
Quoted 11 lines · Tom Rix

Zoom2 serial is in general supplied by one of the 4 UARTS on the debug board. The default serial is from the USB connector on left side of the debug board.

board/omap3/zoom2/zoom2.c +6 -0
+/*
+ * This the the zoom2, board specific, gpmc configuration for the
+ * quad uart on the debug board.   The more general gpmc configurations
+ * are setup at the cpu level in cpu/arm_cortexa8/omap3/mem.c
+ */
+extern void enable_gpmc_config(u32 *gpmc_config, gpmc_csx_t *gpmc_cs_base,

board/omap3/zoom2/zoom2.c line 55

Quoted 10 lines
board/omap3/zoom2/zoom2.c +10 -0
+			       u32 base, u32 size);
+
+static u32 gpmc_serial_TL16CP754C[GPMC_MAX_REG] = {
+	0x00011000,
+	0x001F1F01,
+	0x00080803,
+	0x1D091D09,
+	0x041D1F1F,
+	0x1D0904C4, 0
+};

Any chance to have comment at least about these value?

Quoted 8 lines
Quoted 4 lines

I have not gotten a response for a better comment.

Can I have a pass on this ?

ok but add a comment in the code and the commit to explain why you can not provide comment about these values

Ok

Quoted 3 lines

Best Regards,
J.

#12 lore raw

PATCH 3/6 OMAP3 Port kernel omap gpio interface.

In reply to Tom Rix
Quoted 2 lines · Tom Rix

Port the linux kernel's omap gpio interface to u-boot. The orignal source is in linux/arch/arm/plat-omap/gpio.c

please specify which specific kernel revision your code is based on

Otherwise fine

Best Regards,
J.

author
#13 lore raw

PATCH 3/6 OMAP3 Port kernel omap gpio interface.

Quoted 5 lines · Jean-Christophe PLAGNIOL-VILLARD
Quoted 3 lines · Tom Rix

Port the linux kernel's omap gpio interface to u-boot. The orignal source is in linux/arch/arm/plat-omap/gpio.c

Quoted 7 lines

please specify which specific kernel revision your code is based on

Otherwise fine

Best Regards,
J.

I added it to the file headers.

I will add it to the commit message.
Tom

#14 lore raw

PATCH 2/6 ZOOM2 Add initial support for Zoom2

In reply to Tom Rix
Quoted 11 lines · Tom Rix

Zoom2 is a new board from Texas Instruments and LogicPD

The logicpd web site is a good source for general information on this board. Please start looking here if the below links are broken.
http://www.logicpd.com

This is a pdf of the product
http://www.logicpd.com/sites/default/files/1012659A_Zoom_OMAP34x-II_MDP_Brief.pdf
This is the product description web page
http://www.logicpd.com/products/development-kits/texas-instruments-zoom%E2%84%A2-omap34x-ii-mdp

Quoted 8 lines

This patch provides a zoom2 base target by copying zoom1 and by making some obvious changes.

To configure, run
make omap3_zoom2_config

---

Applied to arm/next

Best Regards,
J.