Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/amdgpu/dpm: add new callback to fetch vce clock state (v2)

Will be used by the new info ioctl query.

v2: fetch a single state per request

Reviewed-by: Rex Zhu <Rex.Zhu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

+6
+5
drivers/gpu/drm/amd/amdgpu/amdgpu_dpm.h
··· 271 271 int (*set_sclk_od)(struct amdgpu_device *adev, uint32_t value); 272 272 int (*get_mclk_od)(struct amdgpu_device *adev); 273 273 int (*set_mclk_od)(struct amdgpu_device *adev, uint32_t value); 274 + struct amd_vce_state* (*get_vce_clock_state)(struct amdgpu_device *adev, unsigned idx); 274 275 }; 275 276 276 277 #define amdgpu_dpm_pre_set_power_state(adev) (adev)->pm.funcs->pre_set_power_state((adev)) ··· 374 373 #define amdgpu_dpm_dispatch_task(adev, event_id, input, output) \ 375 374 (adev)->powerplay.pp_funcs->dispatch_tasks((adev)->powerplay.pp_handle, (event_id), (input), (output)) 376 375 376 + #define amdgpu_dpm_get_vce_clock_state(adev, i) \ 377 + ((adev)->pp_enabled ? \ 378 + (adev)->powerplay.pp_funcs->get_vce_clock_state((adev)->powerplay.pp_handle, (i)) : \ 379 + (adev)->pm.funcs->get_vce_clock_state((adev), (i))) 377 380 378 381 struct amdgpu_dpm { 379 382 struct amdgpu_ps *ps;
+1
drivers/gpu/drm/amd/powerplay/inc/amd_powerplay.h
··· 359 359 int (*get_mclk_od)(void *handle); 360 360 int (*set_mclk_od)(void *handle, uint32_t value); 361 361 int (*read_sensor)(void *handle, int idx, int32_t *value); 362 + struct amd_vce_state* (*get_vce_clock_state)(void *handle, unsigned idx); 362 363 }; 363 364 364 365 struct amd_powerplay {