From 8bcf57fd991ccadb1c05efcf416a61519b263773 Mon Sep 17 00:00:00 2001 From: Maisam Arif Date: Wed, 29 May 2024 21:20:59 -0500 Subject: [PATCH] Fixed None event being read in AmdSmiEventReader Signed-off-by: Maisam Arif Change-Id: I2141421a133c867a5c91d7d18b73141513f1868b [ROCm/amdsmi commit: 3aa62b082a755921d82ce9ca891c35c6bff00832] --- projects/amdsmi/py-interface/amdsmi_interface.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/projects/amdsmi/py-interface/amdsmi_interface.py b/projects/amdsmi/py-interface/amdsmi_interface.py index 647aa9fd5f..b10bfa0ecf 100644 --- a/projects/amdsmi/py-interface/amdsmi_interface.py +++ b/projects/amdsmi/py-interface/amdsmi_interface.py @@ -421,7 +421,8 @@ class AmdSmiEventReader: self.processor_handle = processor_handle mask = 0 for event_type in event_types: - mask |= (1 << (int(event_type) - 1)) + if event_type != AmdSmiEvtNotificationType.NONE: + mask |= (1 << (int(event_type) - 1)) _check_res(amdsmi_wrapper.amdsmi_init_gpu_event_notification(processor_handle)) _check_res(amdsmi_wrapper.amdsmi_set_gpu_event_notification_mask(