blob: 81c076a1a7046ee7ade9b039faa737dfafcfe104 [file] [log] [blame]
Varun Wadekar28463b92015-07-14 17:11:20 +05301/*
Varun Wadekar2b914122018-06-25 11:36:47 -07002 * Copyright (c) 2015-2018, ARM Limited and Contributors. All rights reserved.
Varun Wadekar28463b92015-07-14 17:11:20 +05303 *
dp-armfa3cf0b2017-05-03 09:38:09 +01004 * SPDX-License-Identifier: BSD-3-Clause
Varun Wadekar28463b92015-07-14 17:11:20 +05305 */
6
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +00007#ifndef DENVER_H
8#define DENVER_H
Varun Wadekar28463b92015-07-14 17:11:20 +05309
Varun Wadekar3c337a62015-09-03 17:15:06 +053010/* MIDR values for Denver */
Varun Wadekarc6a11f62017-05-25 18:04:48 -070011#define DENVER_MIDR_PN0 U(0x4E0F0000)
12#define DENVER_MIDR_PN1 U(0x4E0F0010)
13#define DENVER_MIDR_PN2 U(0x4E0F0020)
14#define DENVER_MIDR_PN3 U(0x4E0F0030)
15#define DENVER_MIDR_PN4 U(0x4E0F0040)
Varun Wadekar3c337a62015-09-03 17:15:06 +053016
17/* Implementer code in the MIDR register */
Varun Wadekarc6a11f62017-05-25 18:04:48 -070018#define DENVER_IMPL U(0x4E)
Varun Wadekar28463b92015-07-14 17:11:20 +053019
20/* CPU state ids - implementation defined */
Varun Wadekarc6a11f62017-05-25 18:04:48 -070021#define DENVER_CPU_STATE_POWER_DOWN U(0x3)
Varun Wadekar28463b92015-07-14 17:11:20 +053022
Varun Wadekarcd38e6e2018-08-28 09:11:30 -070023/* Speculative store buffering */
24#define DENVER_CPU_DIS_SSB_EL3 (U(1) << 11)
25#define DENVER_PN4_CPU_DIS_SSB_EL3 (U(1) << 18)
26
27/* Speculative memory disambiguation */
28#define DENVER_CPU_DIS_MD_EL3 (U(1) << 9)
29#define DENVER_PN4_CPU_DIS_MD_EL3 (U(1) << 17)
30
Varun Wadekar2b914122018-06-25 11:36:47 -070031/* Core power management states */
32#define DENVER_CPU_PMSTATE_C1 U(0x1)
33#define DENVER_CPU_PMSTATE_C6 U(0x6)
34#define DENVER_CPU_PMSTATE_C7 U(0x7)
35#define DENVER_CPU_PMSTATE_MASK U(0xF)
36
Varun Wadekard43583c2016-02-22 11:09:41 -080037#ifndef __ASSEMBLY__
38
39/* Disable Dynamic Code Optimisation */
40void denver_disable_dco(void);
41
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +000042#endif /* __ASSEMBLY__ */
Varun Wadekard43583c2016-02-22 11:09:41 -080043
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +000044#endif /* DENVER_H */