-
Notifications
You must be signed in to change notification settings - Fork 34
/
board.h
39 lines (27 loc) · 1 KB
/
board.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#ifndef __BOARD_H__
#define __BOARD_H__
#include "dram.h"
#include "sunxi_spi.h"
#include "sunxi_usart.h"
#include "sunxi_sdhci.h"
#define USART_DBG usart5_dbg
#define CONFIG_BOOT_SPINAND
#define CONFIG_BOOT_SDCARD
#define CONFIG_BOOT_MMC
#define CONFIG_FATFS_CACHE_SIZE (CONFIG_DTB_LOAD_ADDR - SDRAM_BASE) // in bytes
#define CONFIG_SDMMC_SPEED_TEST_SIZE 1024 // (unit: 512B sectors)
#define CONFIG_CPU_FREQ 1200000000
// #define CONFIG_ENABLE_CPU_FREQ_DUMP
#define CONFIG_KERNEL_FILENAME "zImage"
#define CONFIG_DTB_FILENAME "sun8i-t113-mangopi-dual.dtb"
#define CONFIG_KERNEL_LOAD_ADDR (SDRAM_BASE + (72 * 1024 * 1024))
#define CONFIG_DTB_LOAD_ADDR (SDRAM_BASE + (64 * 1024 * 1024))
// 128KB erase sectors, so place them starting from 2nd sector
#define CONFIG_SPINAND_DTB_ADDR (128 * 2048)
#define CONFIG_SPINAND_KERNEL_ADDR (256 * 2048)
extern dram_para_t ddr_param;
extern sunxi_usart_t USART_DBG;
extern sunxi_spi_t sunxi_spi0;
extern void board_init(void);
extern int board_sdhci_init(void);
#endif