Renamed API amdsmi_dev_get_drm_render_minor to
amdsmi_get_gpu_drm_render_minor
grep -rli 'amdsmi_dev_get_drm_render_minor' * | xargs -i@ sed -i
's/amdsmi_dev_get_drm_render_minor/amdsmi_get_gpu_drm_render_minor/g' @
Change-Id: Icf6a1ba28ee3ff7f1fa66bad5d600725aad0bfca
[ROCm/amdsmi commit: ac1b857f24]
This commit is contained in:
committed by
Naveen Krishna Chatradhi
vanhempi
acd7475ad0
commit
3ef24c6323
@@ -2958,7 +2958,7 @@ except AmdSmiException as e:
|
||||
print(e)
|
||||
```
|
||||
|
||||
## amdsmi_dev_get_drm_render_minor
|
||||
## amdsmi_get_gpu_drm_render_minor
|
||||
Description: Get the drm minor number associated with this device.
|
||||
|
||||
Input parameters:
|
||||
@@ -2967,7 +2967,7 @@ Input parameters:
|
||||
|
||||
Output: drm minor number
|
||||
|
||||
Exceptions that can be thrown by `amdsmi_dev_get_drm_render_minor` function:
|
||||
Exceptions that can be thrown by `amdsmi_get_gpu_drm_render_minor` function:
|
||||
* `AmdSmiLibraryException`
|
||||
* `AmdSmiRetryException`
|
||||
* `AmdSmiParameterException`
|
||||
@@ -2980,7 +2980,7 @@ try:
|
||||
print("No GPUs on machine")
|
||||
else:
|
||||
for device in devices:
|
||||
render_minor = amdsmi_dev_get_drm_render_minor(device)
|
||||
render_minor = amdsmi_get_gpu_drm_render_minor(device)
|
||||
print(render_minor)
|
||||
except AmdSmiException as e:
|
||||
print(e)
|
||||
|
||||
@@ -160,7 +160,7 @@ from .amdsmi_interface import AmdSmiEventReader
|
||||
from .amdsmi_interface import amdsmi_get_gpu_vendor_name
|
||||
from .amdsmi_interface import amdsmi_get_gpu_id
|
||||
from .amdsmi_interface import amdsmi_get_gpu_vram_vendor
|
||||
from .amdsmi_interface import amdsmi_dev_get_drm_render_minor
|
||||
from .amdsmi_interface import amdsmi_get_gpu_drm_render_minor
|
||||
from .amdsmi_interface import amdsmi_get_gpu_subsystem_id
|
||||
from .amdsmi_interface import amdsmi_get_gpu_subsystem_name
|
||||
|
||||
|
||||
@@ -1121,7 +1121,7 @@ def amdsmi_get_gpu_vram_vendor(processor_handle: amdsmi_wrapper.amdsmi_processor
|
||||
return vram_vendor.value.decode("utf-8")
|
||||
|
||||
|
||||
def amdsmi_dev_get_drm_render_minor(processor_handle: amdsmi_wrapper.amdsmi_processor_handle):
|
||||
def amdsmi_get_gpu_drm_render_minor(processor_handle: amdsmi_wrapper.amdsmi_processor_handle):
|
||||
if not isinstance(processor_handle, amdsmi_wrapper.amdsmi_processor_handle):
|
||||
raise AmdSmiParameterException(
|
||||
processor_handle, amdsmi_wrapper.amdsmi_processor_handle
|
||||
@@ -1129,7 +1129,7 @@ def amdsmi_dev_get_drm_render_minor(processor_handle: amdsmi_wrapper.amdsmi_proc
|
||||
minor = ctypes.c_uint32()
|
||||
|
||||
_check_res(
|
||||
amdsmi_wrapper.amdsmi_dev_get_drm_render_minor(
|
||||
amdsmi_wrapper.amdsmi_get_gpu_drm_render_minor(
|
||||
processor_handle, ctypes.byref(minor)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -1436,9 +1436,9 @@ amdsmi_get_gpu_subsystem_id.argtypes = [amdsmi_processor_handle, ctypes.POINTER(
|
||||
amdsmi_get_gpu_subsystem_name = _libraries['libamd_smi.so'].amdsmi_get_gpu_subsystem_name
|
||||
amdsmi_get_gpu_subsystem_name.restype = amdsmi_status_t
|
||||
amdsmi_get_gpu_subsystem_name.argtypes = [amdsmi_processor_handle, ctypes.POINTER(ctypes.c_char), size_t]
|
||||
amdsmi_dev_get_drm_render_minor = _libraries['libamd_smi.so'].amdsmi_dev_get_drm_render_minor
|
||||
amdsmi_dev_get_drm_render_minor.restype = amdsmi_status_t
|
||||
amdsmi_dev_get_drm_render_minor.argtypes = [amdsmi_processor_handle, ctypes.POINTER(ctypes.c_uint32)]
|
||||
amdsmi_get_gpu_drm_render_minor = _libraries['libamd_smi.so'].amdsmi_get_gpu_drm_render_minor
|
||||
amdsmi_get_gpu_drm_render_minor.restype = amdsmi_status_t
|
||||
amdsmi_get_gpu_drm_render_minor.argtypes = [amdsmi_processor_handle, ctypes.POINTER(ctypes.c_uint32)]
|
||||
amdsmi_dev_get_pci_bandwidth = _libraries['libamd_smi.so'].amdsmi_dev_get_pci_bandwidth
|
||||
amdsmi_dev_get_pci_bandwidth.restype = amdsmi_status_t
|
||||
amdsmi_dev_get_pci_bandwidth.argtypes = [amdsmi_processor_handle, ctypes.POINTER(struct_c__SA_amdsmi_pcie_bandwidth_t)]
|
||||
@@ -1852,7 +1852,7 @@ __all__ = \
|
||||
'amdsmi_dev_close_supported_func_iterator',
|
||||
'amdsmi_dev_counter_group_supported', 'amdsmi_dev_create_counter',
|
||||
'amdsmi_dev_destroy_counter', 'amdsmi_dev_get_busy_percent',
|
||||
'amdsmi_dev_get_drm_render_minor', 'amdsmi_dev_get_ecc_count',
|
||||
'amdsmi_get_gpu_drm_render_minor', 'amdsmi_dev_get_ecc_count',
|
||||
'amdsmi_dev_get_ecc_enabled', 'amdsmi_dev_get_ecc_status',
|
||||
'amdsmi_dev_get_energy_count', 'amdsmi_dev_get_fan_rpms',
|
||||
'amdsmi_dev_get_fan_speed', 'amdsmi_dev_get_fan_speed_max',
|
||||
|
||||
@@ -290,7 +290,7 @@ class Formatter:
|
||||
| """ + self.style.text(" 1 Get device vendor name. Api: amdsmi_get_gpu_vendor_name <bdf>") + """ |
|
||||
| """ + self.style.text(" 2 Get device id. Api: amdsmi_get_gpu_id <bdf>") + """ |
|
||||
| """ + self.style.text(" 3 Get device vram vendor. Api: amdsmi_get_gpu_vram_vendor <bdf>") + """ |
|
||||
| """ + self.style.text(" 4 Get device drm render minor. Api: amdsmi_dev_get_drm_render_minor <bdf>") + """ |
|
||||
| """ + self.style.text(" 4 Get device drm render minor. Api: amdsmi_get_gpu_drm_render_minor <bdf>") + """ |
|
||||
| """ + self.style.text(" 5 Get device subsystem id. Api: amdsmi_get_gpu_subsystem_id <bdf>") + """ |
|
||||
| """ + self.style.text(" 6 Get device subsystem name. Api: amdsmi_get_gpu_subsystem_name <bdf>") + """ |
|
||||
| """ + self.style.text(" 7 Get device pci id. Api: amdsmi_dev_get_pci_id <bdf>") + """ |
|
||||
@@ -731,7 +731,7 @@ commands = {
|
||||
3: [smi_api.amdsmi_get_gpu_vram_vendor, {
|
||||
"device_identifier1": [None, True]
|
||||
}],
|
||||
4: [smi_api.amdsmi_dev_get_drm_render_minor, {
|
||||
4: [smi_api.amdsmi_get_gpu_drm_render_minor, {
|
||||
"device_identifier1": [None, True]
|
||||
}],
|
||||
5: [smi_api.amdsmi_get_gpu_subsystem_id, {
|
||||
|
||||
Viittaa uudesa ongelmassa
Block a user