xref: /openbmc/u-boot/include/configs/rut.h (revision 8f240a3b)
1 /*
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_MACH_TYPE	MACH_TYPE_RUT
18 
19 #include "siemens-am33x-common.h"
20 
21 #define RUT_IOCTRL_VAL	0x18b
22 #define DDR_PLL_FREQ	303
23 
24  /* Physical Memory Map */
25 #define CONFIG_MAX_RAM_BANK_SIZE	(256 << 20) /* 256 MiB */
26 
27 /* I2C Configuration */
28 #define CONFIG_SYS_I2C_SPEED		100000
29 
30 #define CONFIG_SYS_I2C_EEPROM_ADDR              0x50
31 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN          2
32 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS       6       /* 64 byte pages */
33 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS   10      /* take up to 10 msec */
34 
35 #define CONFIG_PHY_NATSEMI
36 
37 #define CONFIG_FACTORYSET
38 
39 /* Watchdog */
40 #define WATCHDOG_TRIGGER_GPIO	14
41 
42 #ifndef CONFIG_SPL_BUILD
43 
44 /* Use common default */
45 
46 /* Default env settings */
47 #define CONFIG_EXTRA_ENV_SETTINGS \
48 	"hostname=rut\0" \
49 	"ubi_off=2048\0"\
50 	"nand_img_size=0x500000\0" \
51 	"splashpos=m,m\0" \
52 	"optargs=fixrtc --no-log consoleblank=0 \0" \
53 	CONFIG_ENV_SETTINGS_V1 \
54 	CONFIG_ENV_SETTINGS_NAND_V1 \
55 	"mmc_dev=0\0" \
56 	"mmc_root=/dev/mmcblk0p2 rw\0" \
57 	"mmc_root_fs_type=ext4 rootwait\0" \
58 	"mmc_load_uimage=" \
59 		"mmc rescan; " \
60 		"setenv bootfile uImage;" \
61 		"fatload mmc ${mmc_dev} ${kloadaddr} ${bootfile}\0" \
62 	"loadbootenv=fatload mmc ${mmc_dev} ${loadaddr} ${bootenv}\0" \
63 	"importbootenv=echo Importing environment from mmc ...; " \
64 		"env import -t $loadaddr $filesize\0" \
65 	"mmc_args=run bootargs_defaults;" \
66 		"mtdparts default;" \
67 		"setenv bootargs ${bootargs} " \
68 		"root=${mmc_root} ${mtdparts}" \
69 		"rootfstype=${mmc_root_fs_type} ip=${ip_method} " \
70 		"eth=${ethaddr} " \
71 		"\0" \
72 	"mmc_boot=run mmc_args; " \
73 		"run mmc_load_uimage; " \
74 		"bootm ${kloadaddr}\0" \
75 	""
76 
77 #ifndef CONFIG_RESTORE_FLASH
78 /* set to negative value for no autoboot */
79 
80 #define CONFIG_BOOTCOMMAND \
81 	"if mmc rescan; then " \
82 		"echo SD/MMC found on device ${mmc_dev};" \
83 		"if run loadbootenv; then " \
84 			"echo Loaded environment from ${bootenv};" \
85 			"run importbootenv;" \
86 		"fi;" \
87 		"if test -n $uenvcmd; then " \
88 			"echo Running uenvcmd ...;" \
89 			"run uenvcmd;" \
90 		"fi;" \
91 		"if run mmc_load_uimage; then " \
92 			"run mmc_args;" \
93 			"bootm ${kloadaddr};" \
94 		"fi;" \
95 	"fi;" \
96 	"run nand_boot;" \
97 	"reset;"
98 
99 #else
100 
101 #define CONFIG_BOOTCOMMAND			\
102 	"setenv autoload no; "			\
103 	"dhcp; "				\
104 	"if tftp 80000000 debrick.scr; then "	\
105 		"source 80000000; "		\
106 	"fi"
107 #endif
108 
109 #endif /* CONFIG_SPL_BUILD */
110 
111 #if defined(CONFIG_VIDEO)
112 #define CONFIG_VIDEO_DA8XX
113 #define CONFIG_SPLASH_SCREEN
114 #define CONFIG_SPLASH_SCREEN_ALIGN
115 #define CONFIG_VIDEO_LOGO
116 #define CONFIG_VIDEO_BMP_RLE8
117 #define CONFIG_VIDEO_BMP_LOGO
118 #define DA8XX_LCD_CNTL_BASE	LCD_CNTL_BASE
119 
120 #define CONFIG_SPI
121 
122 #define BOARD_LCD_RESET		115	/* Bank 3 pin 19 */
123 #define CONFIG_FORMIKE
124 #define DISPL_PLL_SPREAD_SPECTRUM
125 #endif
126 
127 #endif	/* ! __CONFIG_RUT_H */
128