blob: 33c2fc0870601e5e1c5d0d0bc953c6751f107f08 [file] [log] [blame]
Tom Rini10e47792018-05-06 17:58:06 -04001/* SPDX-License-Identifier: GPL-2.0+ */
wdenke65527f2004-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>
wdenke65527f2004-02-12 00:47:09 +00006 */
wdenkabf7a7c2003-12-08 01:34:36 +00007
wdenke65527f2004-02-12 00:47:09 +00008/*
9 * board/config.h - configuration options, board specific
10 */
wdenkabf7a7c2003-12-08 01:34:36 +000011
wdenke65527f2004-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 */
wdenkabf7a7c2003-12-08 01:34:36 +000019
Tom Rini6a5dccc2022-11-16 13:10:41 -050020#define CFG_SYS_UART_PORT (0)
wdenke65527f2004-02-12 00:47:09 +000021
wdenke65527f2004-02-12 00:47:09 +000022/* Configuration for environment
23 * Environment is embedded in u-boot in the second sector of the flash
24 */
wdenke65527f2004-02-12 00:47:09 +000025
angelo@sysam.it6312a952015-03-29 22:54:16 +020026#define LDS_BOARD_TEXT \
Simon Glass547cb402017-08-03 12:21:49 -060027 . = DEFINED(env_offset) ? env_offset : .; \
28 env/embedded.o(.text);
angelo@sysam.it6312a952015-03-29 22:54:16 +020029
Tom Rinic9edebe2022-12-04 10:03:50 -050030#define CFG_EXTRA_ENV_SETTINGS \
TsiChungLiew1692b482007-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 ""
wdenke65527f2004-02-12 00:47:09 +000041
Tom Rini6a5dccc2022-11-16 13:10:41 -050042#define CFG_SYS_CLK 66000000
wdenke65527f2004-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 Rini6a5dccc2022-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
wdenke65527f2004-02-12 00:47:09 +000052
wdenke65527f2004-02-12 00:47:09 +000053/*-----------------------------------------------------------------------
54 * Definitions for initial stack pointer and data area (in DPRAM)
55 */
Tom Rini6a5dccc2022-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 */
wdenke65527f2004-02-12 00:47:09 +000058
59/*-----------------------------------------------------------------------
60 * Start addresses for the final memory configuration
61 * (Set up by the startup code)
Tom Rinibb4dd962022-11-16 13:10:37 -050062 * Please note that CFG_SYS_SDRAM_BASE _must_ start at 0
wdenke65527f2004-02-12 00:47:09 +000063 */
Tom Rinibb4dd962022-11-16 13:10:37 -050064#define CFG_SYS_SDRAM_BASE 0x00000000
65#define CFG_SYS_SDRAM_SIZE 4 /* SDRAM size in MB */
Tom Rini6a5dccc2022-11-16 13:10:41 -050066#define CFG_SYS_FLASH_BASE 0xffe00000
wdenke65527f2004-02-12 00:47:09 +000067
wdenke65527f2004-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 Rini6a5dccc2022-11-16 13:10:41 -050073#define CFG_SYS_BOOTMAPSZ (CFG_SYS_SDRAM_BASE + (CFG_SYS_SDRAM_SIZE << 20))
wdenke65527f2004-02-12 00:47:09 +000074
TsiChung Liew12b340a2008-10-21 14:19:26 +000075/*
wdenke65527f2004-02-12 00:47:09 +000076 * FLASH organization
77 */
TsiChung Liew12b340a2008-10-21 14:19:26 +000078#ifdef CONFIG_SYS_FLASH_CFI
Tom Rini6a5dccc2022-11-16 13:10:41 -050079# define CFG_SYS_FLASH_SIZE 0x800000 /* Max size that the board might have */
TsiChung Liew12b340a2008-10-21 14:19:26 +000080#endif
wdenke65527f2004-02-12 00:47:09 +000081
82/*-----------------------------------------------------------------------
83 * Cache Configuration
84 */
wdenke65527f2004-02-12 00:47:09 +000085
Tom Rini6a5dccc2022-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 Rinibb4dd962022-11-16 13:10:37 -050092 CF_ADDRMASK(CFG_SYS_SDRAM_SIZE) | \
TsiChung Liew0ee47d42010-03-11 22:12:53 -060093 CF_ACR_EN | CF_ACR_SM_ALL)
Tom Rini6a5dccc2022-11-16 13:10:41 -050094#define CFG_SYS_CACHE_ICACR (CF_CACR_CENB | CF_CACR_CINV | \
TsiChung Liew0ee47d42010-03-11 22:12:53 -060095 CF_CACR_DISD | CF_CACR_INVI | \
96 CF_CACR_CEIB | CF_CACR_DCM | \
97 CF_CACR_EUSP)
98
wdenke65527f2004-02-12 00:47:09 +000099/*-----------------------------------------------------------------------
wdenke65527f2004-02-12 00:47:09 +0000100 * Port configuration
101 */
Tom Rini6a5dccc2022-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
TsiChungLiew1692b482007-08-15 20:32:06 -0500109#endif /* _M5272C3_H */