blob: 98a17181a41efead383c8d91b461b166c6ea9e56 [file] [log] [blame]
Tom Rini83d290c2018-05-06 17:58:06 -04001/* SPDX-License-Identifier: GPL-2.0+ */
wdenkbf9e3b32004-02-12 00:47:09 +00002/*
3 * Configuation settings for the Motorola MC5272C3 board.
4 *
5 * (C) Copyright 2003 Josef Baumgartner <josef.baumgartner@telex.de>
wdenkbf9e3b32004-02-12 00:47:09 +00006 */
wdenk4e5ca3e2003-12-08 01:34:36 +00007
wdenkbf9e3b32004-02-12 00:47:09 +00008/*
9 * board/config.h - configuration options, board specific
10 */
wdenk4e5ca3e2003-12-08 01:34:36 +000011
wdenkbf9e3b32004-02-12 00:47:09 +000012#ifndef _M5272C3_H
13#define _M5272C3_H
14
15/*
16 * High Level Configuration Options
17 * (easy to change)
18 */
wdenk4e5ca3e2003-12-08 01:34:36 +000019
Tom Rini65cc0e22022-11-16 13:10:41 -050020#define CFG_SYS_UART_PORT (0)
wdenk4e5ca3e2003-12-08 01:34:36 +000021
wdenkbf9e3b32004-02-12 00:47:09 +000022/* Configuration for environment
23 * Environment is embedded in u-boot in the second sector of the flash
24 */
wdenkbf9e3b32004-02-12 00:47:09 +000025
angelo@sysam.it5296cb12015-03-29 22:54:16 +020026#define LDS_BOARD_TEXT \
Simon Glass0649cd02017-08-03 12:21:49 -060027 . = DEFINED(env_offset) ? env_offset : .; \
28 env/embedded.o(.text);
angelo@sysam.it5296cb12015-03-29 22:54:16 +020029
Tom Rini0613c362022-12-04 10:03:50 -050030#define CFG_EXTRA_ENV_SETTINGS \
TsiChungLiewf28e1bd2007-08-15 20:32:06 -050031 "netdev=eth0\0" \
32 "loadaddr=10000\0" \
33 "u-boot=u-boot.bin\0" \
34 "load=tftp ${loadaddr) ${u-boot}\0" \
35 "upd=run load; run prog\0" \
36 "prog=prot off ffe00000 ffe3ffff;" \
37 "era ffe00000 ffe3ffff;" \
38 "cp.b ${loadaddr} ffe00000 ${filesize};"\
39 "save\0" \
40 ""
wdenkbf9e3b32004-02-12 00:47:09 +000041
Tom Rini65cc0e22022-11-16 13:10:41 -050042#define CFG_SYS_CLK 66000000
wdenkbf9e3b32004-02-12 00:47:09 +000043
44/*
45 * Low Level Configuration Settings
46 * (address mappings, register initial values, etc.)
47 * You should know what you are doing if you make changes here.
48 */
Tom Rini65cc0e22022-11-16 13:10:41 -050049#define CFG_SYS_MBAR 0x10000000 /* Register Base Addrs */
50#define CFG_SYS_SCR 0x0003
51#define CFG_SYS_SPR 0xffff
wdenkbf9e3b32004-02-12 00:47:09 +000052
wdenkbf9e3b32004-02-12 00:47:09 +000053/*-----------------------------------------------------------------------
54 * Definitions for initial stack pointer and data area (in DPRAM)
55 */
Tom Rini65cc0e22022-11-16 13:10:41 -050056#define CFG_SYS_INIT_RAM_ADDR 0x20000000
57#define CFG_SYS_INIT_RAM_SIZE 0x1000 /* Size of used area in internal SRAM */
wdenkbf9e3b32004-02-12 00:47:09 +000058
59/*-----------------------------------------------------------------------
60 * Start addresses for the final memory configuration
61 * (Set up by the startup code)
Tom Riniaa6e94d2022-11-16 13:10:37 -050062 * Please note that CFG_SYS_SDRAM_BASE _must_ start at 0
wdenkbf9e3b32004-02-12 00:47:09 +000063 */
Tom Riniaa6e94d2022-11-16 13:10:37 -050064#define CFG_SYS_SDRAM_BASE 0x00000000
65#define CFG_SYS_SDRAM_SIZE 4 /* SDRAM size in MB */
Tom Rini65cc0e22022-11-16 13:10:41 -050066#define CFG_SYS_FLASH_BASE 0xffe00000
wdenkbf9e3b32004-02-12 00:47:09 +000067
wdenkbf9e3b32004-02-12 00:47:09 +000068/*
69 * For booting Linux, the board info and command line data
70 * have to be in the first 8 MB of memory, since this is
71 * the maximum mapped by the Linux kernel during initialization ??
72 */
Tom Rini65cc0e22022-11-16 13:10:41 -050073#define CFG_SYS_BOOTMAPSZ (CFG_SYS_SDRAM_BASE + (CFG_SYS_SDRAM_SIZE << 20))
wdenkbf9e3b32004-02-12 00:47:09 +000074
TsiChung Liewb2028162008-10-21 14:19:26 +000075/*
wdenkbf9e3b32004-02-12 00:47:09 +000076 * FLASH organization
77 */
TsiChung Liewb2028162008-10-21 14:19:26 +000078#ifdef CONFIG_SYS_FLASH_CFI
Tom Rini65cc0e22022-11-16 13:10:41 -050079# define CFG_SYS_FLASH_SIZE 0x800000 /* Max size that the board might have */
TsiChung Liewb2028162008-10-21 14:19:26 +000080#endif
wdenkbf9e3b32004-02-12 00:47:09 +000081
82/*-----------------------------------------------------------------------
83 * Cache Configuration
84 */
wdenkbf9e3b32004-02-12 00:47:09 +000085
Tom Rini65cc0e22022-11-16 13:10:41 -050086#define ICACHE_STATUS (CFG_SYS_INIT_RAM_ADDR + \
87 CFG_SYS_INIT_RAM_SIZE - 8)
88#define DCACHE_STATUS (CFG_SYS_INIT_RAM_ADDR + \
89 CFG_SYS_INIT_RAM_SIZE - 4)
90#define CFG_SYS_ICACHE_INV (CF_CACR_CINV | CF_CACR_INVI)
91#define CFG_SYS_CACHE_ACR0 (CFG_SYS_SDRAM_BASE | \
Tom Riniaa6e94d2022-11-16 13:10:37 -050092 CF_ADDRMASK(CFG_SYS_SDRAM_SIZE) | \
TsiChung Liewdd9f0542010-03-11 22:12:53 -060093 CF_ACR_EN | CF_ACR_SM_ALL)
Tom Rini65cc0e22022-11-16 13:10:41 -050094#define CFG_SYS_CACHE_ICACR (CF_CACR_CENB | CF_CACR_CINV | \
TsiChung Liewdd9f0542010-03-11 22:12:53 -060095 CF_CACR_DISD | CF_CACR_INVI | \
96 CF_CACR_CEIB | CF_CACR_DCM | \
97 CF_CACR_EUSP)
98
wdenkbf9e3b32004-02-12 00:47:09 +000099/*-----------------------------------------------------------------------
wdenkbf9e3b32004-02-12 00:47:09 +0000100 * Port configuration
101 */
Tom Rini65cc0e22022-11-16 13:10:41 -0500102#define CFG_SYS_PACNT 0x00000000
103#define CFG_SYS_PADDR 0x0000
104#define CFG_SYS_PADAT 0x0000
105#define CFG_SYS_PBCNT 0x55554155 /* Ethernet/UART configuration */
106#define CFG_SYS_PBDDR 0x0000
107#define CFG_SYS_PBDAT 0x0000
108#define CFG_SYS_PDCNT 0x00000000
Angelo Dureghello7ff7b462023-02-25 23:25:26 +0100109
Angelo Dureghello7ff7b462023-02-25 23:25:26 +0100110
TsiChungLiewf28e1bd2007-08-15 20:32:06 -0500111#endif /* _M5272C3_H */