Handle un-readable kfd properties files

Some systems have kfd sysfs properties entries that
are unreadable--for example, when a multi-gpu system is
dividing the gpus among containers, each container may
only be able to access certain gpus.

Previously, all kfd topology node properties entries were
assumed to be valid. Now, we check for readability before
declaring them "valid".

Fixes SWDEV-240169

Also:
* remove an assertion that would happen when no pcie
device identifier files are found on the system.
* fix cpplint issues

Change-Id: I74321b685159dd2628c890b33c39ad82988cb9dd
这个提交包含在:
Chris Freehill 于 2020-07-10 12:35:31 -04:00 提交
1 父节点 e2c7ef6422
当前提交 68155baed5
5 个文件已更改
+41 -8

没有与搜索条件相匹配的文件

+3 -2
查看文件
@@ -132,8 +132,9 @@ void TestVoltRead::Run(void) {
};
for (uint32_t i = RSMI_VOLT_TYPE_FIRST; i <= RSMI_VOLT_TYPE_LAST; ++i) {
IF_VERB(STANDARD) {
std::cout << "\t** **********" << GetVoltSensorNameStr(static_cast<rsmi_voltage_type_t>(i)) <<
" Voltage **********" << std::endl;
std::cout << "\t** **********" <<
GetVoltSensorNameStr(static_cast<rsmi_voltage_type_t>(i)) <<
" Voltage **********" << std::endl;
}
print_volt_metric(RSMI_VOLT_CURRENT, "Current Voltage");
print_volt_metric(RSMI_VOLT_MAX, "Voltage max value");