162306a36Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */ 262306a36Sopenharmony_ci/** HPI Version Definitions 362306a36Sopenharmony_ciDevelopment releases have odd minor version. 462306a36Sopenharmony_ciProduction releases have even minor version. 562306a36Sopenharmony_ci 662306a36Sopenharmony_ci\file hpi_version.h 762306a36Sopenharmony_ci*/ 862306a36Sopenharmony_ci 962306a36Sopenharmony_ci#ifndef _HPI_VERSION_H 1062306a36Sopenharmony_ci#define _HPI_VERSION_H 1162306a36Sopenharmony_ci 1262306a36Sopenharmony_ci/* Use single digits for versions less that 10 to avoid octal. */ 1362306a36Sopenharmony_ci/* *** HPI_VER is the only edit required to update version *** */ 1462306a36Sopenharmony_ci/** HPI version */ 1562306a36Sopenharmony_ci#define HPI_VER HPI_VERSION_CONSTRUCTOR(4, 14, 3) 1662306a36Sopenharmony_ci 1762306a36Sopenharmony_ci/** HPI version string in dotted decimal format */ 1862306a36Sopenharmony_ci#define HPI_VER_STRING "4.14.03" 1962306a36Sopenharmony_ci 2062306a36Sopenharmony_ci/** Library version as documented in hpi-api-versions.txt */ 2162306a36Sopenharmony_ci#define HPI_LIB_VER HPI_VERSION_CONSTRUCTOR(10, 4, 0) 2262306a36Sopenharmony_ci 2362306a36Sopenharmony_ci/** Construct hpi version number from major, minor, release numbers */ 2462306a36Sopenharmony_ci#define HPI_VERSION_CONSTRUCTOR(maj, min, r) ((maj << 16) + (min << 8) + r) 2562306a36Sopenharmony_ci 2662306a36Sopenharmony_ci/** Extract major version from hpi version number */ 2762306a36Sopenharmony_ci#define HPI_VER_MAJOR(v) ((int)(v >> 16)) 2862306a36Sopenharmony_ci/** Extract minor version from hpi version number */ 2962306a36Sopenharmony_ci#define HPI_VER_MINOR(v) ((int)((v >> 8) & 0xFF)) 3062306a36Sopenharmony_ci/** Extract release from hpi version number */ 3162306a36Sopenharmony_ci#define HPI_VER_RELEASE(v) ((int)(v & 0xFF)) 3262306a36Sopenharmony_ci 3362306a36Sopenharmony_ci#endif 34