blob: 78264bab55a6a641651a6392a3c1bb93de41aa37 [file] [log] [blame]
Heiko Schocher499c4982013-08-19 16:39:01 +02001/*
2 * siemens rut
3 * (C) Copyright 2013 Siemens Schweiz AG
4 * (C) Heiko Schocher, DENX Software Engineering, hs@denx.de.
5 *
6 * Based on:
7 * U-Boot file:/include/configs/am335x_evm.h
8 *
9 * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/
10 *
11 * SPDX-License-Identifier: GPL-2.0+
12 */
13
14#ifndef __CONFIG_RUT_H
15#define __CONFIG_RUT_H
16
17#define CONFIG_SIEMENS_RUT
18#define MACH_TYPE_RUT 4316
19#define CONFIG_SIEMENS_MACH_TYPE MACH_TYPE_RUT
20
21#include "siemens-am33x-common.h"
22
23#define CONFIG_SYS_MPUCLK 600
24#define RUT_IOCTRL_VAL 0x18b
25#define DDR_PLL_FREQ 303
26
27 /* Physical Memory Map */
28#define CONFIG_MAX_RAM_BANK_SIZE (256 << 20) /* 256 MiB */
29
30/* I2C Configuration */
31#define CONFIG_SYS_I2C_SPEED 100000
32
33#define CONFIG_SYS_I2C_EEPROM_ADDR 0x50
34#define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 2
35#define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 6 /* 64 byte pages */
36#define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS 10 /* take up to 10 msec */
37
38#define CONFIG_SYS_U_BOOT_MAX_SIZE_SECTORS 0x200
39
40#undef CONFIG_SPL_NET_SUPPORT
41#undef CONFIG_SPL_NET_VCI_STRING
42#undef CONFIG_SPL_ETH_SUPPORT
43
Heiko Schocher499c4982013-08-19 16:39:01 +020044#define CONFIG_PHY_NATSEMI
45
46#define CONFIG_FACTORYSET
47
Heiko Schocher499c4982013-08-19 16:39:01 +020048
49/* Watchdog */
50#define WATCHDOG_TRIGGER_GPIO 14
51
52#ifndef CONFIG_SPL_BUILD
53
Heiko Schocherd17c3fc2015-06-16 14:59:34 +020054/* Use common default */
55#define MTDPARTS_DEFAULT MTDPARTS_DEFAULT_V1
56
Heiko Schocher499c4982013-08-19 16:39:01 +020057/* Default env settings */
58#define CONFIG_EXTRA_ENV_SETTINGS \
59 "hostname=rut\0" \
Samuel Egli8069bfe2013-11-04 14:05:03 +010060 "nand_img_size=0x500000\0" \
61 "splashpos=m,m\0" \
Heiko Schocher499c4982013-08-19 16:39:01 +020062 "optargs=fixrtc --no-log consoleblank=0 \0" \
Heiko Schocherd17c3fc2015-06-16 14:59:34 +020063 CONFIG_ENV_SETTINGS_V1 \
64 CONFIG_ENV_SETTINGS_NAND_V1 \
Heiko Schocher499c4982013-08-19 16:39:01 +020065 "mmc_dev=0\0" \
66 "mmc_root=/dev/mmcblk0p2 rw\0" \
67 "mmc_root_fs_type=ext4 rootwait\0" \
68 "mmc_load_uimage=" \
69 "mmc rescan; " \
70 "setenv bootfile uImage;" \
71 "fatload mmc ${mmc_dev} ${kloadaddr} ${bootfile}\0" \
72 "loadbootenv=fatload mmc ${mmc_dev} ${loadaddr} ${bootenv}\0" \
73 "importbootenv=echo Importing environment from mmc ...; " \
74 "env import -t $loadaddr $filesize\0" \
75 "mmc_args=run bootargs_defaults;" \
76 "mtdparts default;" \
77 "setenv bootargs ${bootargs} " \
78 "root=${mmc_root} ${mtdparts}" \
79 "rootfstype=${mmc_root_fs_type} ip=${ip_method} " \
80 "eth=${ethaddr} " \
81 "\0" \
82 "mmc_boot=run mmc_args; " \
83 "run mmc_load_uimage; " \
84 "bootm ${kloadaddr}\0" \
85 ""
86
87#ifndef CONFIG_RESTORE_FLASH
88/* set to negative value for no autoboot */
89#define CONFIG_BOOTDELAY 3
90
91#define CONFIG_BOOTCOMMAND \
92 "if mmc rescan; then " \
93 "echo SD/MMC found on device ${mmc_dev};" \
94 "if run loadbootenv; then " \
95 "echo Loaded environment from ${bootenv};" \
96 "run importbootenv;" \
97 "fi;" \
98 "if test -n $uenvcmd; then " \
99 "echo Running uenvcmd ...;" \
100 "run uenvcmd;" \
101 "fi;" \
102 "if run mmc_load_uimage; then " \
103 "run mmc_args;" \
104 "bootm ${kloadaddr};" \
105 "fi;" \
106 "fi;" \
107 "run nand_boot;" \
Samuel Egli8069bfe2013-11-04 14:05:03 +0100108 "reset;"
Heiko Schocher499c4982013-08-19 16:39:01 +0200109
110#else
111#define CONFIG_BOOTDELAY 0
112
113#define CONFIG_BOOTCOMMAND \
114 "setenv autoload no; " \
115 "dhcp; " \
116 "if tftp 80000000 debrick.scr; then " \
117 "source 80000000; " \
118 "fi"
119#endif
120
121#endif /* CONFIG_SPL_BUILD */
122
123#ifdef CONFIG_SPL_BUILD
124#undef CONFIG_HW_WATCHDOG
125#endif
126
127#define CONFIG_VIDEO
128#if defined(CONFIG_VIDEO)
129#define CONFIG_VIDEO_DA8XX
130#define CONFIG_CFB_CONSOLE
131#define CONFIG_VGA_AS_SINGLE_DEVICE
132#define CONFIG_SPLASH_SCREEN
133#define CONFIG_SPLASH_SCREEN_ALIGN
134#define CONFIG_VIDEO_LOGO
135#define CONFIG_VIDEO_BMP_RLE8
136#define CONFIG_VIDEO_BMP_LOGO
137#define CONFIG_CMD_BMP
138#define DA8XX_LCD_CNTL_BASE LCD_CNTL_BASE
139
140#define CONFIG_SPI
141#define CONFIG_OMAP3_SPI
142
143#define BOARD_LCD_RESET 115 /* Bank 3 pin 19 */
144#define CONFIG_ARCH_EARLY_INIT_R
145#define CONFIG_FORMIKE
Samuel Egli8069bfe2013-11-04 14:05:03 +0100146#define DISPL_PLL_SPREAD_SPECTRUM
147#define CONFIG_SYS_CONSOLE_BG_COL 0xff
148#define CONFIG_SYS_CONSOLE_FG_COL 0x00
Heiko Schocher499c4982013-08-19 16:39:01 +0200149#endif
150
Heiko Schocherfaf2dc62014-11-18 11:51:06 +0100151#ifndef CONFIG_SPL_BUILD
152#define CONFIG_FIT
153#endif
154
Heiko Schocher499c4982013-08-19 16:39:01 +0200155#endif /* ! __CONFIG_RUT_H */