Tom Rini | 10e4779 | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0+ */ |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 2 | /* |
| 3 | * siemens rut |
| 4 | * (C) Copyright 2013 Siemens Schweiz AG |
| 5 | * (C) Heiko Schocher, DENX Software Engineering, hs@denx.de. |
| 6 | * |
| 7 | * Based on: |
| 8 | * U-Boot file:/include/configs/am335x_evm.h |
| 9 | * |
| 10 | * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/ |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 11 | */ |
| 12 | |
| 13 | #ifndef __CONFIG_RUT_H |
| 14 | #define __CONFIG_RUT_H |
| 15 | |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 16 | #include "siemens-am33x-common.h" |
| 17 | |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 18 | #define RUT_IOCTRL_VAL 0x18b |
| 19 | #define DDR_PLL_FREQ 303 |
| 20 | |
| 21 | /* Physical Memory Map */ |
| 22 | #define CONFIG_MAX_RAM_BANK_SIZE (256 << 20) /* 256 MiB */ |
| 23 | |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 24 | #define CONFIG_FACTORYSET |
| 25 | |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 26 | /* Watchdog */ |
| 27 | #define WATCHDOG_TRIGGER_GPIO 14 |
| 28 | |
| 29 | #ifndef CONFIG_SPL_BUILD |
| 30 | |
Heiko Schocher | d17c3fc | 2015-06-16 14:59:34 +0200 | [diff] [blame] | 31 | /* Use common default */ |
Heiko Schocher | d17c3fc | 2015-06-16 14:59:34 +0200 | [diff] [blame] | 32 | |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 33 | /* Default env settings */ |
| 34 | #define CONFIG_EXTRA_ENV_SETTINGS \ |
| 35 | "hostname=rut\0" \ |
Heiko Schocher | cbec11a | 2016-06-07 08:55:45 +0200 | [diff] [blame] | 36 | "ubi_off=2048\0"\ |
Samuel Egli | 8069bfe | 2013-11-04 14:05:03 +0100 | [diff] [blame] | 37 | "nand_img_size=0x500000\0" \ |
| 38 | "splashpos=m,m\0" \ |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 39 | "optargs=fixrtc --no-log consoleblank=0 \0" \ |
Heiko Schocher | d17c3fc | 2015-06-16 14:59:34 +0200 | [diff] [blame] | 40 | CONFIG_ENV_SETTINGS_V1 \ |
| 41 | CONFIG_ENV_SETTINGS_NAND_V1 \ |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 42 | "mmc_dev=0\0" \ |
| 43 | "mmc_root=/dev/mmcblk0p2 rw\0" \ |
| 44 | "mmc_root_fs_type=ext4 rootwait\0" \ |
| 45 | "mmc_load_uimage=" \ |
| 46 | "mmc rescan; " \ |
| 47 | "setenv bootfile uImage;" \ |
| 48 | "fatload mmc ${mmc_dev} ${kloadaddr} ${bootfile}\0" \ |
| 49 | "loadbootenv=fatload mmc ${mmc_dev} ${loadaddr} ${bootenv}\0" \ |
| 50 | "importbootenv=echo Importing environment from mmc ...; " \ |
| 51 | "env import -t $loadaddr $filesize\0" \ |
| 52 | "mmc_args=run bootargs_defaults;" \ |
| 53 | "mtdparts default;" \ |
| 54 | "setenv bootargs ${bootargs} " \ |
| 55 | "root=${mmc_root} ${mtdparts}" \ |
| 56 | "rootfstype=${mmc_root_fs_type} ip=${ip_method} " \ |
| 57 | "eth=${ethaddr} " \ |
| 58 | "\0" \ |
| 59 | "mmc_boot=run mmc_args; " \ |
| 60 | "run mmc_load_uimage; " \ |
| 61 | "bootm ${kloadaddr}\0" \ |
| 62 | "" |
| 63 | |
| 64 | #ifndef CONFIG_RESTORE_FLASH |
| 65 | /* set to negative value for no autoboot */ |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 66 | |
| 67 | #define CONFIG_BOOTCOMMAND \ |
| 68 | "if mmc rescan; then " \ |
| 69 | "echo SD/MMC found on device ${mmc_dev};" \ |
| 70 | "if run loadbootenv; then " \ |
| 71 | "echo Loaded environment from ${bootenv};" \ |
| 72 | "run importbootenv;" \ |
| 73 | "fi;" \ |
| 74 | "if test -n $uenvcmd; then " \ |
| 75 | "echo Running uenvcmd ...;" \ |
| 76 | "run uenvcmd;" \ |
| 77 | "fi;" \ |
| 78 | "if run mmc_load_uimage; then " \ |
| 79 | "run mmc_args;" \ |
| 80 | "bootm ${kloadaddr};" \ |
| 81 | "fi;" \ |
| 82 | "fi;" \ |
| 83 | "run nand_boot;" \ |
Samuel Egli | 8069bfe | 2013-11-04 14:05:03 +0100 | [diff] [blame] | 84 | "reset;" |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 85 | |
| 86 | #else |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 87 | |
| 88 | #define CONFIG_BOOTCOMMAND \ |
| 89 | "setenv autoload no; " \ |
| 90 | "dhcp; " \ |
| 91 | "if tftp 80000000 debrick.scr; then " \ |
| 92 | "source 80000000; " \ |
| 93 | "fi" |
| 94 | #endif |
| 95 | |
| 96 | #endif /* CONFIG_SPL_BUILD */ |
| 97 | |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 98 | #if defined(CONFIG_VIDEO) |
| 99 | #define CONFIG_VIDEO_DA8XX |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 100 | #define CONFIG_VIDEO_LOGO |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 101 | #define CONFIG_VIDEO_BMP_LOGO |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 102 | #define DA8XX_LCD_CNTL_BASE LCD_CNTL_BASE |
| 103 | |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 104 | #define BOARD_LCD_RESET 115 /* Bank 3 pin 19 */ |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 105 | #define CONFIG_FORMIKE |
Samuel Egli | 8069bfe | 2013-11-04 14:05:03 +0100 | [diff] [blame] | 106 | #define DISPL_PLL_SPREAD_SPECTRUM |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 107 | #endif |
| 108 | |
Heiko Schocher | 499c498 | 2013-08-19 16:39:01 +0200 | [diff] [blame] | 109 | #endif /* ! __CONFIG_RUT_H */ |