]> git.ipfire.org Git - people/ms/u-boot.git/blame - include/configs/sama5d2_xplained.h
Merge git://git.denx.de/u-boot-sh
[people/ms/u-boot.git] / include / configs / sama5d2_xplained.h
CommitLineData
75238f23
WY
1/*
2 * Configuration file for the SAMA5D2 Xplained Board.
3 *
4 * Copyright (C) 2015 Atmel Corporation
5 * Wenyou Yang <wenyou.yang@atmel.com>
6 *
7 * SPDX-License-Identifier: GPL-2.0+
8 */
9
10#ifndef __CONFIG_H
11#define __CONFIG_H
12
75238f23
WY
13#include "at91-sama5_common.h"
14
0daa2e18
WY
15#define CONFIG_MISC_INIT_R
16
75238f23
WY
17/* SDRAM */
18#define CONFIG_NR_DRAM_BANKS 1
e61ed48f 19#define CONFIG_SYS_SDRAM_BASE 0x20000000
75238f23
WY
20#define CONFIG_SYS_SDRAM_SIZE 0x20000000
21
37dadbca 22#ifdef CONFIG_SPL_BUILD
62904b73 23#define CONFIG_SYS_INIT_SP_ADDR 0x218000
37dadbca 24#else
75238f23 25#define CONFIG_SYS_INIT_SP_ADDR \
62904b73 26 (CONFIG_SYS_SDRAM_BASE + 16 * 1024 - GENERATED_GBL_DATA_SIZE)
37dadbca 27#endif
75238f23
WY
28
29#define CONFIG_SYS_LOAD_ADDR 0x22000000 /* load address */
30
75238f23
WY
31/* SerialFlash */
32#ifdef CONFIG_CMD_SF
75238f23
WY
33#define CONFIG_SF_DEFAULT_BUS 0
34#define CONFIG_SF_DEFAULT_CS 0
35#define CONFIG_SF_DEFAULT_SPEED 30000000
36#endif
37
5541543f 38#ifdef CONFIG_SD_BOOT
75238f23
WY
39
40/* bootstrap + u-boot + env in sd card */
75238f23
WY
41#undef CONFIG_BOOTCOMMAND
42
75238f23
WY
43#define CONFIG_BOOTCOMMAND "fatload mmc 1:1 0x21000000 at91-sama5d2_xplained.dtb; " \
44 "fatload mmc 1:1 0x22000000 zImage; " \
45 "bootz 0x22000000 - 0x21000000"
75238f23
WY
46
47#endif
48
37dadbca 49/* SPL */
37dadbca 50#define CONFIG_SPL_TEXT_BASE 0x200000
23a19e03 51#define CONFIG_SPL_MAX_SIZE 0x10000
37dadbca
WY
52#define CONFIG_SPL_BSS_START_ADDR 0x20000000
53#define CONFIG_SPL_BSS_MAX_SIZE 0x80000
54#define CONFIG_SYS_SPL_MALLOC_START 0x20080000
55#define CONFIG_SYS_SPL_MALLOC_SIZE 0x80000
56
37dadbca
WY
57#define CONFIG_SYS_MONITOR_LEN (512 << 10)
58
5541543f 59#ifdef CONFIG_SD_BOOT
37dadbca
WY
60#define CONFIG_SYS_MMCSD_FS_BOOT_PARTITION 1
61#define CONFIG_SPL_FS_LOAD_PAYLOAD_NAME "u-boot.img"
37dadbca 62
5541543f 63#elif CONFIG_SPI_BOOT
37dadbca 64#define CONFIG_SPL_SPI_LOAD
62904b73 65#define CONFIG_SYS_SPI_U_BOOT_OFFS 0x10000
37dadbca
WY
66
67#endif
68
75238f23 69#endif