[SWDEV-484382] Fix VCLK/DCLK outputs for monitor, static, metric

Units were off and VCLK/DCLK outputs were not coming in
properly through amdsmi_get_clk_freq()

Now we match units sent back through rsmi_dev_gpu_clk_freq_get (MHz).

CLI now shows maximum of 2 VCLK/DCLKs otherwise shows N/A if there
is no current_freq listed.

Change-Id: I8a7b66cbb5263e8d396f8568c104e1ce3512923d
Signed-off-by: Charis Poag <Charis.Poag@amd.com>
This commit is contained in:
Charis Poag
2024-12-20 09:59:15 -06:00
committed by Arif, Maisam
orang tua 23a21ea202
melakukan 3226a1d0ea
7 mengubah file dengan 128 tambahan dan 48 penghapusan
+2 -1
Melihat File
@@ -3688,11 +3688,12 @@ def amdsmi_get_clk_freq(
)
)
return {
dict_ret = {
"num_supported": freq.num_supported,
"current": freq.current,
"frequency": list(freq.frequency)[: freq.num_supported],
}
return dict_ret
def amdsmi_get_soc_pstate(