blob: ec6b01f14423e706529bb9966f9cb3a58e62b49a [file] [log] [blame]
Tom Rini83d290c2018-05-06 17:58:06 -04001/* SPDX-License-Identifier: GPL-2.0+ */
Marek Vasutf9727162013-09-20 16:14:13 +02002/*
3 * Copyright (C) 2013 Marek Vasut <marex@denx.de>
Marek Vasutf9727162013-09-20 16:14:13 +02004 */
5#ifndef __CONFIGS_BG0900_H__
6#define __CONFIGS_BG0900_H__
7
Marek Vasutf9727162013-09-20 16:14:13 +02008/* Memory configuration */
Marek Vasutf9727162013-09-20 16:14:13 +02009#define PHYS_SDRAM_1 0x40000000 /* Base address */
10#define PHYS_SDRAM_1_SIZE 0x10000000 /* Max 256 MB RAM */
11#define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM_1
12
13/* Environment */
14#define CONFIG_ENV_SIZE (16 * 1024)
15#define CONFIG_ENV_OVERWRITE
Marek Vasutf9727162013-09-20 16:14:13 +020016
17/* FEC Ethernet on SoC */
18#ifdef CONFIG_CMD_NET
19#define CONFIG_FEC_MXC
Marek Vasutf9727162013-09-20 16:14:13 +020020#endif
21
22/* SPI */
23#ifdef CONFIG_CMD_SPI
24#define CONFIG_DEFAULT_SPI_BUS 2
Marek Vasutf9727162013-09-20 16:14:13 +020025#define CONFIG_DEFAULT_SPI_MODE SPI_MODE_0
26
27/* SPI FLASH */
28#ifdef CONFIG_CMD_SF
Marek Vasutf9727162013-09-20 16:14:13 +020029#define CONFIG_SF_DEFAULT_BUS 2
30#define CONFIG_SF_DEFAULT_CS 0
31#define CONFIG_SF_DEFAULT_SPEED 40000000
32#define CONFIG_SF_DEFAULT_MODE SPI_MODE_0
33
34#define CONFIG_ENV_SPI_BUS 2
35#define CONFIG_ENV_SPI_CS 0
36#define CONFIG_ENV_SPI_MAX_HZ 40000000
37#define CONFIG_ENV_SPI_MODE SPI_MODE_0
38#endif
39
40#endif
41
42/* Boot Linux */
Marek Vasutf9727162013-09-20 16:14:13 +020043#define CONFIG_BOOTFILE "uImage"
Marek Vasutf9727162013-09-20 16:14:13 +020044#define CONFIG_BOOTCOMMAND "bootm"
45#define CONFIG_LOADADDR 0x42000000
46#define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
47
48/* Extra Environment */
49#define CONFIG_EXTRA_ENV_SETTINGS \
50 "update_spi_firmware_filename=u-boot.sb\0" \
51 "update_spi_firmware_maxsz=0x80000\0" \
52 "update_spi_firmware=" /* Update the SPI flash firmware */ \
53 "if sf probe 2:0 ; then " \
54 "if tftp ${update_spi_firmware_filename} ; then " \
55 "sf erase 0x0 +${filesize} ; " \
56 "sf write ${loadaddr} 0x0 ${filesize} ; " \
57 "fi ; " \
58 "fi\0"
59
60/* The rest of the configuration is shared */
61#include <configs/mxs.h>
62
63#endif /* __CONFIGS_BG0900_H__ */