blob: 3f52f117581cf1c4725a992f965511fa272bbd01 [file] [log] [blame]
Siddarth Gore16b76702010-03-18 20:25:40 +05301/*
Gerald Kerma361b3d82014-12-19 08:13:09 +01002 * (C) Copyright 2009-2014
3 * Gerald Kerma <dreagle@doukki.net>
Siddarth Gore16b76702010-03-18 20:25:40 +05304 * Marvell Semiconductor <www.marvell.com>
5 * Written-by: Siddarth Gore <gores@marvell.com>
6 *
Wolfgang Denk1a459662013-07-08 09:37:19 +02007 * SPDX-License-Identifier: GPL-2.0+
Siddarth Gore16b76702010-03-18 20:25:40 +05308 */
9
10#ifndef _CONFIG_GURUPLUG_H
11#define _CONFIG_GURUPLUG_H
12
Gerald Kerma361b3d82014-12-19 08:13:09 +010013
Siddarth Gore16b76702010-03-18 20:25:40 +053014/*
15 * Version number information
16 */
17#define CONFIG_IDENT_STRING "\nMarvell-GuruPlug"
18
19/*
20 * High Level Configuration Options (easy to change)
21 */
Siddarth Gore16b76702010-03-18 20:25:40 +053022#define CONFIG_SHEEVA_88SV131 1 /* CPU Core subversion */
Siddarth Gore16b76702010-03-18 20:25:40 +053023#define CONFIG_KW88F6281 1 /* SOC Name */
24#define CONFIG_MACH_GURUPLUG /* Machine type */
Siddarth Gore16b76702010-03-18 20:25:40 +053025#define CONFIG_SKIP_LOWLEVEL_INIT /* disable board lowlevel_init */
Siddarth Gore16b76702010-03-18 20:25:40 +053026
Quentin Armitage64561632015-10-28 00:47:15 +000027/* Add target to build it automatically upon "make" */
28#define CONFIG_BUILD_TARGET "u-boot.kwb"
29
Siddarth Gore16b76702010-03-18 20:25:40 +053030/*
Gerald Kerma361b3d82014-12-19 08:13:09 +010031 * Compression configuration
32 */
33#define CONFIG_BZIP2
34#define CONFIG_LZMA
35#define CONFIG_LZO
36
37/*
38 * Enable device tree support
39 */
40#define CONFIG_OF_LIBFDT
41
42/*
Siddarth Gore16b76702010-03-18 20:25:40 +053043 * Commands configuration
44 */
45#define CONFIG_SYS_NO_FLASH /* Declare no flash (NOR/SPI) */
Gerald Kerma361b3d82014-12-19 08:13:09 +010046#define CONFIG_CMD_BOOTZ
Quentin Armitage64561632015-10-28 00:47:15 +000047#define CONFIG_CMD_DATE
Siddarth Gore16b76702010-03-18 20:25:40 +053048#define CONFIG_CMD_ENV
Gerald Kerma361b3d82014-12-19 08:13:09 +010049#define CONFIG_CMD_IDE
50#define CONFIG_CMD_MII
Siddarth Gore16b76702010-03-18 20:25:40 +053051
52/*
Prafulla Wadaskar54e999a2010-09-30 22:53:43 +053053 * mv-common.h should be defined after CMD configs since it used them
54 * to enable certain macros
Siddarth Gore16b76702010-03-18 20:25:40 +053055 */
Prafulla Wadaskar54e999a2010-09-30 22:53:43 +053056#include "mv-common.h"
Siddarth Gore16b76702010-03-18 20:25:40 +053057
58/*
59 * Environment variables configurations
60 */
61#ifdef CONFIG_CMD_NAND
62#define CONFIG_ENV_IS_IN_NAND 1
63#define CONFIG_ENV_SECT_SIZE 0x20000 /* 128K */
64#else
65#define CONFIG_ENV_IS_NOWHERE 1 /* if env in SDRAM */
66#endif
67/*
68 * max 4k env size is enough, but in case of nand
69 * it has to be rounded to sector size
70 */
71#define CONFIG_ENV_SIZE 0x20000 /* 128k */
Gerald Kerma361b3d82014-12-19 08:13:09 +010072#define CONFIG_ENV_OFFSET 0xE0000 /* env starts here */
Siddarth Gore16b76702010-03-18 20:25:40 +053073
74/*
75 * Default environment variables
76 */
Gerald Kerma361b3d82014-12-19 08:13:09 +010077#define CONFIG_BOOTCOMMAND \
78 "setenv bootargs ${console} ${mtdparts} ${bootargs_root}; " \
79 "ubi part root; " \
80 "ubifsmount ubi:rootfs; " \
81 "ubifsload 0x800000 ${kernel}; " \
82 "ubifsload 0x700000 ${fdt}; " \
83 "ubifsumount; " \
84 "fdt addr 0x700000; fdt resize; fdt chosen; " \
85 "bootz 0x800000 - 0x700000"
Siddarth Gore16b76702010-03-18 20:25:40 +053086
Gerald Kerma361b3d82014-12-19 08:13:09 +010087#define CONFIG_MTDPARTS \
88 "mtdparts=orion_nand:" \
89 "896K(uboot),128K(uboot_env)," \
90 "-@1M(root)\0"
91
92#define CONFIG_EXTRA_ENV_SETTINGS \
93 "console=console=ttyS0,115200\0" \
94 "mtdids=nand0=orion_nand\0" \
95 "mtdparts="CONFIG_MTDPARTS \
96 "kernel=/boot/zImage\0" \
97 "fdt=/boot/guruplug-server-plus.dtb\0" \
98 "bootargs_root=ubi.mtd=2 root=ubi0:rootfs rootfstype=ubifs rw\0"
99
100#define MTDIDS_DEFAULT "nand0=orion_nand"
101
102#define MTDPARTS_DEFAULT \
103 "mtdparts="CONFIG_MTDPARTS
Siddarth Gore16b76702010-03-18 20:25:40 +0530104
105/*
Siddarth Gore16b76702010-03-18 20:25:40 +0530106 * Ethernet Driver configuration
107 */
108#ifdef CONFIG_CMD_NET
Albert Aribaudd44265a2010-07-12 22:24:28 +0200109#define CONFIG_MVGBE_PORTS {1, 1} /* enable both ports */
Siddarth Gore16b76702010-03-18 20:25:40 +0530110#define CONFIG_PHY_BASE_ADR 0
Siddarth Gore16b76702010-03-18 20:25:40 +0530111#endif /* CONFIG_CMD_NET */
112
113/*
Prafulla Wadaskar54e999a2010-09-30 22:53:43 +0530114 * SATA Driver configuration
Siddarth Gore16b76702010-03-18 20:25:40 +0530115 */
Prafulla Wadaskar54e999a2010-09-30 22:53:43 +0530116#ifdef CONFIG_MVSATA_IDE
117#define CONFIG_SYS_ATA_IDE0_OFFSET MV_SATA_PORT0_OFFSET
118#endif /*CONFIG_MVSATA_IDE*/
Siddarth Gore16b76702010-03-18 20:25:40 +0530119
Gerald Kerma361b3d82014-12-19 08:13:09 +0100120/*
Quentin Armitage64561632015-10-28 00:47:15 +0000121 * RTC driver configuration
122 */
123#ifdef CONFIG_CMD_DATE
124#define CONFIG_RTC_MV
125#endif /* CONFIG_CMD_DATE */
126
127/*
Gerald Kerma361b3d82014-12-19 08:13:09 +0100128 * 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 Gore16b76702010-03-18 20:25:40 +0530141#define CONFIG_SYS_ALT_MEMTEST
142
143#endif /* _CONFIG_GURUPLUG_H */