xref: /rk3399_rockchip-uboot/arch/arm/include/asm/arch-tegra/gpu.h (revision a38a3c4af4ed72a2ed6192203f8fe17ccdd2389f)
1871d78edSAlexandre Courbot /*
2871d78edSAlexandre Courbot  *  (C) Copyright 2015
3871d78edSAlexandre Courbot  *  NVIDIA Corporation <www.nvidia.com>
4871d78edSAlexandre Courbot  *
5871d78edSAlexandre Courbot  * SPDX-License-Identifier:	GPL-2.0+
6871d78edSAlexandre Courbot  */
7871d78edSAlexandre Courbot 
8871d78edSAlexandre Courbot #ifndef __ASM_ARCH_TEGRA_GPU_H
9871d78edSAlexandre Courbot #define __ASM_ARCH_TEGRA_GPU_H
10871d78edSAlexandre Courbot 
11871d78edSAlexandre Courbot #if defined(CONFIG_TEGRA_GPU)
12871d78edSAlexandre Courbot 
13871d78edSAlexandre Courbot void config_gpu(void);
14871d78edSAlexandre Courbot bool gpu_configured(void);
15871d78edSAlexandre Courbot 
16871d78edSAlexandre Courbot #else /* CONFIG_TEGRA_GPU */
17871d78edSAlexandre Courbot 
18871d78edSAlexandre Courbot static inline void config_gpu(void)
19871d78edSAlexandre Courbot {
20871d78edSAlexandre Courbot }
21871d78edSAlexandre Courbot 
22871d78edSAlexandre Courbot static inline bool gpu_configured(void)
23871d78edSAlexandre Courbot {
24871d78edSAlexandre Courbot 	return false;
25871d78edSAlexandre Courbot }
26871d78edSAlexandre Courbot 
27871d78edSAlexandre Courbot #endif /* CONFIG_TEGRA_GPU */
28*a38a3c4aSAlexandre Courbot 
29*a38a3c4aSAlexandre Courbot #if defined(CONFIG_OF_LIBFDT)
30*a38a3c4aSAlexandre Courbot 
31*a38a3c4aSAlexandre Courbot int gpu_enable_node(void *blob, const char *gpupath);
32*a38a3c4aSAlexandre Courbot 
33*a38a3c4aSAlexandre Courbot #else /* CONFIG_OF_LIBFDT */
34*a38a3c4aSAlexandre Courbot 
35*a38a3c4aSAlexandre Courbot static inline int gpu_enable_node(void *blob, const char *gpupath)
36*a38a3c4aSAlexandre Courbot {
37*a38a3c4aSAlexandre Courbot 	return 0;
38*a38a3c4aSAlexandre Courbot }
39*a38a3c4aSAlexandre Courbot 
40*a38a3c4aSAlexandre Courbot #endif /* CONFIG_OF_LIBFDT */
41*a38a3c4aSAlexandre Courbot 
42*a38a3c4aSAlexandre Courbot #endif	/* __ASM_ARCH_TEGRA_GPU_H */
43