Commit Graph

38 Commits

Author SHA1 Message Date
Kumar Gala
d72871e138 arm: Remove -fno-strict-aliasing
-fno-strict-aliasing is hidding warnings.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2009-09-04 22:15:53 +02:00
Wolfgang Denk
f772acf8a5 ARM: compiler options cleanup - improve tool chain support
For some time there have been repeated reports about build problems
with some ARM (cross) tool chains.  Especially issues about
(in)compatibility with the tool chain provided runtime support
library libgcc.a caused to add and support a private implementation
of such runtime support code in U-Boot.  A closer look at the code
indicated that some of these issues are actually home-made.  This
patch attempts to clean up some of the most obvious problems and make
building of U-Boot with different tool chains easier:

- Even though all ARM systems basicy used the same compiler options
  to select a specific ABI from the tool chain, the code for this was
  distributed over all cpu/*/config.mk files.  We move this one level
  up into lib_arm/config.mk instead.

- So far, we only checked if "-mapcs-32" was supported by the tool
  chain; if yes, this was used, if not, "-mabi=apcs-gnu" was
  selected, no matter if the tool chain actually understood this
  option.  There was no support for EABI conformant tool chains.
  This patch implements the following logic:

  1) If the tool chain supports
	"-mabi=aapcs-linux -mno-thumb-interwork"
     we use these options (EABI conformant tool chain).
  2) Otherwise, we check first if
	"-mapcs-32"
     is supported, and then check for
	"-mabi=apcs-gnu"
     If one test succeeds, we use the first found option.
  3) In case 2), we also test if "-mno-thumb-interwork", and use
     this if the test succeeds. [For "-mabi=aapcs-linux" we set
     "-mno-thumb-interwork" mandatorily.]

  This way we use a similar logic for the compile options as the
  Linux kernel does.

- Some EABI conformant tool chains cause external references to
  utility functions like raise(); such functions are provided in the
  new file lib_arm/eabi_compat.c

  Note that lib_arm/config.mk gets parsed several times, so we must
  make sure to add eabi_compat.o only once to the linker list.

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Cc: Dirk Behme <dirk.behme@googlemail.com>
Cc: Magnus Lilja <lilja.magnus@gmail.com>
Cc: Tom Rix <Tom.Rix@windriver.com>
Cc: Prafulla Wadaskar <prafulla@marvell.com>
Acked-by: Sergey Kubushyn <ksi@koi8.net>
Tested-by: Magnus Lilja <lilja.magnus@gmail.com>
Tested-by: Andrzej Wolski <awolski@poczta.fm>
Tested-by: Gaye Abdoulaye Walsimou <walsimou@walsimou.com>
Tested-by: Tom Rix <Tom.Rix@windriver.com>
Tested-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-08-21 23:11:53 +02:00
Dirk Behme
3ed9e943fd ARM Cortex A8: Remove bogus config.mk entries
Remove bogus config.mk entry, fix newline and remove redundant
omap3/config.mk

Signed-off-by: Dirk Behme <dirk.behme@googlemail.com>
2009-08-10 00:13:22 +02:00
Penda Naveen Kumar
3b9043a7c0 omap3: bug fix for NOR boot support
This patch provides bug fix, when omap3 uses nor boot.

Signed-off-by: Penda Naveen Kumar<pnaveen@ti.com>
Acked-by: Dirk Behme <dirk.behme@googlemail.com>
2009-08-08 11:59:40 +02:00
Dirk Behme
894113529e omap3: replace all instances of gpmc config struct by one global
Signed-off-by: Matthias Ludwig <mludwig@ultratronik.de>
Signed-off-by: Dirk Behme <dirk.behme@googlemail.com>
2009-08-08 11:34:11 +02:00
Dirk Behme
97a099eaa4 omap3: remove typedefs for configuration structs
Signed-off-by: Matthias Ludwig <mludwig@ultratronik.de>
Signed-off-by: Dirk Behme <dirk.behme@googlemail.com>
2009-08-08 11:33:23 +02:00
Matthias Ludwig
187af954cf omap3: embedd gpmc_cs into gpmc config struct
Embedd chip select configuration into struct for gpmc config
instead of having it completely separated as suggested by
Wolfgang Denk on
http://lists.denx.de/pipermail/u-boot/2009-May/052247.html

Signed-off-by: Matthias Ludwig <mludwig@ultratronik.de>
2009-08-07 23:31:51 +02:00
Wolfgang Denk
84efbf4d14 Merge branch 'master' of git://git.denx.de/u-boot-arm 2009-07-23 00:59:37 +02:00
Minkyu Kang
6b96a20d51 ARM Cortex A8: Move OMAP3 specific reset handler
Because of the reset_cpu is soc specific, should be move to soc

Cc: Dirk Behme <dirk.behme@googlemail.com>
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2009-07-22 23:39:42 +02:00
Tom Rix
6bb6e6c75e OMAP3 Fix compiler warning for v7_flush_dcache_all
On build of omap3 targets in MAKEALL, the *.ERR files have

cpu.c: In function 'cleanup_before_linux':
cpu.c:64: warning: implicit declaration of function 'v7_flush_dcache_all'
cpu.c:64: warning: implicit declaration of function 'get_device_type

The functions v7_flush_dcache_all and get_device_type are declared
in include/asm-arm/arch-omap3/sys_proto.h, so use this file to
declare the functions.

Signed-off-by: Tom Rix <Tom.Rix@windriver.com>
2009-07-18 22:36:32 +02:00
Wolfgang Denk
8e5e9b940c Coding style cleanup; update CHANGELOG
Signed-off-by: Wolfgang Denk <wd@denx.de>
2009-07-07 22:35:02 +02:00
Kim, Heung Jun
06e758e75c move L2 cache enable/disable function to cache.c in the omap3 SoC directory
Signed-off-by: HeungJun, Kim <riverful.kim@samsung.com>
CC: Dirk Behme <dirk.behme@googlemail.com>
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-07-06 21:52:25 +02:00
Wolfgang Denk
a89c33db96 General help message cleanup
Many of the help messages were not really helpful; for example, many
commands that take no arguments would not print a correct synopsis
line, but "No additional help available." which is not exactly wrong,
but not helpful either.

Commit ``Make "usage" messages more helpful.'' changed this
partially. But it also became clear that lots of "Usage" and "Help"
messages (fields "usage" and "help" in struct cmd_tbl_s respective)
were actually redundant.

This patch cleans this up - for example:

Before:
	=> help dtt
	dtt - Digital Thermometer and Thermostat

	Usage:
	dtt         - Read temperature from digital thermometer and thermostat.

After:
	=> help dtt
	dtt - Read temperature from Digital Thermometer and Thermostat

	Usage:
	dtt

Signed-off-by: Wolfgang Denk <wd@denx.de>
2009-06-12 20:47:16 +02:00
Tom Rix
708cfb74b7 OMAP3 Turn on the GPIO bank clocks
The function and interface clocks for each GPIO bank, except the first, must
be explicitly turned on.  These are controlled by the config level defines
CONFIG_OMAP3_GPIO_n where n is from 2 to 6.

Signed-off-by: Tom Rix <Tom.Rix@windriver.com>
Acked-by: Dirk Behme <dirk.behme@googlemail.com>
2009-06-12 20:45:47 +02:00
Jean-Christophe PLAGNIOL-VILLARD
ad7e8aac69 arm: remove cpu_init
move s3c44b0 to arch_cpu_init and as noone use cpu_init remove it

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-06-12 20:39:52 +02:00
Jean-Christophe PLAGNIOL-VILLARD
c358d9c3f1 arm: unify interrupt init
all arm init the IRQ stack the same way
so unify it in lib_arm/interrupts.c and then call arch specific interrupt init

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-06-12 20:39:52 +02:00
Jean-Christophe PLAGNIOL-VILLARD
10a451cd57 arm: unify linker script
all arm boards except a few use the same cpu linker script
so move it to cpu/$(CPU)

that could be overwrite in following order
SOC
BOARD
via the corresponding config.mk

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-06-12 20:39:52 +02:00
Tom Rix
0c872ecd01 OMAP3 Port kernel omap gpio interface.
Port version 2.6.27 of 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.

Signed-off-by: Tom Rix <Tom.Rix@windriver.com>
2009-06-12 20:39:50 +02:00
Tom Rix
68a531fd46 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.

Signed-off-by: Tom Rix <Tom.Rix@windriver.com>
2009-06-12 20:39:49 +02:00
Jean-Christophe PLAGNIOL-VILLARD
b54384e3ba arm: timer and interrupt init rework
actually the timer init use the interrupt_init as init callback
which make the interrupt and timer implementation difficult to follow

so now rename it as int timer_init(void) and use interrupt_init for interrupt

btw also remane the corresponding file to the functionnality implemented

as ixp arch implement two timer - one based on interrupt - so all the timer
related code is moved to timer.c

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-06-12 20:39:48 +02:00
Jean-Christophe PLAGNIOL-VILLARD
5b4bebe1d2 OMAP3: Reorganize Makefile style
Reformat COBJS handling.

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Dirk Behme <dirk.behme@googlemail.com>
2009-06-12 20:39:48 +02:00
Jean-Christophe PLAGNIOL-VILLARD
b196698271 OMAP3: Remove dublicated interrupt code
Remove duplicated interrupt code. Original, identical code can be found
in lib_arm/interrupts.c

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Dirk Behme <dirk.behme@googlemail.com>
2009-06-12 20:39:48 +02:00
Detlev Zundel
792a09eb9d Fix e-mail address of Gary Jennejohn.
Signed-off-by: Detlev Zundel <dzu@denx.de>
2009-05-15 22:11:59 +02:00
Manikandan Pillai
d3a513c23b OMAP3: Fix timer handling to 1ms and CONFIG_SYS_HZ to 1000
Signed-off-by: Dirk Behme <dirk.behme@googlemail.com>
Signed-off-by: Manikandan Pillai <mani.pillai@ti.com>
2009-04-30 23:56:01 +02:00
Sanjeev Premi
cba0b778dd OMAP3: Print correct silicon revision
The function display_board_info() displays incorrect
silicon revision - based on the return value from
function get_cpu_rev().

This patch fixes the problem.

Signed-off-by: Sanjeev Premi <premi@ti.com>
2009-04-29 21:11:49 +02:00
Sanjeev Premi
90006e9b33 OMAP3: Remove unused board-types
The board-types defined in struct omap3_sysinfo seem to be
unused. The function display_board_info() is passed
board type as an argument; which is ignored.

This patch removes all uses of board-type, related definitions
and functions.

Signed-off-by: Sanjeev Premi <premi@ti.com>
2009-04-29 21:11:40 +02:00
Sanjeev Premi
6a6b62e3aa OMAP3: Use functions print_cpuinfo() and checkboard()
Use the functions print_cpuinfo() and checkboard() to
display the cpu and board specific information.

These functions reuse content from the existing function
display_board_info() - which has been removed.

Also, updated the existig OMAP3 configurations to
define:
 - CONFIG_DISPLAY_CPUINFO
 - CONFIG_DISPLAY_BOARDINFO

Signed-off-by: Sanjeev Premi <premi@ti.com>
2009-04-29 21:11:32 +02:00
Jean-Christophe PLAGNIOL-VILLARD
ab29823151 arm: unify reset command
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-04-05 13:08:03 +02:00
Jean-Christophe PLAGNIOL-VILLARD
b3acb6cd40 arm: clean cache management
unify arm cache management except for non standard cache as ARM7TDMI

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-04-05 13:06:31 +02:00
Jean-Christophe PLAGNIOL-VILLARD
677e62f432 arm: update co-processor 15 access
import system.h from linux

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-04-05 13:02:43 +02:00
Sanjeev Premi
3600326896 OMAP: Fix compile issue
Fixes this compile error:
board.c: In function 'do_switch_ecc':
board.c:339: error: 'cmd_tbl_t' has no member named 'help'
make[1]: *** [board.o] Error 1
make[1]: Leaving directory `/db/psp_git/users/a0756819/u-boot/cpu/arm_cortexa8/omap3'
make: *** [cpu/arm_cortexa8/omap3/libomap3.a] Error 2

This is due to the fact that current command uses long
help for the usage print even if the CONFIG_SYS_LONGHELP
is not enabled. (Thanks Jean-Christophe for explanation).

Signed-off-by: Sanjeev Premi <premi@ti.com>
2009-04-05 00:30:39 +02:00
Ladislav Michl
81472d893f OMAP: rename timer divisor
Divisor field is called PTV not PVT.

Signed-off-by: Ladislav Michl <ladis@linux-mips.org>
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-03-30 18:58:41 +02:00
Dirk Behme
e6a6a70415 OMAP3: Add support for OMAP3 die ID
Read and store OMAP3 die ID in U-Boot environment.

Signed-off-by: Dirk Behme <dirk.behme@googlemail.com>
2009-03-13 23:17:43 +01:00
Dirk Behme
6530a8bf8a OMAP3: Add OMAP3 auto detection
This patch adds OMAP3 cpu type auto detection based on OMAP3 register
and removes hardcoded values.

Signed-off-by: Steve Sakoman <sakoman@gmail.com>
Signed-off-by: Dirk Behme <dirk.behme@googlemail.com>
2009-02-22 18:29:10 +01:00
Wolfgang Denk
f15c6515fc Coding style cleanup; update CHANGELOG
Signed-off-by: Wolfgang Denk <wd@denx.de>
2009-02-12 00:08:39 +01:00
Dirk Behme
91eee54673 OMAP3: Add common board, interrupt and system info
Add common board, interrupt and system info code.

Signed-off-by: Dirk Behme <dirk.behme@googlemail.com>
2009-01-24 17:51:21 +01:00
Dirk Behme
5ed3e8659e OMAP3: Add common clock, memory and low level code
Add common clock, memory and low level code

Signed-off-by: Dirk Behme <dirk.behme@googlemail.com>
2009-01-24 17:51:21 +01:00
Dirk Behme
0b02b18400 OMAP3: Add common cpu and start code
Add common cpu and start code.

Signed-off-by: Dirk Behme <dirk.behme@googlemail.com>
2009-01-24 17:51:21 +01:00