Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 1 | /* |
| 2 | * (C) Copyright 2015 |
| 3 | * Dirk Eibach, Guntermann & Drunck GmbH, eibach@gdsys.de |
| 4 | * |
| 5 | * |
| 6 | * SPDX-License-Identifier: GPL-2.0+ |
| 7 | */ |
| 8 | |
| 9 | #ifndef __CONFIG_H |
| 10 | #define __CONFIG_H |
| 11 | |
| 12 | /* |
| 13 | * DDR Setup |
| 14 | */ |
| 15 | #define CONFIG_SYS_SDRAM_BASE 0x00000000 /* DDR is system memory */ |
| 16 | /* TODO: Check: Can this be unified with CONFIG_SYS_SDRAM_BASE? */ |
| 17 | #define CONFIG_SYS_DDR_SDRAM_BASE CONFIG_SYS_SDRAM_BASE |
| 18 | |
| 19 | /* |
| 20 | * Memory test |
| 21 | * TODO: Migrate! |
| 22 | */ |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 23 | |
| 24 | /* |
| 25 | * The reserved memory |
| 26 | */ |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 27 | |
| 28 | #define CONFIG_SYS_MONITOR_LEN (512 * 1024) /* Reserve 512 kB for Mon */ |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 29 | |
| 30 | /* |
| 31 | * Initial RAM Base Address Setup |
| 32 | */ |
| 33 | #define CONFIG_SYS_INIT_RAM_LOCK |
| 34 | #define CONFIG_SYS_INIT_RAM_ADDR 0xE6000000 /* Initial RAM address */ |
| 35 | #define CONFIG_SYS_INIT_RAM_SIZE 0x1000 /* Size of used area in RAM */ |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 36 | |
| 37 | /* |
| 38 | * FLASH on the Local Bus |
| 39 | */ |
| 40 | #define CONFIG_SYS_FLASH_BASE 0xFE000000 /* FLASH base address */ |
| 41 | #define CONFIG_SYS_FLASH_SIZE 8 /* FLASH size is up to 8M */ |
| 42 | |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 43 | #define CONFIG_SYS_BAUDRATE_TABLE \ |
| 44 | {300, 600, 1200, 2400, 4800, 9600, 19200, 38400, 57600, 115200} |
| 45 | |
| 46 | /* |
| 47 | * Environment |
| 48 | */ |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 49 | |
| 50 | #define CONFIG_LOADS_ECHO /* echo on for serial download */ |
| 51 | #define CONFIG_SYS_LOADS_BAUD_CHANGE /* allow baudrate change */ |
| 52 | |
| 53 | /* |
| 54 | * Miscellaneous configurable options |
| 55 | */ |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 56 | |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 57 | /* |
| 58 | * For booting Linux, the board info and command line data |
| 59 | * have to be in the first 256 MB of memory, since this is |
| 60 | * the maximum mapped by the Linux kernel during initialization. |
| 61 | */ |
| 62 | #define CONFIG_SYS_BOOTMAPSZ (256 << 20) /* Initial Memory map for Linux */ |
| 63 | |
| 64 | /* |
| 65 | * Environment Configuration |
| 66 | */ |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 67 | |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 68 | /* TODO: Turn into string option and migrate to Kconfig */ |
| 69 | #define CONFIG_HOSTNAME "gazerbeam" |
| 70 | #define CONFIG_ROOTPATH "/opt/nfsroot" |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 71 | |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 72 | #define CONFIG_EXTRA_ENV_SETTINGS \ |
| 73 | "netdev=eth0\0" \ |
| 74 | "consoledev=ttyS1\0" \ |
| 75 | "u-boot=u-boot.bin\0" \ |
| 76 | "kernel_addr=1000000\0" \ |
| 77 | "fdt_addr=C00000\0" \ |
| 78 | "fdtfile=hrcon.dtb\0" \ |
| 79 | "load=tftp ${loadaddr} ${u-boot}\0" \ |
| 80 | "update=protect off " __stringify(CONFIG_SYS_MONITOR_BASE) \ |
| 81 | " +${filesize};era " __stringify(CONFIG_SYS_MONITOR_BASE)\ |
| 82 | " +${filesize};cp.b ${fileaddr} " \ |
| 83 | __stringify(CONFIG_SYS_MONITOR_BASE) " ${filesize}\0" \ |
| 84 | "upd=run load update\0" \ |
| 85 | |
Dirk Eibach | d494cdb | 2019-03-29 10:18:19 +0100 | [diff] [blame] | 86 | #endif /* __CONFIG_H */ |