blob: 0f0ab01f62910370a3e3a99a9280a9a7d1b1535d [file] [log] [blame]
Chris Packhamc0def242016-09-22 12:56:14 +12001/*
2 * Copyright (C) 2014 Stefan Roese <sr@denx.de>
3 *
4 * SPDX-License-Identifier: GPL-2.0+
5 */
6
7#ifndef _CONFIG_DB_88F6820_AMC_H
8#define _CONFIG_DB_88F6820_AMC_H
9
10/*
11 * High Level Configuration Options (easy to change)
12 */
13
14#define CONFIG_DISPLAY_BOARDINFO_LATE
15
16/*
17 * TEXT_BASE needs to be below 16MiB, since this area is scrubbed
18 * for DDR ECC byte filling in the SPL before loading the main
19 * U-Boot into it.
20 */
21#define CONFIG_SYS_TEXT_BASE 0x00800000
22#define CONFIG_SYS_TCLK 200000000 /* 200MHz */
23
24/*
25 * Commands configuration
26 */
Chris Packhamc0def242016-09-22 12:56:14 +120027#define CONFIG_CMD_PCI
28
Chris Packhamc0def242016-09-22 12:56:14 +120029/* SPI NOR flash default params, used by sf commands */
30#define CONFIG_SF_DEFAULT_BUS 1
31#define CONFIG_SF_DEFAULT_SPEED 1000000
32#define CONFIG_SF_DEFAULT_MODE SPI_MODE_3
33
34/* Partition support */
Chris Packhamc0def242016-09-22 12:56:14 +120035
36/* Additional FS support/configuration */
37#define CONFIG_SUPPORT_VFAT
38
39/* USB/EHCI configuration */
40#define CONFIG_EHCI_IS_TDI
41
42/* Environment in SPI NOR flash */
43#define CONFIG_ENV_IS_IN_SPI_FLASH
44#define CONFIG_ENV_SPI_BUS 1
45#define CONFIG_ENV_OFFSET (1 << 20) /* 1MiB in */
46#define CONFIG_ENV_SIZE (64 << 10) /* 64KiB */
47#define CONFIG_ENV_SECT_SIZE (256 << 10) /* 256KiB sectors */
48
49#define CONFIG_PHY_MARVELL /* there is a marvell phy */
50#define PHY_ANEG_TIMEOUT 8000 /* PHY needs a longer aneg time */
51
52/* PCIe support */
53#ifndef CONFIG_SPL_BUILD
Chris Packhamc0def242016-09-22 12:56:14 +120054#define CONFIG_PCI_MVEBU
Chris Packhamc0def242016-09-22 12:56:14 +120055#define CONFIG_PCI_SCAN_SHOW
56#endif
57
Chris Packham42f75052016-09-22 12:56:15 +120058/* NAND */
59#define CONFIG_SYS_NAND_USE_FLASH_BBT
60#define CONFIG_SYS_NAND_ONFI_DETECTION
61
Chris Packhamc0def242016-09-22 12:56:14 +120062#define CONFIG_SYS_ALT_MEMTEST
63
64/* Keep device tree and initrd in lower memory so the kernel can access them */
65#define CONFIG_EXTRA_ENV_SETTINGS \
66 "fdt_high=0x10000000\0" \
67 "initrd_high=0x10000000\0"
68
69/* SPL */
70/*
71 * Select the boot device here
72 *
73 * Currently supported are:
74 * SPL_BOOT_SPI_NOR_FLASH - Booting via SPI NOR flash
75 *
76 * MMC is not populated on this board.
77 * NAND support may be added in the future.
78 */
79#define SPL_BOOT_SPI_NOR_FLASH 1
80#define CONFIG_SPL_BOOT_DEVICE SPL_BOOT_SPI_NOR_FLASH
81
82/* Defines for SPL */
83#define CONFIG_SPL_FRAMEWORK
84#define CONFIG_SPL_SIZE (140 << 10)
85#define CONFIG_SPL_TEXT_BASE 0x40000030
86#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - 0x0030)
87
88#define CONFIG_SPL_BSS_START_ADDR (0x40000000 + CONFIG_SPL_SIZE)
89#define CONFIG_SPL_BSS_MAX_SIZE (16 << 10)
90
91#ifdef CONFIG_SPL_BUILD
92#define CONFIG_SYS_MALLOC_SIMPLE
93#endif
94
95#define CONFIG_SPL_STACK (0x40000000 + ((192 - 16) << 10))
96#define CONFIG_SPL_BOOTROM_SAVE (CONFIG_SPL_STACK + 4)
97
98#if CONFIG_SPL_BOOT_DEVICE == SPL_BOOT_SPI_NOR_FLASH
99/* SPL related SPI defines */
100#define CONFIG_SPL_SPI_LOAD
101#define CONFIG_SYS_SPI_U_BOOT_OFFS 0x24000
102#define CONFIG_SYS_U_BOOT_OFFS CONFIG_SYS_SPI_U_BOOT_OFFS
103#endif
104
105/*
106 * mv-common.h should be defined after CMD configs since it used them
107 * to enable certain macros
108 */
109#include "mv-common.h"
110#undef CONFIG_SYS_MAXARGS
111#define CONFIG_SYS_MAXARGS 96
112
113#endif /* _CONFIG_DB_88F6820_AMC_H */