blob: c5bf7d5a8fd05dd715ec1a45eb032d131fec2c6a [file] [log] [blame]
Sumit Garg82d45c12018-06-15 13:41:59 +05301/*
2 * Copyright (c) 2018, ARM Limited and Contributors. All rights reserved.
3 *
4 * SPDX-License-Identifier: BSD-3-Clause
5 */
6
Antonio Nino Diaz6f3ccc52018-07-20 09:17:26 +01007#ifndef PLATFORM_DEF_H
8#define PLATFORM_DEF_H
Sumit Garg82d45c12018-06-15 13:41:59 +05309
Antonio Nino Diaze0f90632018-12-14 00:18:21 +000010#include <lib/utils_def.h>
11#include <plat/common/common_def.h>
Sumit Garg82d45c12018-06-15 13:41:59 +053012
Sumit Garg4d4df112018-06-15 14:43:35 +053013/* CPU topology */
14#define PLAT_MAX_CORES_PER_CLUSTER 2
15#define PLAT_CLUSTER_COUNT 12
16#define PLATFORM_CORE_COUNT (PLAT_CLUSTER_COUNT * \
17 PLAT_MAX_CORES_PER_CLUSTER)
18
Antonio Nino Diaz6f3ccc52018-07-20 09:17:26 +010019#define PLAT_MAX_PWR_LVL U(1)
20#define PLAT_MAX_RET_STATE U(1)
21#define PLAT_MAX_OFF_STATE U(2)
Sumit Garg754073f2018-06-15 15:29:02 +053022
23#define SQ_LOCAL_STATE_RUN 0
24#define SQ_LOCAL_STATE_RET 1
25#define SQ_LOCAL_STATE_OFF 2
26
Sumit Garg82d45c12018-06-15 13:41:59 +053027#define CACHE_WRITEBACK_SHIFT 6
28#define CACHE_WRITEBACK_GRANULE (1 << CACHE_WRITEBACK_SHIFT)
29
Sumit Garg470255b2018-06-15 15:10:16 +053030#define PLAT_PHY_ADDR_SPACE_SIZE (1ULL << 32)
31#define PLAT_VIRT_ADDR_SPACE_SIZE (1ULL << 32)
32#define MAX_XLAT_TABLES 4
33#define MAX_MMAP_REGIONS 6
34
Sumit Garg82d45c12018-06-15 13:41:59 +053035#define PLATFORM_STACK_SIZE 0x400
36
37#define BL31_BASE 0x04000000
38#define BL31_SIZE 0x00080000
39#define BL31_LIMIT (BL31_BASE + BL31_SIZE)
40
Ard Biesheuvel18498352018-12-29 19:40:31 +010041#define BL32_BASE 0xfc000000
42
Sumit Gargbda9d3c2018-06-15 14:50:19 +053043#define PLAT_SQ_CCN_BASE 0x32000000
44#define PLAT_SQ_CLUSTER_TO_CCN_ID_MAP \
45 0, /* Cluster 0 */ \
46 18, /* Cluster 1 */ \
47 11, /* Cluster 2 */ \
48 29, /* Cluster 3 */ \
49 35, /* Cluster 4 */ \
50 17, /* Cluster 5 */ \
51 12, /* Cluster 6 */ \
52 30, /* Cluster 7 */ \
53 14, /* Cluster 8 */ \
54 32, /* Cluster 9 */ \
55 15, /* Cluster 10 */ \
56 33 /* Cluster 11 */
57
Sumit Garg84711f92018-06-15 14:34:42 +053058/* UART related constants */
59#define PLAT_SQ_BOOT_UART_BASE 0x2A400000
60#define PLAT_SQ_BOOT_UART_CLK_IN_HZ 62500000
61#define SQ_CONSOLE_BAUDRATE 115200
62
Sumit Garg58ed23d2018-06-15 15:02:31 +053063#define SQ_SYS_CNTCTL_BASE 0x2a430000
64
65#define SQ_SYS_TIMCTL_BASE 0x2a810000
66#define PLAT_SQ_NSTIMER_FRAME_ID 0
67
Ard Biesheuvel6fc122f2018-06-15 15:25:42 +053068#define DRAMINFO_BASE 0x2E00FFC0
69
Sumit Gargfe717612018-06-15 15:17:10 +053070#define PLAT_SQ_MHU_BASE 0x45000000
71
Sumit Garg0f18bc42018-06-15 15:20:53 +053072#define PLAT_SQ_SCP_COM_SHARED_MEM_BASE 0x45400000
73#define SCPI_CMD_GET_DRAMINFO 0x1
74
Sumit Garg38172022018-06-15 13:48:11 +053075#define SQ_BOOT_CFG_ADDR 0x45410000
76#define PLAT_SQ_PRIMARY_CPU_SHIFT 8
77#define PLAT_SQ_PRIMARY_CPU_BIT_WIDTH 6
78
Sumit Gargc412c2c2018-06-15 14:58:25 +053079#define PLAT_SQ_GICD_BASE 0x30000000
80#define PLAT_SQ_GICR_BASE 0x30400000
81
Sumit Garg754073f2018-06-15 15:29:02 +053082#define PLAT_SQ_GPIO_BASE 0x51000000
83
Antonio Nino Diaz6f3ccc52018-07-20 09:17:26 +010084#endif /* PLATFORM_DEF_H */