wdenk | fa89d7c | 2004-09-28 16:44:41 +0000 | [diff] [blame] | 1 | /* |
| 2 | * (C) Copyright 2004 |
| 3 | * Vincent Dubey, Xa SA, vincent.dubey@xa-ch.com |
| 4 | * |
| 5 | * (C) Copyright 2002 |
| 6 | * Kyle Harris, Nexus Technologies, Inc. kharris@nexus-tech.net |
| 7 | * |
| 8 | * (C) Copyright 2002 |
| 9 | * Sysgo Real-Time Solutions, GmbH <www.elinos.com> |
| 10 | * Marius Groeger <mgroeger@sysgo.de> |
| 11 | * |
Wolfgang Denk | d79de1d | 2013-07-08 09:37:19 +0200 | [diff] [blame] | 12 | * SPDX-License-Identifier: GPL-2.0+ |
wdenk | fa89d7c | 2004-09-28 16:44:41 +0000 | [diff] [blame] | 13 | */ |
| 14 | |
| 15 | #include <common.h> |
Ben Warren | 0fd6aae | 2009-10-04 22:37:03 -0700 | [diff] [blame] | 16 | #include <netdev.h> |
Marek Vasut | 71d058b | 2011-11-26 11:17:32 +0100 | [diff] [blame] | 17 | #include <asm/arch/pxa.h> |
wdenk | fa89d7c | 2004-09-28 16:44:41 +0000 | [diff] [blame] | 18 | |
Wolfgang Denk | 6405a15 | 2006-03-31 18:32:53 +0200 | [diff] [blame] | 19 | DECLARE_GLOBAL_DATA_PTR; |
wdenk | fa89d7c | 2004-09-28 16:44:41 +0000 | [diff] [blame] | 20 | |
| 21 | /* |
| 22 | * Miscelaneous platform dependent initialisations |
| 23 | */ |
| 24 | |
| 25 | int board_init (void) |
| 26 | { |
Marek Vasut | 7cdb976 | 2010-10-20 21:54:19 +0200 | [diff] [blame] | 27 | /* We have RAM, disable cache */ |
| 28 | dcache_disable(); |
| 29 | icache_disable(); |
wdenk | fa89d7c | 2004-09-28 16:44:41 +0000 | [diff] [blame] | 30 | |
| 31 | /* arch number of xaeniax */ |
| 32 | gd->bd->bi_arch_number = 585; |
| 33 | |
| 34 | /* adress of boot parameters */ |
| 35 | gd->bd->bi_boot_params = 0xa0000100; |
| 36 | |
| 37 | return 0; |
| 38 | } |
| 39 | |
| 40 | int board_late_init(void) |
| 41 | { |
| 42 | setenv("stdout", "serial"); |
| 43 | setenv("stderr", "serial"); |
| 44 | return 0; |
| 45 | } |
| 46 | |
Marek Vasut | 7cdb976 | 2010-10-20 21:54:19 +0200 | [diff] [blame] | 47 | int dram_init(void) |
| 48 | { |
Marek Vasut | 08341be | 2011-11-26 11:18:57 +0100 | [diff] [blame] | 49 | pxa2xx_dram_init(); |
Marek Vasut | 7cdb976 | 2010-10-20 21:54:19 +0200 | [diff] [blame] | 50 | gd->ram_size = PHYS_SDRAM_1_SIZE; |
| 51 | return 0; |
| 52 | } |
wdenk | fa89d7c | 2004-09-28 16:44:41 +0000 | [diff] [blame] | 53 | |
Marek Vasut | 7cdb976 | 2010-10-20 21:54:19 +0200 | [diff] [blame] | 54 | void dram_init_banksize(void) |
wdenk | fa89d7c | 2004-09-28 16:44:41 +0000 | [diff] [blame] | 55 | { |
wdenk | fa89d7c | 2004-09-28 16:44:41 +0000 | [diff] [blame] | 56 | gd->bd->bi_dram[0].start = PHYS_SDRAM_1; |
| 57 | gd->bd->bi_dram[0].size = PHYS_SDRAM_1_SIZE; |
wdenk | fa89d7c | 2004-09-28 16:44:41 +0000 | [diff] [blame] | 58 | } |
Ben Warren | 0fd6aae | 2009-10-04 22:37:03 -0700 | [diff] [blame] | 59 | |
| 60 | #ifdef CONFIG_CMD_NET |
| 61 | int board_eth_init(bd_t *bis) |
| 62 | { |
| 63 | int rc = 0; |
| 64 | #ifdef CONFIG_SMC91111 |
| 65 | rc = smc91111_initialize(0, CONFIG_SMC91111_BASE); |
| 66 | #endif |
| 67 | return rc; |
| 68 | } |
| 69 | #endif |