blob: 62530e219087ab3531cd5c23762f06350820002a [file] [log] [blame]
johpow01a3810e82021-05-18 15:23:31 -05001/*
Bipin Ravi2f73d972022-01-20 00:01:04 -06002 * Copyright (c) 2021-2022, Arm Limited. All rights reserved.
johpow01a3810e82021-05-18 15:23:31 -05003 *
4 * SPDX-License-Identifier: BSD-3-Clause
5 */
6
7#ifndef CORTEX_X2_H
8#define CORTEX_X2_H
9
10#define CORTEX_X2_MIDR U(0x410FD480)
11
Bipin Ravi86499742022-01-18 01:59:06 -060012/* Cortex-X2 loop count for CVE-2022-23960 mitigation */
13#define CORTEX_X2_BHB_LOOP_COUNT U(32)
14
johpow01a3810e82021-05-18 15:23:31 -050015/*******************************************************************************
16 * CPU Extended Control register specific definitions
17 ******************************************************************************/
18#define CORTEX_X2_CPUECTLR_EL1 S3_0_C15_C1_4
Bipin Ravi2f73d972022-01-20 00:01:04 -060019#define CORTEX_X2_CPUECTLR_EL1_PFSTIDIS_BIT (ULL(1) << 8)
johpow01a3810e82021-05-18 15:23:31 -050020
21/*******************************************************************************
johpow01f6c37de2021-12-03 11:27:33 -060022 * CPU Extended Control register 2 specific definitions
23 ******************************************************************************/
24#define CORTEX_X2_CPUECTLR2_EL1 S3_0_C15_C1_5
25
26#define CORTEX_X2_CPUECTLR2_EL1_PF_MODE_SHIFT U(11)
27#define CORTEX_X2_CPUECTLR2_EL1_PF_MODE_WIDTH U(4)
28#define CORTEX_X2_CPUECTLR2_EL1_PF_MODE_CNSRV ULL(0x9)
29
30/*******************************************************************************
johpow01a3810e82021-05-18 15:23:31 -050031 * CPU Power Control register specific definitions
32 ******************************************************************************/
33#define CORTEX_X2_CPUPWRCTLR_EL1 S3_0_C15_C2_7
34#define CORTEX_X2_CPUPWRCTLR_EL1_CORE_PWRDN_BIT U(1)
35
johpow0115f10bd2021-12-01 17:40:39 -060036/*******************************************************************************
37 * CPU Auxiliary Control Register 5 definitions
38 ******************************************************************************/
39#define CORTEX_X2_CPUACTLR5_EL1 S3_0_C15_C8_0
Bipin Ravi78b72082022-02-06 01:29:31 -060040#define CORTEX_X2_CPUACTLR5_EL1_BIT_17 (ULL(1) << 17)
johpow0115f10bd2021-12-01 17:40:39 -060041
Bipin Ravi9ad54782022-01-20 00:42:05 -060042/*******************************************************************************
43 * CPU Implementation Specific Selected Instruction registers
44 ******************************************************************************/
45#define CORTEX_X2_IMP_CPUPSELR_EL3 S3_6_C15_C8_0
46#define CORTEX_X2_IMP_CPUPCR_EL3 S3_6_C15_C8_1
47#define CORTEX_X2_IMP_CPUPOR_EL3 S3_6_C15_C8_2
48#define CORTEX_X2_IMP_CPUPMR_EL3 S3_6_C15_C8_3
49
johpow01a3810e82021-05-18 15:23:31 -050050#endif /* CORTEX_X2_H */