Add support for reading GPU's unique ID
Add support and testing for reading the Unique ID associated with a specific GPU. This ID will persist across reboots, even if the GPU is moved to a different machine. Note that this is per-GPU, not per-card, as some cards have multiple GPUs, and each GPU will get a unique identifier Change-Id: Idce50c6febc2ceb1a4c1200d2489ec8b9d8fe174
Este cometimento está contido em:
1 ascendente
dbdb1a9248
cometimento
35d2807196
6 ficheiros modificados
+48
Não existem ficheiros que correspondam à sua pesquisa
@@ -120,6 +120,19 @@ void TestSysInfoRead::Run(void) {
|
||||
std::cout << " (" << std::dec << val_ui64 << ")" << std::endl;
|
||||
}
|
||||
|
||||
err = rsmi_dev_unique_id_get(i, &val_ui64);
|
||||
if (err == RSMI_STATUS_NOT_SUPPORTED) {
|
||||
std::cout <<
|
||||
"\t**rsmi_dev_unique_id() is not supported"
|
||||
" on this machine" << std::endl;
|
||||
} else {
|
||||
CHK_ERR_ASRT(err)
|
||||
IF_VERB(STANDARD) {
|
||||
std::cout << "\t**GPU Unique ID : " << std::hex << val_ui64 <<
|
||||
std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
err = rsmi_version_get(&ver);
|
||||
CHK_ERR_ASRT(err)
|
||||
|
||||
|
||||
Criar uma nova questão referindo esta
Bloquear um utilizador