Jagan Teki | 1494cc8 | 2018-05-07 11:21:34 +0530 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2018 Simone CIANNI <simone.cianni@bticino.it> |
| 3 | * Copyright (C) 2018 Raffaele RECALCATI <raffaele.recalcati@bticino.it> |
| 4 | * Copyright (C) 2018 Jagan Teki <jagan@amarulasolutions.com> |
| 5 | * |
| 6 | * Configuration settings for the BTicion i.MX6DL Mamoj board. |
| 7 | * |
| 8 | * SPDX-License-Identifier: GPL-2.0+ |
| 9 | */ |
| 10 | |
| 11 | #ifndef __IMX6DL_MAMOJ_CONFIG_H |
| 12 | #define __IMX6DL_MAMOJ_CONFIG_H |
| 13 | |
| 14 | #include <linux/sizes.h> |
| 15 | #include "mx6_common.h" |
| 16 | |
| 17 | /* Size of malloc() pool */ |
| 18 | #define CONFIG_SYS_MALLOC_LEN (16 * SZ_1M) |
| 19 | |
| 20 | /* Total Size of Environment Sector */ |
| 21 | #define CONFIG_ENV_SIZE SZ_128K |
| 22 | |
| 23 | /* Allow to overwrite serial and ethaddr */ |
| 24 | #define CONFIG_ENV_OVERWRITE |
| 25 | |
| 26 | /* Environment */ |
| 27 | #ifndef CONFIG_ENV_IS_NOWHERE |
| 28 | /* Environment in MMC */ |
| 29 | # if defined(CONFIG_ENV_IS_IN_MMC) |
| 30 | # define CONFIG_ENV_OFFSET 0x100000 |
| 31 | # endif |
| 32 | #endif |
| 33 | |
| 34 | #ifndef CONFIG_SPL_BUILD |
| 35 | #define CONFIG_EXTRA_ENV_SETTINGS \ |
| 36 | "scriptaddr=0x14000000\0" \ |
| 37 | "fdt_addr_r=0x13000000\0" \ |
| 38 | "kernel_addr_r=0x10008000\0" \ |
| 39 | "fdt_high=0xffffffff\0" \ |
| 40 | BOOTENV |
| 41 | |
| 42 | #define BOOT_TARGET_DEVICES(func) \ |
| 43 | func(MMC, mmc, 2) |
| 44 | |
| 45 | #include <config_distro_bootcmd.h> |
| 46 | #endif |
| 47 | |
| 48 | /* UART */ |
| 49 | #define CONFIG_MXC_UART_BASE UART3_BASE |
| 50 | |
| 51 | /* MMC */ |
| 52 | #define CONFIG_SYS_MMC_ENV_DEV 2 |
| 53 | #define CONFIG_SUPPORT_EMMC_BOOT |
| 54 | |
| 55 | /* Ethernet */ |
| 56 | #define CONFIG_FEC_MXC_PHYADDR 1 |
| 57 | #define CONFIG_MII |
| 58 | |
| 59 | /* USB */ |
| 60 | #define CONFIG_EHCI_HCD_INIT_AFTER_RESET |
| 61 | #define CONFIG_MXC_USB_PORTSC (PORT_PTS_UTMI | PORT_PTS_PTW) |
| 62 | #define CONFIG_MXC_USB_FLAGS 0 |
| 63 | #define CONFIG_USB_MAX_CONTROLLER_COUNT 2 |
| 64 | |
| 65 | /* Miscellaneous configurable options */ |
| 66 | #define CONFIG_SYS_MEMTEST_START 0x80000000 |
| 67 | #define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + 0x8000000) |
| 68 | |
| 69 | #define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR |
| 70 | #define CONFIG_SYS_HZ 1000 |
| 71 | |
| 72 | /* Physical Memory Map */ |
| 73 | #define CONFIG_NR_DRAM_BANKS 1 |
| 74 | #define PHYS_SDRAM MMDC0_ARB_BASE_ADDR |
| 75 | |
| 76 | #define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM |
| 77 | #define CONFIG_SYS_INIT_RAM_ADDR IRAM_BASE_ADDR |
| 78 | #define CONFIG_SYS_INIT_RAM_SIZE IRAM_SIZE |
| 79 | |
| 80 | #define CONFIG_SYS_INIT_SP_OFFSET (CONFIG_SYS_INIT_RAM_SIZE - \ |
| 81 | GENERATED_GBL_DATA_SIZE) |
| 82 | #define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_INIT_RAM_ADDR + \ |
| 83 | CONFIG_SYS_INIT_SP_OFFSET) |
| 84 | |
| 85 | /* SPL */ |
| 86 | #include "imx6_spl.h" |
| 87 | |
| 88 | #endif /* __IMX6DL_MAMOJ_CONFIG_H */ |