283 커밋

작성자 SHA1 메시지 날짜
Kent Russell 0e18159c0e README: Remove restrictive licensing language
Also update copyright years

Signed-off-by: Kent Russell <kent.russell@amd.com>
Change-Id: Ic9ead543c4937680afc1957623c4d5fcbfbd58b0


[ROCm/rocm_smi_lib commit: 85571318e2]
2022-03-16 13:52:25 -04:00
Hao Zhou b8fe06926d Merge amd-staging into amd-master 20220310
Signed-off-by: Hao Zhou <Hao.Zhou@amd.com>
Change-Id: I8fcf65fa293919572468a786409db75ea97c1097


[ROCm/rocm_smi_lib commit: 87af568be9]
2022-03-10 14:07:38 +08:00
Elena Sakhnovitch 090011b153 [rocm_smi.py] resetPowerOverdrive fix
resetPowerOverdrive: improve output messages.

Signed-off-by: Elena Sakhnovitch
Change-Id: Ic5b9084f0637458c36e460231f2d3622b0a23aa6


[ROCm/rocm_smi_lib commit: a3317714cb]
2022-03-04 11:26:45 -05:00
Ranjith Ramakrishnan f391b5d739 File reorganization with backward compatibility
Wrapper header files
Soft link to libraries and binaries
rocm_smi.py and rsmiBindings.py installed in libexec/rocm_smi
Binaries, libraries and header files installed as per File Reorg folder structure

Change-Id: I3166ab67f89c2ae4aafbc87bb00c9a5233221ade


[ROCm/rocm_smi_lib commit: f1da5591b5]
2022-03-03 18:48:52 -05:00
Hao Zhou 5ed1301080 Merge amd-staging into amd-master 20220224
Signed-off-by: Hao Zhou <Hao.Zhou@amd.com>
Change-Id: I371300c32821939aec486a70d22bcdd005971e95


[ROCm/rocm_smi_lib commit: 35ad11c7d5]
2022-02-24 16:41:38 +08:00
Elena Sakhnovitch 45763cc1bb [rocm_smi.py]: fix input error type for --setclock
signed-off-by: Elena Sakhnovitch
Change-Id: I9626978780f360c591fb8908f5b759f2289dff0b


[ROCm/rocm_smi_lib commit: 9b871fcd9f]
2022-02-22 14:24:38 -05:00
Hao Zhou 0098b0e5d9 Merge amd-staging into amd-master 20220211
Signed-off-by: Hao Zhou <Hao.Zhou@amd.com>
Change-Id: I95fd0cafb212a3e0f64b58ba6a009a4cd37ae0a6


[ROCm/rocm_smi_lib commit: 19c569146c]
2022-02-11 10:20:57 +08:00
Ori Messinger 9d6285f6c8 ROCm SMI CLI: Hide Failed Command Warning
The purpose of this patch is to hide 'One or more commands failed.'
from showing up, unless an appropriate log level has been set.

You can set the loglevel in the CLI with:
--loglevel <debug/info/warning/error/critical>

Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Change-Id: Ifa309cd62596491a6ea5892e0752251f037fc0e9


[ROCm/rocm_smi_lib commit: 007f326c34]
2022-02-09 11:52:33 -05:00
Hao Zhou 4fd0e1357e Merge amd-staging into amd-master 20220121
Signed-off-by: Hao Zhou <Hao.Zhou@amd.com>
Change-Id: I0076befd07044063076f31332baa14ea0bdfb5b4


[ROCm/rocm_smi_lib commit: 6e7c204564]
2022-01-21 11:50:24 +08:00
Sreekant Somasekharan 8266782850 Print ASD firmware version in hex instead of decimal format
Change-Id: Idf113f63b79f2d2903ae795d272d232a43680516


[ROCm/rocm_smi_lib commit: cf2f0b0508]
2022-01-18 10:44:20 -05:00
Hao Zhou 6d2fbad79e Merge amd-staging into amd-master
Signed-off-by: Hao Zhou <Hao.Zhou@amd.com>
Change-Id: Ic324e60cd33d0db539537a978710d9c87c1dbd2e


[ROCm/rocm_smi_lib commit: 3ef213258b]
2021-12-09 10:24:19 +08:00
Elena Sakhnovitch 5553c7fb40 [rocm_smi.py] remove \r symbol at print
Remove carriage return at the end of the line in printLog function.
On linux end of line is encoded with \n, not \n\r.

Change-Id: If3835d773033b53a7f25b4a0284df359a6f9555d


[ROCm/rocm_smi_lib commit: 1aeb27c4c9]
2021-12-08 10:13:56 -05:00
Divya Shikre c23694e66a Add fix to display correct GPU Memory Activity and GFX Activity value.
Driver mem fills in 0xFF for all for the metrices not supported for that ASIC.
So if 0xFF is detected, return RSMI_STATUS_NOT_SUPPORTED

Signed-off-by: Divya Shikre <DivyaUday.Shikre@amd.com>
Change-Id: I86a38148c7a288ea0db94893f685560eaac098ab


[ROCm/rocm_smi_lib commit: 7b1daaef96]
2021-11-25 14:28:06 -05:00
Ori Messinger 4883fa50c4 ROCm SMI CLI: Fix printErrLog Arguments
This patch removes every erroneous occurance of a third argument
when calling printErrLog(device, err), since it takes two arguments.

Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Change-Id: I5971cc68b69c86f37c69f44e4785dabfc82c7955


[ROCm/rocm_smi_lib commit: 40eed25a3b]
2021-11-08 12:54:00 -05:00
Kent Russell c9d18c953d Merge amd-staging into amd-master
Conflicts:
	python_smi_tools/rocm_smi.py

Change-Id: Iad29365d4dd0ac30d19013dae31105343b126733


[ROCm/rocm_smi_lib commit: 98baeca615]
2021-11-01 11:47:00 -04:00
Elena Sakhnovitch 8a5effb2e1 [ROCm-SMI] add --showNodesBw
Display min and max bandwidth between gpu nodes

Signed-off-by: Elena Sakhnovitch
Change-Id: I7289fb83f80e2f899996b7d7560ece670cc5f31f


[ROCm/rocm_smi_lib commit: 13cde8429d]
2021-10-29 12:49:35 -04:00
Elena Sakhnovitch f0a86d3d29 [rocm_smi.py] remove repetitive footnote
Printing "Primary die (usually one above or below the secondary) shows
total (primary + secondary) socket power information" footnote only one time, not
for every secondary die.

Signed-off-by: Elena Sakhnovitch
Change-Id: Iae9c5c94945ec38ecdb128a576a4eacafc30a044


[ROCm/rocm_smi_lib commit: 15e4fe80e1]
2021-10-29 08:32:06 -04:00
Ori Messinger b1720b42cd ROCm SMI CLI: Add --showtopoaccess Functionality
The purpose of this patch is to implement --showtopoaccess
functionality in the CLI, which shows True or False if P2P is
possible between two given GPUs.

Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Change-Id: I07d70d80ae7b484136b31d5d22780c4990029391


[ROCm/rocm_smi_lib commit: e2d9a37e5f]
2021-10-14 11:06:05 -04:00
Elena Sakhnovitch 683df7e44c [rocm_smi.py]: fix fan 255% error
signed-off-by: Elena Sakhnovitch
Change-Id: I265ba32bc3777db5f04f1924547fe432ba78c3d0


[ROCm/rocm_smi_lib commit: 2f84906cc2]
2021-09-29 21:11:06 -04:00
Elena Sakhnovitch bc5030e721 [rocm_smi.py]: pep8 formatting
signed-off-by: Elena Sakhnovitch
Change-Id: If12b3371cd6acac16d9f6b3adf5f5cc8df28992f


[ROCm/rocm_smi_lib commit: 80140c3b02]
2021-08-26 10:23:58 -04:00
Elena Sakhnovitch 63d9a19053 [rocm_smi.py] --showpower error bugfix
Fix error message in -P for secondary die

Signed-off-by: Elena Sakhnovitch
Change-Id: Ica3c0a83b565d2231fad23389b9378056a0f56b3


[ROCm/rocm_smi_lib commit: 6a01b6b2ec]
2021-07-30 15:20:21 -04:00
Elena Sakhnovitch 6496488d1d [rocm_smi.py] add secondary die check.
Signed-off-by: Elena Sakhnovitch <Elena.Sakhnovitch@amd.com>
Change-Id: I46618002c1967ec115db88becbaba9e7c0a08af1


[ROCm/rocm_smi_lib commit: 2c39e6cf51]
2021-07-30 15:20:21 -04:00
Harish Kasiviswanathan 42b0e1c549 rocm_smi.py: Remove extraneous line during process termination
During the tail end when process is terminating, subprocess module fails
to find the process. This results in extraneous printing of a line with
char 'b'. Fix this.

BUG: SWDEV-296409

Signed-off-by: Harish Kasiviswanathan <Harish.Kasiviswanathan@amd.com>
Change-Id: I39aacf8ae948a5acec0aa93296cc0e0aec88b3ef


[ROCm/rocm_smi_lib commit: cef19745d1]
2021-07-30 15:20:21 -04:00
Elena Sakhnovitch 578d20c037 [rocm_smi.py] --showpower error bugfix
Fix error message in -P for secondary die

Signed-off-by: Elena Sakhnovitch
Change-Id: Ica3c0a83b565d2231fad23389b9378056a0f56b3


[ROCm/rocm_smi_lib commit: 2db7e2a312]
2021-07-30 00:08:14 -04:00
Elena Sakhnovitch ebba123919 [rocm_smi.py] add secondary die check.
Signed-off-by: Elena Sakhnovitch <Elena.Sakhnovitch@amd.com>
Change-Id: I46618002c1967ec115db88becbaba9e7c0a08af1


[ROCm/rocm_smi_lib commit: b59e752122]
2021-07-29 17:46:12 -04:00
Harish Kasiviswanathan 3da3df8905 rocm_smi.py: Remove extraneous line during process termination
During the tail end when process is terminating, subprocess module fails
to find the process. This results in extraneous printing of a line with
char 'b'. Fix this.

BUG: SWDEV-296409

Signed-off-by: Harish Kasiviswanathan <Harish.Kasiviswanathan@amd.com>
Change-Id: I39aacf8ae948a5acec0aa93296cc0e0aec88b3ef


[ROCm/rocm_smi_lib commit: a03acf2c07]
2021-07-27 16:26:49 -04:00
Ori Messinger bb6e5c5a8b ROCm SMI Python CLI: Fix printLog Collisions
Python's default 'print' implementation is not thread safe, causing
empty lines to be printed during multithreaded code execution.

This fixes the --showevents output for multi-GPU systems.

Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Change-Id: I72f7341cdf4401f1fed4cd8f7d7a4a90bf9a3a4c


[ROCm/rocm_smi_lib commit: 8d5ced1f60]
2021-07-27 15:26:37 -04:00
Ori Messinger e5da211b1c ROCm SMI Python CLI: Add Zero Padding to Device Model
Use zero padding for the hexadecimal value 'device_model' inside
showProductName with a padding length of 4.

Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Change-Id: I962b94d414c6ba050d951486ad9e7559123f8850


[ROCm/rocm_smi_lib commit: 034caf6f76]
2021-07-27 15:22:34 -04:00
Ori Messinger 8e3d715d10 ROCm SMI Python CLI: Fix printLog Collisions
Python's default 'print' implementation is not thread safe, causing
empty lines to be printed during multithreaded code execution.

This fixes the --showevents output for multi-GPU systems.

Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Change-Id: I72f7341cdf4401f1fed4cd8f7d7a4a90bf9a3a4c


[ROCm/rocm_smi_lib commit: 95348f37cc]
2021-07-21 23:58:07 -04:00
Ori Messinger b8324162e0 ROCm SMI Python CLI: Add Zero Padding to Device Model
Use zero padding for the hexadecimal value 'device_model' inside
showProductName with a padding length of 4.

Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Change-Id: I962b94d414c6ba050d951486ad9e7559123f8850


[ROCm/rocm_smi_lib commit: 03ae187a35]
2021-07-17 04:29:52 -04:00
Divya Shikre 47d033876c Add fix to show usage of setperfdeterminism functionality in --help command
Signed-off-by: Divya Shikre <DivyaUday.Shikre@amd.com>
Change-Id: Ife93c887eea2a9aae69f2923dba45c7cde4838d3


[ROCm/rocm_smi_lib commit: 686e6ac654]
2021-05-12 17:29:37 -04:00
Kent Russell 22485bf114 rocm_smi.py: Fix gpu reset error
Since device is a list, we need to pass a single item to the isAmdGpu
function.

Fixes: 17bdc065a1 "rocm_smi.py: Don't try to reset non-AMD GPUs"

Signed-off-by: Kent Russell <kent.russell@amd.com>
Change-Id: I19a74377636ff4589f11d092f41e1d35c1acb307


[ROCm/rocm_smi_lib commit: 242d94a668]
2021-04-28 07:44:55 -04:00
Kent Russell 2ba625e569 rocm_smi.py: Don't try to print absent clock files
Instead of throwing "Unsupported clock" errors for ASICs that don't
support a certain clock type (e.g. dcefclk on MI-series), just dump the
warning to logging.debug and don't try to read the clock

Signed-off-by: Kent Russell <kent.russell@amd.com>
Change-Id: If3cb9a472b03aa535a76fc24bcd9f77122090634


[ROCm/rocm_smi_lib commit: b931380f02]
2021-04-23 10:19:04 -04:00
Ori Messinger 563db7514b rocm_smi.py: Show 'Out of Spec' warning only if required
Use default power cap exposed via sysfs to determine when to
show 'Out of Spec" warning.

Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Change-Id: I0fa3612b50e230856b0d5a390f876b35268d9587


[ROCm/rocm_smi_lib commit: b71e07b3fb]
2021-04-22 14:44:05 -04:00
Ori Messinger 6b4889a3a4 ROCm SMI Python CLI: Add showevent Functionality
Implement showevent functionality in the ROCm SMI Python CLI.

It can be called using --showevents with any combination of:
VM_FAULT, THERMAL_THROTTLE, and/or GPU_RESET
For example:
./rocm-smi --showevents VM_FAULT, THERMAL_THROTTLE, GPU_RESET

Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Change-Id: I905fd9c949e91423b79833a04ab89d6ba3760e62


[ROCm/rocm_smi_lib commit: a9e7e5a475]
2021-04-22 10:21:07 -04:00
Elena 6f751e3fd5 [rocm_smi.py] add energy counter
--showenergycounter

Signed-off-by: Elena Sakhnovitch
Change-Id: Iede0f2b06523f7cb2719489a883e9c49722f8d93


[ROCm/rocm_smi_lib commit: c80fc54500]
2021-04-21 18:40:19 -04:00
Elena 8ee1e50e75 [rocm_smi.py] Coarse Grain Utilization Counters
--showuse
--showmemuse

====================================
========= % time GPU is busy =======
GPU[0]          : GPU use (%): 0
GPU[0]          : GFX Activity: 0
====================================

Change-Id: I9db115ad78b394469206b22d195781a430b2f1d8


[ROCm/rocm_smi_lib commit: 771b4af95c]
2021-04-21 17:23:21 -04:00
Harish Kasiviswanathan 7717cc9d88 Suppress warning message in getFanSpeed function
Many data center cards are fanless. Don't show warning if unable to get
fan speed. The fan speed will be reported as 0

Signed-off-by: Harish Kasiviswanathan <Harish.Kasiviswanathan@amd.com>
Change-Id: I53efe67ac88fb0824cf4820430b46c18bc7692df


[ROCm/rocm_smi_lib commit: 1c9e384c8f]
2021-04-21 15:29:44 -04:00
Divya Shikre 7b99a4e180 Update setrange functionality in CLI
Signed-off-by: Divya Shikre <DivyaUday.Shikre@amd.com>
Change-Id: Ic942bd76297c50caf189bfc0972d30dc42d91f32


[ROCm/rocm_smi_lib commit: 56c132873b]
2021-04-20 15:39:05 -04:00
Divya Shikre 275094d6c5 Add support for mi200 clocks being continuous.
Signed-off-by: Divya Shikre <DivyaUday.Shikre@amd.com>
Change-Id: Ifb7570054572239b9f48eaefe51e879fb3569031


[ROCm/rocm_smi_lib commit: dc431506f5]
2021-04-20 13:12:27 -04:00
Divya Shikre f17e6de490 Fix for cli errors - extra args in perf_determinism, undefined variable in setClocks
Signed-off-by: Divya Shikre <DivyaUday.Shikre@amd.com>
Change-Id: Id138cfcbea4384f520537cc045d358024177b1ac


[ROCm/rocm_smi_lib commit: d9f7bd0ff4]
2021-04-19 17:32:07 -04:00
Elena 134bb5d820 Adding 4 new HBM temperature sensors.
Signed-off-by: Elena Sakhnovitch
Change-Id: Iaea04c38e8c2353e85d8aa2b871fdb82727157de


[ROCm/rocm_smi_lib commit: 81c066350f]
2021-04-17 23:58:49 -04:00
Kent Russell 17bdc065a1 rocm_smi.py: Don't try to reset non-AMD GPUs
This won't work for obvious reasons, so exit with an error instead of
trying to access a file that doesn't exist and segfaulting

Change-Id: Id1230922fa6e9a19e9394280faad88a43c7d2e34


[ROCm/rocm_smi_lib commit: c7c2ac5559]
2021-04-13 08:00:17 -04:00
Divya Shikre b44fccf1b3 Update performance determinism api as per the modified sysfs interface.
Signed-off-by: Divya Shikre <DivyaUday.Shikre@amd.com>
Change-Id: Ib0ec5128819644a2ff6c916da9194a7fe1dad795


[ROCm/rocm_smi_lib commit: aaf2120117]
2021-04-07 16:38:48 -04:00
Chris Freehill 37e617e0c8 Handle set freq for double-digit index in rocm_smi.py
rocm_smi.py --set<m|s>clk was treating the freq as a string.
This causes problems in parsing when the index is more than 1
digit. Now, treat the indexes as integers.

Change-Id: Ia0d859d33b685fe90689a86ff1c83980808b1514


[ROCm/rocm_smi_lib commit: 11440536cf]
2021-02-23 18:51:29 -06:00
Ori Messinger eaec11ce8a ROCm SMI Python CLI: Fix Lower Power Cap Warning
The purpose of this patch is to fix a power cap bug for --setpoweroverdrive.
This bug occurs when the user attempts to set a lower wattage than the current
or default wattage, which displays an unnecessary warning message.

Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Change-Id: I730d2c6031b7d7c4af5acf32ecd28da5ca21ab12


[ROCm/rocm_smi_lib commit: 20e2d260fb]
2021-01-27 03:24:22 -05:00
Ori Messinger 12fd0f8c40 ROCm SMI Python CLI & LIB: Add GPU Reset Functionality
The purpose of this patch is to implement GPU reset functionality
in the LIB, and to call it from the rocm_smi python CLI.

Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Change-Id: Iaf525f7016f8354a7fd93af0209ca2e97ef4fd56


[ROCm/rocm_smi_lib commit: 80f629b9be]
2021-01-26 17:52:24 -05:00
Ori Messinger 4c3c50ea13 ROCm SMI Python CLI: Fix Fan Speed Bug
The purpose of this patch is to fix a fan speed bug for --showfan.
This bug occurs when the current and/or maximum fan speeds are not
found by the LIB, which displayed an unclear error message.

Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Change-Id: Ied06e460f22391238dd2d86572813e2a5a64f45b


[ROCm/rocm_smi_lib commit: 4f297bdeb3]
2021-01-26 08:51:04 -05:00
Kent Russell 98a39bf706 Fix type in --setmrange documentation
mrange is for MCLK, not SCLK, so fix the typo accordingly

Change-Id: Ib20774b073288a8ec193322f2f767616979c95da


[ROCm/rocm_smi_lib commit: a902770f86]
2021-01-25 13:20:20 -05:00
Elena e03f3b97f2 ROCm SMI Pythoc CLI: Fix division by zero fan bug
Signed-off-by: Elena Sakhnovitch <Elena.Sakhnovitch@amd.com>
Change-Id: If259ac1ad6d77ce85b2b7616d972b6e7964a9f78


[ROCm/rocm_smi_lib commit: 61cdfff562]
2021-01-20 18:21:23 -05:00