mirror of
https://github.com/torvalds/linux.git
synced 2026-11-07 06:17:02 +01:00
drm/amd/pm: Fix metrics formatting in SMUv15.0.8
Use the right formatting for some fields which are encoded in Q10 format. Signed-off-by: Lijo Lazar <lijo.lazar@amd.com> Reviewed-by: Asad Kamal <asad.kamal@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
6719c0337a
commit
b7d7649f7d
|
|
@ -1770,7 +1770,8 @@ static ssize_t smu_v15_0_8_get_gpu_metrics(struct smu_context *smu, void **table
|
|||
gpu_metrics->mem_max_bandwidth = SMUQ10_ROUND(metrics->MaxDramBandwidth);
|
||||
|
||||
/* Energy counter reported in 15.259uJ (2^-16) units */
|
||||
gpu_metrics->energy_accumulator = metrics->SocketEnergyAcc;
|
||||
gpu_metrics->energy_accumulator =
|
||||
SMUQ10_ROUND(metrics->SocketEnergyAcc);
|
||||
|
||||
for (i = 0; i < NUM_XCC(adev->gfx.xcc_mask); ++i) {
|
||||
xcc_id = GET_INST(GC, i);
|
||||
|
|
@ -1848,7 +1849,7 @@ static ssize_t smu_v15_0_8_get_gpu_metrics(struct smu_context *smu, void **table
|
|||
}
|
||||
|
||||
gpu_metrics->xgmi_link_width = metrics->XgmiWidth;
|
||||
gpu_metrics->xgmi_link_speed = metrics->XgmiBitrate;
|
||||
gpu_metrics->xgmi_link_speed = SMUQ10_ROUND(metrics->XgmiBitrate);
|
||||
|
||||
gpu_metrics->firmware_timestamp = metrics->Timestamp;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user