Implement rdc_device_get_component_version API related code

Implement an API to obtain the version information of the rdc calling component.
See rdc_component_t for details on available components.
It can be expanded later if necessary.

Change-Id: I03b48f774179c52c57b606704283add74ca39a02
Signed-off-by: Chen Gong <curry.gong@amd.com>
This commit is contained in:
Chen Gong
2024-08-18 19:29:04 +08:00
committed by Galantsev, Dmitrii
parent 69a9f24b6e
commit 5a3fd9fbc1
9 changed files with 109 additions and 0 deletions
+9
View File
@@ -182,6 +182,15 @@ rdc_status_t rdc_device_get_attributes(rdc_handle_t p_rdc_handle, uint32_t gpu_i
->rdc_device_get_attributes(gpu_index, p_rdc_attr);
}
rdc_status_t rdc_device_get_component_version(rdc_handle_t p_rdc_handle, rdc_component_t component, rdc_component_version_t* p_rdc_compv) {
if (!p_rdc_handle || !p_rdc_compv) {
return RDC_ST_INVALID_HANDLER;
}
return static_cast<amd::rdc::RdcHandler*>(p_rdc_handle)
->rdc_device_get_component_version(component, p_rdc_compv);
}
rdc_status_t rdc_group_field_create(rdc_handle_t p_rdc_handle, uint32_t num_field_ids,
rdc_field_t* field_ids, const char* field_group_name,
rdc_field_grp_t* rdc_field_group_id) {