Handle GPU Not detected

Signed-off-by: Maisam Arif <Maisam.Arif@amd.com>
Change-Id: I988b0dddde23b83c1a8e402233b6aa08ce55d0c7
这个提交包含在:
Maisam Arif
2023-11-02 20:54:03 -05:00
父节点 fc02ebc5f2
当前提交 9bfebc6f1c
共修改 2 个文件,包含 9 行新增和 0 行删除
+5
查看文件
@@ -50,6 +50,11 @@ class AMDSMICommands():
sys.exit(-1)
else:
raise e
if len(self.device_handles) == 0:
logging.error('Unable to detect any devices, check if driver is initialized (amdgpu not found in modules)')
sys.exit(-1)
self.stop = ''
+4
查看文件
@@ -154,6 +154,10 @@ class AMDSMIHelpers():
else:
raise e
if len(device_handles) == 0:
logging.error('Unable to find any devices, check if driver is initialized (amdgpu not found in modules)')
sys.exit(-1)
# Handle spacing for the gpu_choices_str
max_padding = int(math.log10(len(device_handles))) + 1