ef9bfd7216189d85bd5a509e4a3e35784f699f53
[firefly-linux-kernel-4.4.55.git] / drivers / gpu / arm / midgard_for_linux / platform / vexpress / mali_kbase_cpu_vexpress.h
1 /*
2  *
3  * (C) COPYRIGHT 2012-2013, 2015 ARM Limited. All rights reserved.
4  *
5  * This program is free software and is provided to you under the terms of the
6  * GNU General Public License version 2 as published by the Free Software
7  * Foundation, and any use by you of this program is subject to the terms
8  * of such GNU licence.
9  *
10  * A copy of the licence is included with the program, and can also be obtained
11  * from Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
12  * Boston, MA  02110-1301, USA.
13  *
14  */
15
16
17
18
19
20 #ifndef _KBASE_CPU_VEXPRESS_H_
21 #define _KBASE_CPU_VEXPRESS_H_
22
23 /**
24  * Versatile Express implementation of @ref kbase_cpu_clk_speed_func.
25  */
26 int kbase_get_vexpress_cpu_clock_speed(u32 *cpu_clock);
27
28 /**
29  * kbase_get_platform_logic_tile_type -  determines which LogicTile type 
30  * is used by Versatile Express
31  *
32  * When platform_config build parameter is specified as vexpress, i.e.,
33  * platform_config=vexpress, GPU frequency may vary dependent on the
34  * particular platform. The GPU frequency depends on the LogicTile type.
35  *
36  * This function is called by kbase_common_device_init to determine
37  * which LogicTile type is used by the platform by reading the HBI value
38  * of the daughterboard which holds the LogicTile:
39  *
40  * 0x192 HBI0192 Virtex-5
41  * 0x217 HBI0217 Virtex-6
42  * 0x247 HBI0247 Virtex-7
43  *
44  * Return: HBI value of the logic tile daughterboard, zero if not accessible
45  */
46 u32 kbase_get_platform_logic_tile_type(void);
47
48 #endif                          /* _KBASE_CPU_VEXPRESS_H_ */