]> git.sur5r.net Git - u-boot/blob - include/configs/nios2-generic.h
nios2 : convert altera_pio to driver model
[u-boot] / include / configs / nios2-generic.h
1 /*
2  * (C) Copyright 2005, Psyent Corporation <www.psyent.com>
3  * Scott McNutt <smcnutt@psyent.com>
4  * (C) Copyright 2010, Thomas Chou <thomas@wytron.com.tw>
5  *
6  * SPDX-License-Identifier:     GPL-2.0+
7  */
8
9 #ifndef __CONFIG_H
10 #define __CONFIG_H
11
12 /*
13  * BOARD/CPU
14  */
15 #include "../board/altera/nios2-generic/custom_fpga.h" /* fpga parameters */
16 #define CONFIG_BOARD_NAME "nios2-generic" /* custom board name */
17 #define CONFIG_BOARD_EARLY_INIT_F       /* enable early board-spec. init */
18 #define CONFIG_DISPLAY_CPUINFO
19 #define CONFIG_DISPLAY_BOARDINFO
20 #define CONFIG_SYS_NIOS_SYSID_BASE      CONFIG_SYS_SYSID_BASE
21
22 /*
23  * SERIAL
24  */
25 #define CONFIG_BAUDRATE                 115200
26 #define CONFIG_SYS_CONSOLE_INFO_QUIET   /* Suppress console info */
27
28 /*
29  * TIMER
30  */
31 #define CONFIG_SYS_TIMER_RATE           CONFIG_SYS_TIMER_FREQ
32
33 /*
34  * BOOTP options
35  */
36 #define CONFIG_BOOTP_BOOTFILESIZE
37 #define CONFIG_BOOTP_BOOTPATH
38 #define CONFIG_BOOTP_GATEWAY
39 #define CONFIG_BOOTP_HOSTNAME
40
41 /*
42  * FDT options
43  */
44 #define CONFIG_OF_LIBFDT
45 #define CONFIG_OF_BOARD_SETUP
46 #define CONFIG_LMB
47
48 /*
49  * ENVIRONMENT -- Put environment in sector CONFIG_SYS_MONITOR_LEN above
50  * CONFIG_SYS_RESET_ADDR, since we assume the monitor is stored at the
51  * reset address, no? This will keep the environment in user region
52  * of flash. NOTE: the monitor length must be multiple of sector size
53  * (which is common practice).
54  */
55 #define CONFIG_ENV_IS_IN_FLASH
56
57 #define CONFIG_ENV_SIZE         0x20000 /* 128k, 1 sector */
58 #define CONFIG_ENV_OVERWRITE            /* Serial change Ok     */
59 #define CONFIG_ENV_ADDR         ((CONFIG_SYS_RESET_ADDR + \
60                                           CONFIG_SYS_MONITOR_LEN) | \
61                                          CONFIG_SYS_FLASH_BASE)
62
63 /*
64  * MEMORY ORGANIZATION
65  * -Monitor at top of sdram.
66  * -The heap is placed below the monitor
67  * -The stack is placed below the heap (&grows down).
68  */
69 #define CONFIG_MONITOR_IS_IN_RAM
70 #define CONFIG_SYS_MONITOR_LEN          0x40000 /* Reserve 256k */
71 #define CONFIG_SYS_MONITOR_BASE (CONFIG_SYS_SDRAM_BASE + \
72                                          CONFIG_SYS_SDRAM_SIZE - \
73                                          CONFIG_SYS_MONITOR_LEN)
74 #define CONFIG_SYS_MALLOC_LEN           (CONFIG_ENV_SIZE + 0x20000)
75 #define CONFIG_SYS_MALLOC_BASE          (CONFIG_SYS_MONITOR_BASE - \
76                                          CONFIG_SYS_MALLOC_LEN)
77 #define CONFIG_SYS_INIT_SP              CONFIG_SYS_MALLOC_BASE
78
79 /*
80  * MISC
81  */
82 #define CONFIG_SYS_LONGHELP             /* Provide extended help */
83 #define CONFIG_SYS_CBSIZE               256     /* Console I/O buf size */
84 #define CONFIG_SYS_MAXARGS              16      /* Max command args     */
85 #define CONFIG_SYS_BARGSIZE             CONFIG_SYS_CBSIZE /* Bootarg buf size */
86 #define CONFIG_SYS_PBSIZE               (CONFIG_SYS_CBSIZE + \
87                                         sizeof(CONFIG_SYS_PROMPT) + \
88                                          16)    /* Print buf size */
89 #define CONFIG_SYS_LOAD_ADDR            CONFIG_SYS_SDRAM_BASE
90 #define CONFIG_SYS_MEMTEST_START        CONFIG_SYS_SDRAM_BASE
91 #define CONFIG_SYS_MEMTEST_END          (CONFIG_SYS_INIT_SP - 0x20000)
92 #define CONFIG_CMDLINE_EDITING
93 #define CONFIG_CMD_GPIO
94
95 #endif /* __CONFIG_H */