xref: /rk3399_ARM-atf/plat/nvidia/tegra/include/t210/tegra_def.h (revision 94c672e77f5e39902e46c26cc38df313f9bc1e49)
108438e24SVarun Wadekar /*
208438e24SVarun Wadekar  * Copyright (c) 2015, ARM Limited and Contributors. All rights reserved.
308438e24SVarun Wadekar  *
408438e24SVarun Wadekar  * Redistribution and use in source and binary forms, with or without
508438e24SVarun Wadekar  * modification, are permitted provided that the following conditions are met:
608438e24SVarun Wadekar  *
708438e24SVarun Wadekar  * Redistributions of source code must retain the above copyright notice, this
808438e24SVarun Wadekar  * list of conditions and the following disclaimer.
908438e24SVarun Wadekar  *
1008438e24SVarun Wadekar  * Redistributions in binary form must reproduce the above copyright notice,
1108438e24SVarun Wadekar  * this list of conditions and the following disclaimer in the documentation
1208438e24SVarun Wadekar  * and/or other materials provided with the distribution.
1308438e24SVarun Wadekar  *
1408438e24SVarun Wadekar  * Neither the name of ARM nor the names of its contributors may be used
1508438e24SVarun Wadekar  * to endorse or promote products derived from this software without specific
1608438e24SVarun Wadekar  * prior written permission.
1708438e24SVarun Wadekar  *
1808438e24SVarun Wadekar  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
1908438e24SVarun Wadekar  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
2008438e24SVarun Wadekar  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
2108438e24SVarun Wadekar  * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
2208438e24SVarun Wadekar  * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
2308438e24SVarun Wadekar  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
2408438e24SVarun Wadekar  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
2508438e24SVarun Wadekar  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
2608438e24SVarun Wadekar  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
2708438e24SVarun Wadekar  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
2808438e24SVarun Wadekar  * POSSIBILITY OF SUCH DAMAGE.
2908438e24SVarun Wadekar  */
3008438e24SVarun Wadekar 
3108438e24SVarun Wadekar #ifndef __TEGRA_DEF_H__
3208438e24SVarun Wadekar #define __TEGRA_DEF_H__
3308438e24SVarun Wadekar 
3408438e24SVarun Wadekar #include <platform_def.h>
3508438e24SVarun Wadekar 
3608438e24SVarun Wadekar /*******************************************************************************
37*94c672e7SVarun Wadekar  * Power down state IDs
38*94c672e7SVarun Wadekar  ******************************************************************************/
39*94c672e7SVarun Wadekar #define PSTATE_ID_CORE_POWERDN		7
40*94c672e7SVarun Wadekar #define PSTATE_ID_CLUSTER_IDLE		16
41*94c672e7SVarun Wadekar #define PSTATE_ID_CLUSTER_POWERDN	17
42*94c672e7SVarun Wadekar #define PSTATE_ID_SOC_POWERDN		27
43*94c672e7SVarun Wadekar 
44*94c672e7SVarun Wadekar /*******************************************************************************
45*94c672e7SVarun Wadekar  * This value is used by the PSCI implementation during the `SYSTEM_SUSPEND`
46*94c672e7SVarun Wadekar  * call as the `state-id` field in the 'power state' parameter.
47*94c672e7SVarun Wadekar  ******************************************************************************/
48*94c672e7SVarun Wadekar #define PLAT_SYS_SUSPEND_STATE_ID	PSTATE_ID_SOC_POWERDN
49*94c672e7SVarun Wadekar 
50*94c672e7SVarun Wadekar /*******************************************************************************
5108438e24SVarun Wadekar  * Implementation defined ACTLR_EL3 bit definitions
5208438e24SVarun Wadekar  ******************************************************************************/
5308438e24SVarun Wadekar #define ACTLR_EL3_L2ACTLR_BIT		(1 << 6)
5408438e24SVarun Wadekar #define ACTLR_EL3_L2ECTLR_BIT		(1 << 5)
5508438e24SVarun Wadekar #define ACTLR_EL3_L2CTLR_BIT		(1 << 4)
5608438e24SVarun Wadekar #define ACTLR_EL3_CPUECTLR_BIT		(1 << 1)
5708438e24SVarun Wadekar #define ACTLR_EL3_CPUACTLR_BIT		(1 << 0)
5808438e24SVarun Wadekar #define ACTLR_EL3_ENABLE_ALL_ACCESS	(ACTLR_EL3_L2ACTLR_BIT | \
5908438e24SVarun Wadekar 					 ACTLR_EL3_L2ECTLR_BIT | \
6008438e24SVarun Wadekar 					 ACTLR_EL3_L2CTLR_BIT | \
6108438e24SVarun Wadekar 					 ACTLR_EL3_CPUECTLR_BIT | \
6208438e24SVarun Wadekar 					 ACTLR_EL3_CPUACTLR_BIT)
6308438e24SVarun Wadekar 
6408438e24SVarun Wadekar /*******************************************************************************
6508438e24SVarun Wadekar  * GIC memory map
6608438e24SVarun Wadekar  ******************************************************************************/
6708438e24SVarun Wadekar #define TEGRA_GICD_BASE			0x50041000
6808438e24SVarun Wadekar #define TEGRA_GICC_BASE			0x50042000
6908438e24SVarun Wadekar 
7008438e24SVarun Wadekar /*******************************************************************************
7108438e24SVarun Wadekar  * Tegra micro-seconds timer constants
7208438e24SVarun Wadekar  ******************************************************************************/
7308438e24SVarun Wadekar #define TEGRA_TMRUS_BASE		0x60005010
7408438e24SVarun Wadekar 
7508438e24SVarun Wadekar /*******************************************************************************
7608438e24SVarun Wadekar  * Tegra Clock and Reset Controller constants
7708438e24SVarun Wadekar  ******************************************************************************/
7808438e24SVarun Wadekar #define TEGRA_CAR_RESET_BASE		0x60006000
7908438e24SVarun Wadekar 
8008438e24SVarun Wadekar /*******************************************************************************
8108438e24SVarun Wadekar  * Tegra Flow Controller constants
8208438e24SVarun Wadekar  ******************************************************************************/
8308438e24SVarun Wadekar #define TEGRA_FLOWCTRL_BASE		0x60007000
8408438e24SVarun Wadekar 
8508438e24SVarun Wadekar /*******************************************************************************
8608438e24SVarun Wadekar  * Tegra Secure Boot Controller constants
8708438e24SVarun Wadekar  ******************************************************************************/
8808438e24SVarun Wadekar #define TEGRA_SB_BASE			0x6000C200
8908438e24SVarun Wadekar 
9008438e24SVarun Wadekar /*******************************************************************************
9108438e24SVarun Wadekar  * Tegra Exception Vectors constants
9208438e24SVarun Wadekar  ******************************************************************************/
9308438e24SVarun Wadekar #define TEGRA_EVP_BASE			0x6000F000
9408438e24SVarun Wadekar 
9508438e24SVarun Wadekar /*******************************************************************************
9608438e24SVarun Wadekar  * Tegra Power Mgmt Controller constants
9708438e24SVarun Wadekar  ******************************************************************************/
9808438e24SVarun Wadekar #define TEGRA_PMC_BASE			0x7000E400
9908438e24SVarun Wadekar 
10008438e24SVarun Wadekar /*******************************************************************************
10108438e24SVarun Wadekar  * Tegra Memory Controller constants
10208438e24SVarun Wadekar  ******************************************************************************/
10308438e24SVarun Wadekar #define TEGRA_MC_BASE			0x70019000
10408438e24SVarun Wadekar 
10508438e24SVarun Wadekar #endif /* __TEGRA_DEF_H__ */
106