Add hal_api_version_str array to display as string after converting each
enum value.
It's easier to understand than using enum value.
If abi version doesn't support about current version and compatible version,
then it needs to notice about not supporting abi_version.
Change-Id: I67f31423a4b9d911b269d8c7560c9907a6bafc8b
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
HAL_ABI_VERSION_END,
};
+static const char *const hal_abi_version_str[] = {
+ [HAL_ABI_VERSION_UNKNOWN] = "Unknown HAL ABI Version",
+ [HAL_ABI_VERSION_TIZEN_6_5] = "HAL_ABI_VERSION_TIZEN_6_5",
+};
+
typedef struct __hal_backend {
const char *name;
const char *vendor;
if (abi_version <= data->curr_version
&& abi_version >= data->compat_version)
return TIZEN_ERROR_NONE;
+
+ _E("%s doesn't support %s of HAL Backend\n", hal_abi_version_str[g_curr_hal_abi_version],
+ hal_abi_version_str[abi_version]);
+ _E("Must use the following ABI versions from %s to %s\n",
+ hal_abi_version_str[data->compat_version],
+ hal_abi_version_str[data->curr_version]);
}
return TIZEN_ERROR_INVALID_PARAMETER;