Charis Poag
b6a68dd877
Fix amd-smi CLI calls returning TypeError
...
$ amd-smi version
TypeError: unsupported operand type(s) for |: 'type' and 'type'
---------------
Python3 --versions lower than 3.10
do not support str | None
Using typing Optional and Union, we can create equivalent logic for
str | none
and
str | list | none
Change-Id: I1f4a7ab67333914b33639dc62652881e1127411e
Signed-off-by: Charis Poag <Charis.Poag@amd.com >
[ROCm/amdsmi commit: 5c778cadf1 ]
2024-09-18 16:59:12 -05:00
Harkirat Gill
e73ae3d79d
Fix for GitHub Issue #24 : Update Event Stop Behavior
...
amd-smi event is failing to exit as it waits for all threads to complete before exiting. Each thread has to listen for a maximum of 10 seconds prior to exiting in the current implementation.
Lowered individual listen time for _event_thread allowing for a quicker exit while still capturing all events (Looped until escape sequence detected).
Added logging for escape character, not sure if needed but helps confirm that key press was registered.
Change-Id: I916608754798f966980a558342c7c62693252d7f
[ROCm/amdsmi commit: d263b53797 ]
2024-09-18 14:54:40 -04:00
gabrpham
fbb1071046
[SWDEV-448738] Added rocmsmi extremum command as 'set -L'
...
Change-Id: I997c630bd20cc61673813a2301eb5e3002619a32
Signed-off-by: gabrpham <Gabriel.Pham@amd.com >
Change-Id: Ifa884303f9a0fa058af093a23f5be449bba54f29
[ROCm/amdsmi commit: b7f779182d ]
2024-09-18 14:51:01 -04:00
gabrpham
d04eadec17
Removed _validate_positive function and replaced with _positive_int or _not_negative_int as appropriate
...
Signed-off-by: gabrpham <Gabriel.Pham@amd.com >
Change-Id: I01effcdf9bae31fd8bc926c5d4bdf58274838618
[ROCm/amdsmi commit: 0d4b332fe4 ]
2024-09-17 18:37:16 -04:00
Eisuke Kawashima
0bc6bd2c24
fix(python): fix comparison to True/False
...
from PEP8 (https://peps.python.org/pep-0008/#programming-recommendations ):
> Comparisons to singletons like None should always be done with is or
> is not, never the equality operators.
Change-Id: I710d64c380eaf420f0ad29e65623ee677b094051
Signed-off-by: Galantsev, Dmitrii <dmitrii.galantsev@amd.com >
[ROCm/amdsmi commit: 5fdcaf1248 ]
2024-09-16 17:34:39 -04:00
Maisam Arif
c2b9cdfd2e
Udpated License Dates
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I8ca199c129c06508bc3e23745ab5ac2d20dce928
[ROCm/amdsmi commit: 105db1afcd ]
2024-09-16 16:14:47 -04:00
Michael John
78d4fe59ea
Use correct regex to avoid SyntaxWarning: invalid escape sequence '\.'
...
Change-Id: I1c6179be294bf21c0897a3abf7e8ab1d270ae238
Signed-off-by: Galantsev, Dmitrii <dmitrii.galantsev@amd.com >
[ROCm/amdsmi commit: d9ccc44146 ]
2024-09-16 15:45:15 -04:00
Maisam Arif
cabbdf44cb
[SWDEV-482412] Optimized PCIe Bandwidth gpu_metrics calls
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: Ib37d232b94a080e9b490dd065628d2567aaf4642
[ROCm/amdsmi commit: 787d4462fa ]
2024-09-11 23:26:30 -05:00
Maisam Arif
f63635db78
Bump Version to 24.6.4.0
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I75b6039c221ecea1e36a451d93bb52b5406bd106
[ROCm/amdsmi commit: 397d8d9339 ]
2024-09-11 17:36:07 -04:00
Tim Huang
202ddc01aa
[SWDEV-463402] - Support retrieving connection type and P2P capabilities between two GPUs
...
1. Add a API interface amdsmi_topo_get_p2p_status to retrieve
connection type and P2P capabilities between 2 GPUs.
2. Add getting p2p status test in hw_topology_read
to print P2P capability information.
3. Add below tables for cli topology sub commands:
- CACHE COHERANCY TABLE
- ATOMICS TABLE
- DMA TABLE
- BI-DIRECTIONAL TABLE
Change-Id: I199173030d4170115cea27c472958a4826e4e1bf
Signed-off-by: Tim Huang <tim.huang@amd.com >
[ROCm/amdsmi commit: 260edaa752 ]
2024-09-06 09:42:34 -04:00
Maisam Arif
c343efc353
[SWDEV-450553] Added Subsystem Device ID to amd-smi static --asic
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I428b4993cca027a6eb1bb9c617fe715118a59407
[ROCm/amdsmi commit: bc4ca45862 ]
2024-09-04 12:51:02 -05:00
gabrpham
614c89889c
[SWDEV-450553] Added gpu memory overdrive to metric function
...
Signed-off-by: gabrpham <Gabriel.Pham@amd.com >
Change-Id: If7bd6865d641a5a83c594a4d3c57938b1b6dc18e
[ROCm/amdsmi commit: 7d8e54d0e1 ]
2024-09-04 12:54:14 -04:00
Maisam Arif
adc9b69f39
Updated cli init functions to not intersect with lib init functions
...
Added Quick start script to quickly test python APIs
"python3 -i tools/amdsmi_quick_start.py"
Fixed ESMI lib macros
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I55370a0cb79d631f7f2f2b91568f089b503ebfad
[ROCm/amdsmi commit: 1efb5e9910 ]
2024-09-04 10:23:36 -04:00
Maisam Arif
8fe8943a0e
Added Example commands for amd-smi CLI
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I4a0211f7dd54de9b225e4546509134bb45c97956
[ROCm/amdsmi commit: d40e4d18a0 ]
2024-09-04 09:39:21 -04:00
gabrpham
62d3348c9e
Changed power parameter in amdsmi_get_energy_count() to energy_accumulator
...
Issue linked here: https://github.com/ROCm/amdsmi/issues/38
Signed-off-by: gabrpham <Gabriel.Pham@amd.com >
Change-Id: I622236eb3f0144aefeb6c82d2713b4822bfeeb11
[ROCm/amdsmi commit: 95ca2b83a1 ]
2024-09-04 09:38:08 -04:00
Oliveira, Daniel
e2e63055a6
SWDEV-463399: amdsmi_get_gpu_vram_info() adds bit-width
...
Driver info `amdgpu_gpu_info.vram_bit_width` is exposed through amdsmi_get_gpu_vram_info().
Code changes related to the following:
* API
* CLI
* Unit tests
* Examples
Change-Id: I8abd8db7a603078b2b1c008b2685cecf35caf3d2
Signed-off-by: Oliveira, Daniel <daniel.oliveira@amd.com >
[ROCm/amdsmi commit: 893f13ab98 ]
2024-08-27 18:22:50 -04:00
Maisam Arif
77e3035cf5
[SWDEV-479989] - Fixed if statement for filtering ecc blocks
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I4d0c7579257c98be8a4ba8e5a31b5d9db4305844
[ROCm/amdsmi commit: 78373cb5f7 ]
2024-08-20 03:16:49 -05:00
Maisam Arif
83dfd814c3
[SWDEV-478576] Adjusted Disclaimer
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I0dbdcd1c8ff200336e7ee0e8ca88a5eba1b41057
[ROCm/amdsmi commit: b49c5596b5 ]
2024-08-09 18:50:55 -04:00
Maisam Arif
0a28df87c8
Fixed Guest VM registering as Passthrough VM
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I0edc36e1a114166647dc10ebc646665b62c5d88e
[ROCm/amdsmi commit: 037f8689fe ]
2024-08-09 18:44:44 -04:00
Maisam Arif
1eaf218f2f
Removed metric --ecc & --ecc-blocks commands from VM
...
ecc is not supported on VM
Added static --ras because ras features are still detectable
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: Ied4132b863989dfd67897e00904f04d140fd2773
[ROCm/amdsmi commit: 210680b570 ]
2024-08-09 18:44:44 -04:00
Maisam Arif
b0c05aa04d
[SWDEV-478576] Added Disclaimer for CLI Tool
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I3d432ac3f8c9663365921591d183a5d1f35c4707
[ROCm/amdsmi commit: cec3e4c2a0 ]
2024-08-09 14:14:50 -04:00
Maisam Arif
a3a8a0cfa8
Bump Version to 24.6.3.0
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I902da5e5e9e7441002420afaaef01ca9c6c9666f
[ROCm/amdsmi commit: 40112f5b17 ]
2024-08-08 01:30:51 -05:00
Ranjith Ramakrishnan
8ce27d8bc7
SWDEV-469004 - Append additonal path to system path
...
amd-smi is installed in /opt/rocm-ver/bin, but not as a soft link in wheel package
For amd-smi to work from bin directory, it need the extra path to find the dependent python scripts in /opt/rocm-ver/libexec/amd_smi
Change-Id: I4ff63a8f55949aaac51d85eae849ecc890f4c694
[ROCm/amdsmi commit: 7591eec971 ]
2024-08-08 02:15:04 -04:00
Maisam Arif
7130dc9f04
Fixed handling in GPU/CPU/CORE select functions
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I83d78a8d6cdcbd54e5c79330be577b3a06a00985
[ROCm/amdsmi commit: 574712386f ]
2024-08-05 18:27:30 -04:00
gabrpham
6975697b56
Fixed cli issue with empty cpu/core parameter
...
Change-Id: Id0fee74357a56baaec59ca5359eb00a65cfd6185
Signed-off-by: gabrpham <Gabriel.Pham@amd.com >
[ROCm/amdsmi commit: 0143041262 ]
2024-08-05 16:37:36 -05:00
gabrpham
0df83ddf94
Fixed 'amd-smi process -G'
...
Issue linked here: https://github.com/ROCm/amdsmi/issues/23
Signed-off-by: gabrpham <Gabriel.Pham@amd.com >
Change-Id: I73c2dede8634b21a5dfe0245a202e883fa856de2
[ROCm/amdsmi commit: fe1dc23ade ]
2024-08-02 16:42:08 -04:00
Galantsev, Dmitrii
c44abfcd08
Cleanup convert_SI_unit and misc linter warnings
...
Change-Id: I000ba548b79a7023aabad653125842064fa2e7cb
Signed-off-by: Galantsev, Dmitrii <dmitrii.galantsev@amd.com >
[ROCm/amdsmi commit: 3784f37a3a ]
2024-08-02 10:29:06 -04:00
gabrpham
5b44997728
[SWDEV-439701] Additional GPU error handling
...
Change-Id: Ieb35e9712f2a78acef8961d865dba1d824969ef3
Signed-off-by: gabrpham <Gabriel.Pham@amd.com >
[ROCm/amdsmi commit: de8145387d ]
2024-07-30 16:19:10 -05:00
Charis Poag
e536831413
Fix TypeError: 'type' object is not subscriptable
...
Python 3.8 requires typing import to specify.
Python 3.10, no longer requires typing import.
Change-Id: I5d9844c91932bc3af53acc6dd56eb258f4d18d9b
Signed-off-by: Charis Poag <Charis.Poag@amd.com >
[ROCm/amdsmi commit: ac40e963d3 ]
2024-07-19 16:33:41 -05:00
Galantsev, Dmitrii
12143a4ec8
[SWDEV-471523] - Replace lspci and lscpu with sysfs reads
...
Change-Id: Ia5a12c04d3064787a0f36a961e68533b79e17ed0
Signed-off-by: Galantsev, Dmitrii <dmitrii.galantsev@amd.com >
[ROCm/amdsmi commit: baaa1cc4b6 ]
2024-07-19 00:29:36 -05:00
Maisam Arif
244587525a
Corrected passthrough platform logic
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: Ibbc4f5dd6300efd16f26efe17bc68eb8c22ed8be
[ROCm/amdsmi commit: b5f9e6a91d ]
2024-07-18 17:54:02 -04:00
Maisam Arif
ad3ba88ba5
[SWDEV-474474] - Changed Monitor PCIE_REPLAY count to use gpu_metrics
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I4351a23e8412875bb4b23b30747ac6d0bf3d3c56
[ROCm/amdsmi commit: 5b7be3bf99 ]
2024-07-18 17:53:49 -04:00
Maisam Arif
a7ea536524
[SWDEV-439701] Add missing parameter CLI error cases
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I8a6623ccdd7b16be320ea0f6f48b7b6cb3511983
[ROCm/amdsmi commit: 0fc779b14f ]
2024-07-18 14:24:00 -04:00
Maisam Arif
0865293d27
[SWDEV-472641] Set file opening and writing encoding to utf-8
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: Ic5cdca41b588341f7894de72dfe3d949378f9a61
[ROCm/amdsmi commit: c83bcb7ac9 ]
2024-07-12 09:46:44 -04:00
Maisam Arif
3a7348925e
Bump Version to 24.6.2.0
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: Ic389b6783514e88c43958ff5d3413a4c4a8a884f
[ROCm/amdsmi commit: 548938389d ]
2024-07-10 19:15:17 -05:00
Maisam Arif
8462635270
Added dmon alias for 'amd-smi monitor'
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I4a787034bd7ab1a0d08d8cfdd038add5c35cdea4
[ROCm/amdsmi commit: 6e5c4b422a ]
2024-07-02 11:05:59 -04:00
Maisam Arif
8c87907db9
Updated error code naming to be inline with Host
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I6c66640742a25361ad6399763ee442598ffb0ac6
[ROCm/amdsmi commit: 27cd092c6d ]
2024-06-28 08:58:52 -05:00
Maisam Arif
a449323329
SWDEV-457854 - Unified BM error codes
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I5b232de3b598bd3146eb0528f61c628da93278d9
[ROCm/amdsmi commit: a3758f82dc ]
2024-06-25 18:33:40 -05:00
Maisam Arif
4d4ccf4bde
SWDEV-446724 - Version command human readable output file format fix
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I94de5b03355b503ade307f2a3881acd07266d6c7
[ROCm/amdsmi commit: 943c74b6ef ]
2024-06-24 10:35:34 -05:00
Oliveira, Daniel
45652b301b
fix: [SWDEV-466302] [rocm/amd_smi_lib]
...
Fixes `amdsmi_get_gpu_process_list` now requires sudo to access pid and memory information
Code changes related to the following:
* amdsmi_get_gpu_process_list()
* CLI
Change-Id: I72b154c220276b354c350fcc067c9a7c32e6c173
Signed-off-by: Oliveira, Daniel <daniel.oliveira@amd.com >
[ROCm/amdsmi commit: a20db864b8 ]
2024-06-24 00:38:17 -04:00
Maisam Arif
3ef31b3ed0
SWDEV-435197 - Add process table to CLI monitor subcommand
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: Ibe06f4a4be619ae9cba909c2474b0e482eeb87d5
[ROCm/amdsmi commit: 92f014059e ]
2024-06-19 23:36:55 -05:00
Maisam Arif
5a62ef2b7c
Bump Version to 24.6.1.0 and Update Changelog
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I88b8ad1341d7f1a2e14517db82979bb6b28575e8
[ROCm/amdsmi commit: a3497702cb ]
2024-06-18 23:54:26 -05:00
Bill(Shuzhou) Liu
f86ba0a7c4
Change the clean shader API to clean local data
...
To be align with the unified API.
Change-Id: I2819339fba6f528204cebd3e9605109e82cbc5b4
[ROCm/amdsmi commit: e3c63628e5 ]
2024-06-17 16:23:33 -05:00
Maisam Arif
807ca0ad89
SWDEV-466598 - Fixed CLI process outputs
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I902e82b6e78311e99542b109435346889daa49fc
[ROCm/amdsmi commit: 9fb2c967de ]
2024-06-08 18:31:08 -05:00
Maisam Arif
e154b3c89b
Removed Throttle Status from CLI Tool
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I8eb8f30f821589003201d6d8bb96592ec5f8a483
[ROCm/amdsmi commit: 37c044696d ]
2024-06-07 15:19:48 -05:00
Maisam Arif
99f0468803
Corrected voltage curve cli output in N/A case
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I77e0888d94ba489eb4820cdd6c20e9f7de04241f
[ROCm/amdsmi commit: 2197a393f4 ]
2024-06-06 15:55:22 -04:00
Bill(Shuzhou) Liu
b517f3c214
Change the name of clear sram to run cleaner shader
...
The function is to clean the local data in LDS/GPRs. The clear sram
is misleading.
Change-Id: I0385e6d6348602fe0f347d17e48ed8983f7ceb87
[ROCm/amdsmi commit: 4cf59c4edb ]
2024-06-05 12:07:39 -05:00
Maisam Arif
5e32624382
Bump Version to 24.6.0.0 and Update Changelog for 6.2.0
...
Signed-off-by: Maisam Arif <Maisam.Arif@amd.com >
Change-Id: I7f20094514cbfa32e40a6e4da36785d94839768c
[ROCm/amdsmi commit: 68d8c1ab46 ]
2024-05-31 03:05:42 -05:00
Maisam Arif
7dfe4276cc
Use different sysfs for soc_pstate and xmgi_plpd
...
The sysfs is changed to use the pm_policy folder with multiple
dpm_policy files.
Change-Id: I40fac8de2d0cb127950d238b8196f6d2416778d0
[ROCm/amdsmi commit: e5d1ba4621 ]
2024-05-31 01:38:41 -04:00
Maisam Arif
58177acb0b
SWDEV-461038 - Enabled Passthrough as BM for CLI Commands
...
Signed-off-by: Maisam Arif <maisarif@amd.com >
Change-Id: I1ae6a065f10ce580b45b79c0a8588853f5f304f7
[ROCm/amdsmi commit: 80eeff3dd4 ]
2024-05-30 15:47:14 -04:00