xref: /rk3399_rockchip-uboot/include/fsl-mc/fsl_dpmng.h (revision a2a55e518f81900ab1538656e5df8d2759ccb1fb)
1*a2a55e51SPrabhakar Kushwaha /* Copyright 2013-2015 Freescale Semiconductor Inc.
27b3bd9a7SJ. German Rivera  *
37b3bd9a7SJ. German Rivera  * SPDX-License-Identifier:	GPL-2.0+
47b3bd9a7SJ. German Rivera  */
57b3bd9a7SJ. German Rivera #ifndef __FSL_DPMNG_H
67b3bd9a7SJ. German Rivera #define __FSL_DPMNG_H
77b3bd9a7SJ. German Rivera 
8*a2a55e51SPrabhakar Kushwaha /* Management Complex General API
9*a2a55e51SPrabhakar Kushwaha  * Contains general API for the Management Complex firmware
107b3bd9a7SJ. German Rivera  */
117b3bd9a7SJ. German Rivera 
127b3bd9a7SJ. German Rivera struct fsl_mc_io;
137b3bd9a7SJ. German Rivera 
147b3bd9a7SJ. German Rivera /**
15*a2a55e51SPrabhakar Kushwaha  * Management Complex firmware version information
167b3bd9a7SJ. German Rivera  */
17*a2a55e51SPrabhakar Kushwaha #define MC_VER_MAJOR 6
187b3bd9a7SJ. German Rivera #define MC_VER_MINOR 0
197b3bd9a7SJ. German Rivera 
20*a2a55e51SPrabhakar Kushwaha /**
21*a2a55e51SPrabhakar Kushwaha  * struct mc_versoin
22*a2a55e51SPrabhakar Kushwaha  * @major: Major version number: incremented on API compatibility changes
23*a2a55e51SPrabhakar Kushwaha  * @minor: Minor version number: incremented on API additions (that are
247b3bd9a7SJ. German Rivera  *		backward compatible); reset when major version is incremented
25*a2a55e51SPrabhakar Kushwaha  * @revision: Internal revision number: incremented on implementation changes
267b3bd9a7SJ. German Rivera  *		and/or bug fixes that have no impact on API
277b3bd9a7SJ. German Rivera  */
28*a2a55e51SPrabhakar Kushwaha struct mc_version {
29*a2a55e51SPrabhakar Kushwaha 	uint32_t major;
30*a2a55e51SPrabhakar Kushwaha 	uint32_t minor;
31*a2a55e51SPrabhakar Kushwaha 	uint32_t revision;
327b3bd9a7SJ. German Rivera };
337b3bd9a7SJ. German Rivera 
347b3bd9a7SJ. German Rivera /**
35*a2a55e51SPrabhakar Kushwaha  * mc_get_version() - Retrieves the Management Complex firmware
36*a2a55e51SPrabhakar Kushwaha  *			version information
37*a2a55e51SPrabhakar Kushwaha  * @mc_io:		Pointer to opaque I/O object
38*a2a55e51SPrabhakar Kushwaha  * @mc_ver_info:	Returned version information structure
397b3bd9a7SJ. German Rivera  *
40*a2a55e51SPrabhakar Kushwaha  * Return:	'0' on Success; Error code otherwise.
417b3bd9a7SJ. German Rivera  */
427b3bd9a7SJ. German Rivera int mc_get_version(struct fsl_mc_io *mc_io, struct mc_version *mc_ver_info);
437b3bd9a7SJ. German Rivera 
447b3bd9a7SJ. German Rivera #endif /* __FSL_DPMNG_H */
45