xref: /openbmc/u-boot/include/configs/sheevaplug.h (revision 9ecb0c41)
1 /*
2  * (C) Copyright 2009-2014
3  * Gerald Kerma <dreagle@doukki.net>
4  * Marvell Semiconductor <www.marvell.com>
5  * Written-by: Prafulla Wadaskar <prafulla@marvell.com>
6  *
7  * SPDX-License-Identifier:	GPL-2.0+
8  */
9 
10 #ifndef _CONFIG_SHEEVAPLUG_H
11 #define _CONFIG_SHEEVAPLUG_H
12 
13 
14 /*
15  * Version number information
16  */
17 #define CONFIG_IDENT_STRING	"\nMarvell-Sheevaplug"
18 
19 /*
20  * High Level Configuration Options (easy to change)
21  */
22 #define CONFIG_FEROCEON_88FR131	1	/* CPU Core subversion */
23 #define CONFIG_MACH_SHEEVAPLUG	/* Machine type */
24 
25 /*
26  * Commands configuration
27  */
28 #define CONFIG_CMD_MMC
29 
30 /*
31  * Standard filesystems
32  */
33 #define CONFIG_SYS_MVFS
34 
35 /*
36  * mv-plug-common.h should be defined after CMD configs since it used them
37  * to enable certain macros
38  */
39 #include "mv-plug-common.h"
40 
41 /*
42  *  Environment variables configurations
43  */
44 #ifdef CONFIG_CMD_NAND
45 #define CONFIG_ENV_IS_IN_NAND		1
46 #define CONFIG_ENV_SECT_SIZE		0x20000	/* 128K */
47 #else
48 #define CONFIG_ENV_IS_NOWHERE		1	/* if env in SDRAM */
49 #endif
50 /*
51  * max 4k env size is enough, but in case of nand
52  * it has to be rounded to sector size
53  */
54 #define CONFIG_ENV_SIZE			0x20000	/* 128k */
55 #define CONFIG_ENV_ADDR			0x80000
56 #define CONFIG_ENV_OFFSET		0x80000	/* env starts here */
57 
58 /*
59  * Default environment variables
60  */
61 #define CONFIG_BOOTCOMMAND		"${x_bootcmd_kernel}; "	\
62 	"setenv bootargs ${x_bootargs} ${x_bootargs_root}; "	\
63 	"bootm 0x6400000;"
64 
65 #define CONFIG_MTDPARTS		\
66 	"orion_nand:512K(uboot),"				\
67 	"512K(env),4M(kernel),"					\
68 	"-(rootfs)\0"
69 
70 #define CONFIG_EXTRA_ENV_SETTINGS	"x_bootargs=console"	\
71 	"=ttyS0,115200 mtdparts="CONFIG_MTDPARTS	\
72 	"x_bootcmd_kernel=nand read 0x6400000 0x100000 0x400000\0" \
73 	"x_bootcmd_usb=usb start\0" \
74 	"x_bootargs_root=root=/dev/mtdblock3 rw rootfstype=jffs2\0"
75 
76 #define MTDIDS_DEFAULT	"nand0=orion_nand"
77 
78 #define MTDPARTS_DEFAULT	\
79 	"mtdparts="CONFIG_MTDPARTS
80 
81 /*
82  * Ethernet Driver configuration
83  */
84 #ifdef CONFIG_CMD_NET
85 #define CONFIG_MVGBE_PORTS	{1, 0}	/* enable port 0 only */
86 #define CONFIG_PHY_BASE_ADR	0
87 #endif /* CONFIG_CMD_NET */
88 
89 /*
90  * SDIO/MMC Card Configuration
91  */
92 #ifdef CONFIG_CMD_MMC
93 #define CONFIG_MMC
94 #define CONFIG_GENERIC_MMC
95 #define CONFIG_MVEBU_MMC
96 #define CONFIG_SYS_MMC_BASE KW_SDIO_BASE
97 #endif /* CONFIG_CMD_MMC */
98 
99 /*
100  * SATA driver configuration
101  */
102 #ifdef CONFIG_CMD_IDE
103 #define __io
104 #define CONFIG_IDE_PREINIT
105 #define CONFIG_DOS_PARTITION
106 #define CONFIG_MVSATA_IDE_USE_PORT0
107 #define CONFIG_MVSATA_IDE_USE_PORT1
108 #define CONFIG_SYS_ATA_IDE0_OFFSET	MV_SATA_PORT0_OFFSET
109 #define CONFIG_SYS_ATA_IDE1_OFFSET	MV_SATA_PORT1_OFFSET
110 #endif /* CONFIG_CMD_IDE */
111 
112 #endif /* _CONFIG_SHEEVAPLUG_H */
113