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
Este cometimento está contido em:
Chris Freehill cometeu 2020-07-10 12:35:31 -04:00
1 ascendente e2c7ef6422
cometimento 68155baed5
5 ficheiros modificados
+41 -8

Não existem ficheiros que correspondam à sua pesquisa

+3 -2
Ver ficheiro
@@ -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");