blob: 41e162c2d08bf91a4e17031b30f2e6b969d0e65c [file] [log] [blame]
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +09001/*
2 * include/configs/koelsch.h
3 *
4 * Copyright (C) 2013 Renesas Electronics Corporation
5 *
6 * SPDX-License-Identifier: GPL-2.0
7 */
8
9#ifndef __KOELSCH_H
10#define __KOELSCH_H
11
12#undef DEBUG
13#define CONFIG_ARMV7
14#define CONFIG_R8A7791
15#define CONFIG_RMOBILE
16#define CONFIG_RMOBILE_BOARD_STRING "Koelsch"
17#define CONFIG_SH_GPIO_PFC
18
19#include <asm/arch/rmobile.h>
20
Nobuhiro Iwamatsu90362c02013-10-20 20:37:17 +090021#define CONFIG_CMD_EDITENV
22#define CONFIG_CMD_SAVEENV
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +090023#define CONFIG_CMD_MEMORY
24#define CONFIG_CMD_DFL
25#define CONFIG_CMD_SDRAM
26#define CONFIG_CMD_RUN
27#define CONFIG_CMD_LOADS
Nobuhiro Iwamatsu90362c02013-10-20 20:37:17 +090028#define CONFIG_CMD_NET
29#define CONFIG_CMD_MII
30#define CONFIG_CMD_PING
31#define CONFIG_CMD_DHCP
32#define CONFIG_CMD_NFS
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +090033#define CONFIG_CMD_BOOTZ
Nobuhiro Iwamatsuaa44ae32014-03-27 14:13:06 +090034#define CONFIG_CMD_USB
Nobuhiro Iwamatsufd77b2e2014-03-28 17:29:45 +090035#define CONFIG_CMD_FAT
Nobuhiro Iwamatsuc71b4dd2014-01-08 10:32:24 +090036
Nobuhiro Iwamatsuc71b4dd2014-01-08 10:32:24 +090037#define CONFIG_CMD_SF
38#define CONFIG_CMD_SPI
39#define CONFIG_SYS_TEXT_BASE 0xE6304000
Nobuhiro Iwamatsue1ee3742014-04-07 17:11:52 +090040#define CONFIG_SYS_THUMB_BUILD
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +090041
Nobuhiro Iwamatsufd77b2e2014-03-28 17:29:45 +090042/* Support File sytems */
43#define CONFIG_DOS_PARTITION
44#define CONFIG_SUPPORT_VFAT
45
46
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +090047#define CONFIG_CMDLINE_TAG
48#define CONFIG_SETUP_MEMORY_TAGS
49#define CONFIG_INITRD_TAG
50#define CONFIG_CMDLINE_EDITING
51
52#define CONFIG_OF_LIBFDT
53#define BOARD_LATE_INIT
54
55#define CONFIG_BAUDRATE 38400
56#define CONFIG_BOOTDELAY 3
57#define CONFIG_BOOTARGS ""
58
59#define CONFIG_VERSION_VARIABLE
60#undef CONFIG_SHOW_BOOT_PROGRESS
61
62#define CONFIG_ARCH_CPU_INIT
63#define CONFIG_DISPLAY_CPUINFO
64#define CONFIG_DISPLAY_BOARDINFO
65#define CONFIG_BOARD_EARLY_INIT_F
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +090066#define CONFIG_TMU_TIMER
67
68/* STACK */
69#define CONFIG_SYS_INIT_SP_ADDR 0xE633fffc
70#define STACK_AREA_SIZE 0xC000
71#define LOW_LEVEL_MERAM_STACK \
72 (CONFIG_SYS_INIT_SP_ADDR + STACK_AREA_SIZE - 4)
73
74/* MEMORY */
75#define KOELSCH_SDRAM_BASE 0x40000000
76#define KOELSCH_SDRAM_SIZE (2048u * 1024 * 1024)
77#define KOELSCH_UBOOT_SDRAM_SIZE (512 * 1024 * 1024)
78
79#define CONFIG_SYS_LONGHELP
80#define CONFIG_SYS_CBSIZE 256
81#define CONFIG_SYS_PBSIZE 256
82#define CONFIG_SYS_MAXARGS 16
83#define CONFIG_SYS_BARGSIZE 512
84#define CONFIG_SYS_BAUDRATE_TABLE { 38400, 115200 }
85
86/* SCIF */
87#define CONFIG_SCIF_CONSOLE
88#define CONFIG_CONS_SCIF0
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +090089#undef CONFIG_SYS_CONSOLE_INFO_QUIET
90#undef CONFIG_SYS_CONSOLE_OVERWRITE_ROUTINE
91#undef CONFIG_SYS_CONSOLE_ENV_OVERWRITE
92
93#define CONFIG_SYS_MEMTEST_START (KOELSCH_SDRAM_BASE)
94#define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + \
95 504 * 1024 * 1024)
96#undef CONFIG_SYS_ALT_MEMTEST
97#undef CONFIG_SYS_MEMTEST_SCRATCH
98#undef CONFIG_SYS_LOADS_BAUD_CHANGE
99
100#define CONFIG_SYS_SDRAM_BASE (KOELSCH_SDRAM_BASE)
101#define CONFIG_SYS_SDRAM_SIZE (KOELSCH_UBOOT_SDRAM_SIZE)
102#define CONFIG_SYS_LOAD_ADDR (CONFIG_SYS_SDRAM_BASE + 0x7fc0)
103#define CONFIG_NR_DRAM_BANKS 1
104
105#define CONFIG_SYS_MONITOR_BASE 0x00000000
106#define CONFIG_SYS_MONITOR_LEN (256 * 1024)
107#define CONFIG_SYS_MALLOC_LEN (1 * 1024 * 1024)
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +0900108#define CONFIG_SYS_BOOTMAPSZ (8 * 1024 * 1024)
109
110/* FLASH */
Nobuhiro Iwamatsuc71b4dd2014-01-08 10:32:24 +0900111#define CONFIG_SYS_NO_FLASH
112#define CONFIG_SPI
113#define CONFIG_SH_QSPI
114#define CONFIG_SPI_FLASH
115#define CONFIG_SPI_FLASH_BAR
116#define CONFIG_SPI_FLASH_SPANSION
117/* ENV setting */
118#define CONFIG_ENV_IS_IN_SPI_FLASH
119#define CONFIG_ENV_ADDR 0xC0000
120
Nobuhiro Iwamatsuc71b4dd2014-01-08 10:32:24 +0900121/* Common ENV setting */
122#define CONFIG_ENV_OVERWRITE
123#define CONFIG_ENV_SECT_SIZE (256 * 1024)
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +0900124#define CONFIG_ENV_OFFSET (CONFIG_ENV_ADDR)
125#define CONFIG_ENV_SIZE (CONFIG_ENV_SECT_SIZE)
126#define CONFIG_ENV_SIZE_REDUND (CONFIG_SYS_MONITOR_LEN)
127
Nobuhiro Iwamatsu90362c02013-10-20 20:37:17 +0900128/* SH Ether */
129#define CONFIG_NET_MULTI
130#define CONFIG_SH_ETHER
131#define CONFIG_SH_ETHER_USE_PORT 0
132#define CONFIG_SH_ETHER_PHY_ADDR 0x1
133#define CONFIG_SH_ETHER_PHY_MODE PHY_INTERFACE_MODE_RMII
134#define CONFIG_SH_ETHER_CACHE_WRITEBACK
135#define CONFIG_SH_ETHER_CACHE_INVALIDATE
136#define CONFIG_PHYLIB
137#define CONFIG_PHY_MICREL
138#define CONFIG_BITBANGMII
139#define CONFIG_BITBANGMII_MULTI
140#define CONFIG_SH_ETHER_ALIGNE_SIZE 64
141
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +0900142/* Board Clock */
Nobuhiro Iwamatsuae8e1d92014-03-31 11:06:46 +0900143#define RMOBILE_XTAL_CLK 20000000u
144#define CONFIG_SYS_CLK_FREQ RMOBILE_XTAL_CLK
145#define CONFIG_SH_TMU_CLK_FREQ (CONFIG_SYS_CLK_FREQ / 2)
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +0900146#define CONFIG_SH_SCIF_CLK_FREQ 14745600
147#define CONFIG_SYS_TMU_CLK_DIV 4
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +0900148
Nobuhiro Iwamatsubb611cc2013-09-11 15:04:33 +0900149/* i2c */
150#define CONFIG_CMD_I2C
151#define CONFIG_SYS_I2C
152#define CONFIG_SYS_I2C_SH
153#define CONFIG_SYS_I2C_SLAVE 0x7F
154#define CONFIG_SYS_I2C_SH_NUM_CONTROLLERS 3
155#define CONFIG_SYS_I2C_SH_BASE0 0xE6500000
156#define CONFIG_SYS_I2C_SH_SPEED0 400000
157#define CONFIG_SYS_I2C_SH_BASE1 0xE6510000
158#define CONFIG_SYS_I2C_SH_SPEED1 400000
159#define CONFIG_SYS_I2C_SH_BASE2 0xE60B0000
160#define CONFIG_SYS_I2C_SH_SPEED2 400000
161#define CONFIG_SH_I2C_DATA_HIGH 4
162#define CONFIG_SH_I2C_DATA_LOW 5
163#define CONFIG_SH_I2C_CLOCK 10000000
164
Nobuhiro Iwamatsub8f383b2013-10-10 10:48:20 +0900165#define CONFIG_SYS_I2C_POWERIC_ADDR 0x58 /* da9063 */
166
Nobuhiro Iwamatsuaa44ae32014-03-27 14:13:06 +0900167/* USB */
168#define CONFIG_USB_EHCI
169#define CONFIG_USB_EHCI_RMOBILE
170#define CONFIG_USB_MAX_CONTROLLER_COUNT 3
171#define CONFIG_USB_STORAGE
172
Nobuhiro Iwamatsu1251e492013-11-21 17:07:46 +0900173#endif /* __KOELSCH_H */