blob: 7fa0c5356c1c16a334af02e54c8f0fcd59ba5b85 [file] [log] [blame]
Luka Perkov2a3ce882012-04-17 09:22:17 +00001/*
2 * Copyright (C) 2011-2012
3 * Gerald Kerma <dreagle@doukki.net>
Luka Perkove91505d2012-12-03 03:24:15 +00004 * Luka Perkov <luka@openwrt.org>
Luka Perkov2a3ce882012-04-17 09:22:17 +00005 *
Wolfgang Denkd79de1d2013-07-08 09:37:19 +02006 * SPDX-License-Identifier: GPL-2.0+
Luka Perkov2a3ce882012-04-17 09:22:17 +00007 */
8
9#ifndef _CONFIG_IB62x0_H
10#define _CONFIG_IB62x0_H
11
12/*
13 * Version number information
14 */
15#define CONFIG_IDENT_STRING " RaidSonic ICY BOX IB-NAS62x0"
16
17/*
18 * High level configuration options
19 */
20#define CONFIG_FEROCEON_88FR131 /* CPU Core subversion */
21#define CONFIG_KIRKWOOD /* SOC Family Name */
22#define CONFIG_KW88F6281 /* SOC Name */
23#define CONFIG_SKIP_LOWLEVEL_INIT /* disable board lowlevel_init */
24
25/*
26 * Machine type
27 */
28#define CONFIG_MACH_TYPE MACH_TYPE_NAS6210
29
30/*
31 * Compression configuration
32 */
33#define CONFIG_BZIP2
34#define CONFIG_LZMA
35#define CONFIG_LZO
36
37/*
38 * Commands configuration
39 */
40#define CONFIG_SYS_NO_FLASH /* declare no flash (NOR/SPI) */
41#define CONFIG_SYS_MVFS
42#include <config_cmd_default.h>
43#define CONFIG_CMD_ENV
44#define CONFIG_CMD_IDE
45#define CONFIG_CMD_MII
46#define CONFIG_CMD_NAND
47#define CONFIG_CMD_PING
48#define CONFIG_CMD_USB
49
50/*
51 * mv-common.h should be defined after CMD configs since it used them
52 * to enable certain macros
53 */
54#include "mv-common.h"
55
56#undef CONFIG_SYS_PROMPT
57#define CONFIG_SYS_PROMPT "ib62x0 => "
58
59/*
60 * Environment variables configuration
61 */
62#ifdef CONFIG_CMD_NAND
63#define CONFIG_ENV_IS_IN_NAND
64#define CONFIG_ENV_SECT_SIZE 0x20000
65#else
66#define CONFIG_ENV_IS_NOWHERE
67#endif
68#define CONFIG_ENV_SIZE 0x20000
69#define CONFIG_ENV_OFFSET 0x80000
70
71/*
72 * Default environment variables
73 */
74#define CONFIG_BOOTCOMMAND \
75 "setenv bootargs ${console} ${mtdparts} ${bootargs_root}; " \
76 "ubi part root; " \
Joe Hershberger108458a2012-11-01 16:54:18 +000077 "ubifsmount ubi:root; " \
Luka Perkov2a3ce882012-04-17 09:22:17 +000078 "ubifsload 0x800000 ${kernel}; " \
79 "ubifsload 0x1100000 ${initrd}; " \
80 "bootm 0x800000 0x1100000"
81
82#define CONFIG_MTDPARTS \
83 "mtdparts=orion_nand:" \
84 "0x80000@0x0(uboot)," \
85 "0x20000@0x80000(uboot_env)," \
86 "-@0xa0000(root)\0"
87
88#define CONFIG_EXTRA_ENV_SETTINGS \
89 "console=console=ttyS0,115200\0" \
90 "mtdids=nand0=orion_nand\0" \
91 "mtdparts="CONFIG_MTDPARTS \
92 "kernel=/boot/uImage\0" \
93 "initrd=/boot/uInitrd\0" \
94 "bootargs_root=ubi.mtd=2 root=ubi0:root rootfstype=ubifs\0"
95
96/*
97 * Ethernet driver configuration
98 */
99#ifdef CONFIG_CMD_NET
100#define CONFIG_MVGBE_PORTS {1, 0} /* enable port 0 only */
101#define CONFIG_PHY_BASE_ADR 0
102#undef CONFIG_RESET_PHY_R
103#endif /* CONFIG_CMD_NET */
104
105/*
106 * SATA driver configuration
107 */
108#ifdef CONFIG_CMD_IDE
109#define __io
110#define CONFIG_IDE_PREINIT
111#define CONFIG_DOS_PARTITION
112#define CONFIG_MVSATA_IDE_USE_PORT0
113#define CONFIG_MVSATA_IDE_USE_PORT1
114#define CONFIG_SYS_ATA_IDE0_OFFSET MV_SATA_PORT0_OFFSET
115#define CONFIG_SYS_ATA_IDE1_OFFSET MV_SATA_PORT1_OFFSET
116#endif /* CONFIG_CMD_IDE */
117
118/*
119 * RTC driver configuration
120 */
121#ifdef CONFIG_CMD_DATE
122#define CONFIG_RTC_MV
123#endif /* CONFIG_CMD_DATE */
124
125/*
126 * File system
127 */
128#define CONFIG_CMD_EXT2
129#define CONFIG_CMD_FAT
130#define CONFIG_CMD_JFFS2
131#define CONFIG_CMD_UBI
132#define CONFIG_CMD_UBIFS
133#define CONFIG_RBTREE
134#define CONFIG_MTD_DEVICE
135#define CONFIG_MTD_PARTITIONS
136#define CONFIG_CMD_MTDPARTS
137
138#endif /* _CONFIG_IB62x0_H */