blob: 810b2bdbd5bc40c4667d73670c2cb09a8ececb56 [file] [log] [blame]
Suneel Garapati03c22882019-10-19 18:37:55 -07001/* SPDX-License-Identifier: GPL-2.0
2 *
3 * Copyright (C) 2018 Marvell International Ltd.
4 *
5 * https://spdx.org/licenses
6 */
7
8#ifndef __OCTEONTX_COMMON_H__
9#define __OCTEONTX_COMMON_H__
10
11#define CONFIG_SUPPORT_RAW_INITRD
12
13/** Maximum size of image supported for bootm (and bootable FIT images) */
14#define CONFIG_SYS_BOOTM_LEN (256 << 20)
15
16/** Memory base address */
17#define CONFIG_SYS_SDRAM_BASE CONFIG_SYS_TEXT_BASE
18
19/** Stack starting address */
20#define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_SDRAM_BASE + 0xffff0)
21
22/** Heap size for U-Boot */
23#define CONFIG_SYS_MALLOC_LEN (CONFIG_ENV_SIZE + 64 * 1024 * 1024)
24
25#define CONFIG_SYS_LOAD_ADDR CONFIG_SYS_SDRAM_BASE
26
27/* Allow environment variable to be overwritten */
28#define CONFIG_ENV_OVERWRITE
29
30/** Reduce hashes printed out */
31#define CONFIG_TFTP_TSIZE
32
33/* Autoboot options */
34#define CONFIG_RESET_TO_RETRY
35#define CONFIG_BOOT_RETRY_TIME -1
36#define CONFIG_BOOT_RETRY_MIN 30
37
38/* BOOTP options */
39#define CONFIG_BOOTP_BOOTFILESIZE
40
41/* AHCI support Definitions */
42#ifdef CONFIG_DM_SCSI
43/** Enable 48-bit SATA addressing */
44# define CONFIG_LBA48
45/** Enable 64-bit addressing */
46# define CONFIG_SYS_64BIT_LBA
47#endif
48
49/***** SPI Defines *********/
50#ifdef CONFIG_DM_SPI_FLASH
51# define CONFIG_SF_DEFAULT_BUS 0
52# define CONFIG_SF_DEFAULT_CS 0
53#endif
54
55/** Extra environment settings */
56#define CONFIG_EXTRA_ENV_SETTINGS \
57 "loadaddr=20080000\0" \
58 "autoload=0\0"
59
60/** Environment defines */
61#if defined(CONFIG_ENV_IS_IN_MMC)
62#define CONFIG_SYS_MMC_ENV_DEV 0
63#endif
64
65/* Monitor Command Prompt */
66#define CONFIG_SYS_CBSIZE 1024 /** Console I/O Buffer Size */
67#define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE
68
69#define CONFIG_SYS_MAXARGS 64 /** max command args */
70
71#define CONFIG_SYS_MMC_MAX_BLK_COUNT 8192
72
73#undef CONFIG_SYS_PROMPT
74#define CONFIG_SYS_PROMPT env_get("prompt")
75
76/** EMMC specific defines */
77#if defined(CONFIG_MMC_OCTEONTX)
78#define CONFIG_SUPPORT_EMMC_BOOT
79#define CONFIG_SUPPORT_EMMC_RPMB
Suneel Garapati03c22882019-10-19 18:37:55 -070080#endif
81
82#if defined(CONFIG_NAND_OCTEONTX)
83/*#define CONFIG_MTD_CONCAT */
84#define CONFIG_SYS_MAX_NAND_DEVICE 8
85#define CONFIG_SYS_NAND_ONFI_DETECTION
86#endif
87
88#endif /* __OCTEONTX_COMMON_H__ */