blob: 5f095677f180952ae6048687bf9aad3282a0fedf [file] [log] [blame]
Siddarth Gore11b10b02010-03-18 20:25:40 +05301/*
Gerald Kerma4658f452014-12-19 08:13:09 +01002 * (C) Copyright 2009-2014
3 * Gerald Kerma <dreagle@doukki.net>
Siddarth Gore11b10b02010-03-18 20:25:40 +05304 * Marvell Semiconductor <www.marvell.com>
5 * Written-by: Siddarth Gore <gores@marvell.com>
6 *
Wolfgang Denkd79de1d2013-07-08 09:37:19 +02007 * SPDX-License-Identifier: GPL-2.0+
Siddarth Gore11b10b02010-03-18 20:25:40 +05308 */
9
10#ifndef _CONFIG_GURUPLUG_H
11#define _CONFIG_GURUPLUG_H
12
Gerald Kerma4658f452014-12-19 08:13:09 +010013#define CONFIG_SYS_GENERIC_BOARD
14
Siddarth Gore11b10b02010-03-18 20:25:40 +053015/*
16 * Version number information
17 */
18#define CONFIG_IDENT_STRING "\nMarvell-GuruPlug"
19
20/*
21 * High Level Configuration Options (easy to change)
22 */
Siddarth Gore11b10b02010-03-18 20:25:40 +053023#define CONFIG_SHEEVA_88SV131 1 /* CPU Core subversion */
Siddarth Gore11b10b02010-03-18 20:25:40 +053024#define CONFIG_KW88F6281 1 /* SOC Name */
25#define CONFIG_MACH_GURUPLUG /* Machine type */
Siddarth Gore11b10b02010-03-18 20:25:40 +053026#define CONFIG_SKIP_LOWLEVEL_INIT /* disable board lowlevel_init */
Siddarth Gore11b10b02010-03-18 20:25:40 +053027
28/*
Gerald Kerma4658f452014-12-19 08:13:09 +010029 * Compression configuration
30 */
31#define CONFIG_BZIP2
32#define CONFIG_LZMA
33#define CONFIG_LZO
34
35/*
36 * Enable device tree support
37 */
38#define CONFIG_OF_LIBFDT
39
40/*
41 * Miscellaneous configurable options
42 */
43#define CONFIG_SYS_HUSH_PARSER /* use "hush" command parser */
44
45/*
Siddarth Gore11b10b02010-03-18 20:25:40 +053046 * Commands configuration
47 */
48#define CONFIG_SYS_NO_FLASH /* Declare no flash (NOR/SPI) */
Gerald Kerma4658f452014-12-19 08:13:09 +010049#define CONFIG_CMD_BOOTZ
Siddarth Gore11b10b02010-03-18 20:25:40 +053050#define CONFIG_CMD_DHCP
51#define CONFIG_CMD_ENV
Gerald Kerma4658f452014-12-19 08:13:09 +010052#define CONFIG_CMD_IDE
53#define CONFIG_CMD_MII
Siddarth Gore11b10b02010-03-18 20:25:40 +053054#define CONFIG_CMD_NAND
55#define CONFIG_CMD_PING
56#define CONFIG_CMD_USB
Gerald Kerma4658f452014-12-19 08:13:09 +010057#define CONFIG_CMD_FAT
Siddarth Gore11b10b02010-03-18 20:25:40 +053058
59/*
Prafulla Wadaskar32686292010-09-30 22:53:43 +053060 * mv-common.h should be defined after CMD configs since it used them
61 * to enable certain macros
Siddarth Gore11b10b02010-03-18 20:25:40 +053062 */
Prafulla Wadaskar32686292010-09-30 22:53:43 +053063#include "mv-common.h"
Siddarth Gore11b10b02010-03-18 20:25:40 +053064
65/*
66 * Environment variables configurations
67 */
68#ifdef CONFIG_CMD_NAND
69#define CONFIG_ENV_IS_IN_NAND 1
70#define CONFIG_ENV_SECT_SIZE 0x20000 /* 128K */
71#else
72#define CONFIG_ENV_IS_NOWHERE 1 /* if env in SDRAM */
73#endif
74/*
75 * max 4k env size is enough, but in case of nand
76 * it has to be rounded to sector size
77 */
78#define CONFIG_ENV_SIZE 0x20000 /* 128k */
Gerald Kerma4658f452014-12-19 08:13:09 +010079#define CONFIG_ENV_OFFSET 0xE0000 /* env starts here */
Siddarth Gore11b10b02010-03-18 20:25:40 +053080
81/*
82 * Default environment variables
83 */
Gerald Kerma4658f452014-12-19 08:13:09 +010084#define CONFIG_BOOTCOMMAND \
85 "setenv bootargs ${console} ${mtdparts} ${bootargs_root}; " \
86 "ubi part root; " \
87 "ubifsmount ubi:rootfs; " \
88 "ubifsload 0x800000 ${kernel}; " \
89 "ubifsload 0x700000 ${fdt}; " \
90 "ubifsumount; " \
91 "fdt addr 0x700000; fdt resize; fdt chosen; " \
92 "bootz 0x800000 - 0x700000"
93
94#define CONFIG_MTDPARTS \
95 "mtdparts=orion_nand:" \
96 "896K(uboot),128K(uboot_env)," \
97 "-@1M(root)\0"
98
99#define CONFIG_EXTRA_ENV_SETTINGS \
100 "console=console=ttyS0,115200\0" \
101 "mtdids=nand0=orion_nand\0" \
102 "mtdparts="CONFIG_MTDPARTS \
103 "kernel=/boot/zImage\0" \
104 "fdt=/boot/guruplug-server-plus.dtb\0" \
105 "bootargs_root=ubi.mtd=2 root=ubi0:rootfs rootfstype=ubifs rw\0"
Siddarth Gore11b10b02010-03-18 20:25:40 +0530106
Gerald Kerma4658f452014-12-19 08:13:09 +0100107#define MTDIDS_DEFAULT "nand0=orion_nand"
108
109#define MTDPARTS_DEFAULT \
110 "mtdparts="CONFIG_MTDPARTS
Siddarth Gore11b10b02010-03-18 20:25:40 +0530111
112/*
Siddarth Gore11b10b02010-03-18 20:25:40 +0530113 * Ethernet Driver configuration
114 */
115#ifdef CONFIG_CMD_NET
Albert Aribaude91d7d32010-07-12 22:24:28 +0200116#define CONFIG_MVGBE_PORTS {1, 1} /* enable both ports */
Siddarth Gore11b10b02010-03-18 20:25:40 +0530117#define CONFIG_PHY_BASE_ADR 0
Siddarth Gore11b10b02010-03-18 20:25:40 +0530118#endif /* CONFIG_CMD_NET */
119
120/*
Prafulla Wadaskar32686292010-09-30 22:53:43 +0530121 * SATA Driver configuration
Siddarth Gore11b10b02010-03-18 20:25:40 +0530122 */
Prafulla Wadaskar32686292010-09-30 22:53:43 +0530123#ifdef CONFIG_MVSATA_IDE
124#define CONFIG_SYS_ATA_IDE0_OFFSET MV_SATA_PORT0_OFFSET
125#endif /*CONFIG_MVSATA_IDE*/
Siddarth Gore11b10b02010-03-18 20:25:40 +0530126
Gerald Kerma4658f452014-12-19 08:13:09 +0100127/*
128 * File system
129 */
130#define CONFIG_CMD_EXT2
131#define CONFIG_CMD_EXT4
132#define CONFIG_CMD_FAT
133#define CONFIG_CMD_JFFS2
134#define CONFIG_CMD_UBI
135#define CONFIG_CMD_UBIFS
136#define CONFIG_RBTREE
137#define CONFIG_MTD_DEVICE
138#define CONFIG_MTD_PARTITIONS
139#define CONFIG_CMD_MTDPARTS
140
Siddarth Gore11b10b02010-03-18 20:25:40 +0530141#define CONFIG_SYS_ALT_MEMTEST
142
143#endif /* _CONFIG_GURUPLUG_H */