blob: 9d2c106d46b9a9f3e3489406209cfb192ce11ab7 [file] [log] [blame]
Prafulla Wadaskar62634642009-07-16 20:58:00 +05301/*
DrEagle9ea48002014-09-07 18:01:21 +02002 * (C) Copyright 2009-2014
3 * Gerald Kerma <dreagle@doukki.net>
Prafulla Wadaskar62634642009-07-16 20:58:00 +05304 * Marvell Semiconductor <www.marvell.com>
5 * Written-by: Prafulla Wadaskar <prafulla@marvell.com>
6 *
Wolfgang Denkd79de1d2013-07-08 09:37:19 +02007 * SPDX-License-Identifier: GPL-2.0+
Prafulla Wadaskar62634642009-07-16 20:58:00 +05308 */
9
10#ifndef _CONFIG_SHEEVAPLUG_H
11#define _CONFIG_SHEEVAPLUG_H
12
13/*
Prafulla Wadaskar62634642009-07-16 20:58:00 +053014 * High Level Configuration Options (easy to change)
15 */
Prafulla Wadaskar62634642009-07-16 20:58:00 +053016#define CONFIG_FEROCEON_88FR131 1 /* CPU Core subversion */
Prafulla Wadaskar62634642009-07-16 20:58:00 +053017#define CONFIG_MACH_SHEEVAPLUG /* Machine type */
DrEagle511d72d2014-12-17 15:02:48 +010018
19/*
Prafulla Wadaskar62634642009-07-16 20:58:00 +053020 * Commands configuration
21 */
DrEagle32ca21f2014-12-17 15:02:44 +010022
Prafulla Wadaskar62634642009-07-16 20:58:00 +053023/*
Quentin Armitagebb7f7282015-10-28 00:47:18 +000024 * Standard filesystems
25 */
26#define CONFIG_SYS_MVFS
27
28/*
Quentin Armitagea99ac8a2015-10-28 00:47:21 +000029 * mv-plug-common.h should be defined after CMD configs since it used them
Prafulla Wadaskar32686292010-09-30 22:53:43 +053030 * to enable certain macros
Prafulla Wadaskar62634642009-07-16 20:58:00 +053031 */
Quentin Armitagea99ac8a2015-10-28 00:47:21 +000032#include "mv-plug-common.h"
Prafulla Wadaskar62634642009-07-16 20:58:00 +053033
34/*
35 * Environment variables configurations
36 */
37#ifdef CONFIG_CMD_NAND
38#define CONFIG_ENV_IS_IN_NAND 1
39#define CONFIG_ENV_SECT_SIZE 0x20000 /* 128K */
40#else
41#define CONFIG_ENV_IS_NOWHERE 1 /* if env in SDRAM */
42#endif
43/*
44 * max 4k env size is enough, but in case of nand
45 * it has to be rounded to sector size
46 */
47#define CONFIG_ENV_SIZE 0x20000 /* 128k */
DrEaglec2bc79d2014-09-07 18:01:20 +020048#define CONFIG_ENV_ADDR 0x80000
49#define CONFIG_ENV_OFFSET 0x80000 /* env starts here */
Prafulla Wadaskar62634642009-07-16 20:58:00 +053050
51/*
52 * Default environment variables
53 */
54#define CONFIG_BOOTCOMMAND "${x_bootcmd_kernel}; " \
55 "setenv bootargs ${x_bootargs} ${x_bootargs_root}; " \
Peter Korsgaard89132022016-01-17 18:23:44 +010056 "bootm 0x6400000;"
Prafulla Wadaskar62634642009-07-16 20:58:00 +053057
DrEagle711d28e2014-09-07 18:01:23 +020058#define CONFIG_MTDPARTS \
Peter Korsgaard3bbf6dd2016-01-17 18:23:43 +010059 "orion_nand:512K(uboot)," \
Peter Korsgaard280eb452016-01-17 18:23:45 +010060 "512K(env),4M(kernel)," \
61 "-(rootfs)\0"
Prafulla Wadaskar62634642009-07-16 20:58:00 +053062
63#define CONFIG_EXTRA_ENV_SETTINGS "x_bootargs=console" \
64 "=ttyS0,115200 mtdparts="CONFIG_MTDPARTS \
Peter Korsgaard280eb452016-01-17 18:23:45 +010065 "x_bootcmd_kernel=nand read 0x6400000 0x100000 0x400000\0" \
Prafulla Wadaskar62634642009-07-16 20:58:00 +053066 "x_bootcmd_usb=usb start\0" \
67 "x_bootargs_root=root=/dev/mtdblock3 rw rootfstype=jffs2\0"
68
DrEaglea0aa4a72014-09-07 18:01:22 +020069#define MTDIDS_DEFAULT "nand0=orion_nand"
70
71#define MTDPARTS_DEFAULT \
72 "mtdparts="CONFIG_MTDPARTS
73
Prafulla Wadaskar62634642009-07-16 20:58:00 +053074/*
Prafulla Wadaskar62634642009-07-16 20:58:00 +053075 * Ethernet Driver configuration
76 */
77#ifdef CONFIG_CMD_NET
Albert Aribaude91d7d32010-07-12 22:24:28 +020078#define CONFIG_MVGBE_PORTS {1, 0} /* enable port 0 only */
Prafulla Wadaskar62634642009-07-16 20:58:00 +053079#define CONFIG_PHY_BASE_ADR 0
Prafulla Wadaskar62634642009-07-16 20:58:00 +053080#endif /* CONFIG_CMD_NET */
81
82/*
DrEaglead881742014-07-25 21:07:30 +020083 * SDIO/MMC Card Configuration
84 */
85#ifdef CONFIG_CMD_MMC
DrEaglead881742014-07-25 21:07:30 +020086#define CONFIG_MVEBU_MMC
87#define CONFIG_SYS_MMC_BASE KW_SDIO_BASE
88#endif /* CONFIG_CMD_MMC */
89
90/*
DrEagle9ea48002014-09-07 18:01:21 +020091 * SATA driver configuration
92 */
Simon Glassb569a012017-05-17 03:25:30 -060093#ifdef CONFIG_IDE
DrEagle9ea48002014-09-07 18:01:21 +020094#define __io
95#define CONFIG_IDE_PREINIT
DrEagle9ea48002014-09-07 18:01:21 +020096#define CONFIG_MVSATA_IDE_USE_PORT0
97#define CONFIG_MVSATA_IDE_USE_PORT1
98#define CONFIG_SYS_ATA_IDE0_OFFSET MV_SATA_PORT0_OFFSET
99#define CONFIG_SYS_ATA_IDE1_OFFSET MV_SATA_PORT1_OFFSET
Simon Glassb569a012017-05-17 03:25:30 -0600100#endif /* CONFIG_IDE */
DrEagle9ea48002014-09-07 18:01:21 +0200101
Prafulla Wadaskar62634642009-07-16 20:58:00 +0530102#endif /* _CONFIG_SHEEVAPLUG_H */