File tree Expand file tree Collapse file tree 2 files changed +18
-0
lines changed
drivers/gpu/drm/amd/amdgpu Expand file tree Collapse file tree 2 files changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -131,6 +131,8 @@ static void gfx_v11_0_ring_invalidate_tlbs(struct amdgpu_ring *ring,
131131 bool all_hub , uint8_t dst_sel );
132132static void gfx_v11_0_set_safe_mode (struct amdgpu_device * adev );
133133static void gfx_v11_0_unset_safe_mode (struct amdgpu_device * adev );
134+ static void gfx_v11_0_update_perf_clk (struct amdgpu_device * adev ,
135+ bool enable );
134136
135137static void gfx11_kiq_set_resources (struct amdgpu_ring * kiq_ring , uint64_t queue_mask )
136138{
@@ -1139,6 +1141,7 @@ static const struct amdgpu_gfx_funcs gfx_v11_0_gfx_funcs = {
11391141 .read_wave_vgprs = & gfx_v11_0_read_wave_vgprs ,
11401142 .select_me_pipe_q = & gfx_v11_0_select_me_pipe_q ,
11411143 .init_spm_golden = & gfx_v11_0_init_spm_golden_registers ,
1144+ .update_perfmon_mgcg = & gfx_v11_0_update_perf_clk ,
11421145};
11431146
11441147static int gfx_v11_0_gpu_early_init (struct amdgpu_device * adev )
Original file line number Diff line number Diff line change @@ -494,6 +494,20 @@ static void soc21_pre_asic_init(struct amdgpu_device *adev)
494494{
495495}
496496
497+ static int soc21_update_umd_stable_pstate (struct amdgpu_device * adev ,
498+ bool enter )
499+ {
500+ if (enter )
501+ amdgpu_gfx_rlc_enter_safe_mode (adev );
502+ else
503+ amdgpu_gfx_rlc_exit_safe_mode (adev );
504+
505+ if (adev -> gfx .funcs -> update_perfmon_mgcg )
506+ adev -> gfx .funcs -> update_perfmon_mgcg (adev , !enter );
507+
508+ return 0 ;
509+ }
510+
497511static const struct amdgpu_asic_funcs soc21_asic_funcs =
498512{
499513 .read_disabled_bios = & soc21_read_disabled_bios ,
@@ -513,6 +527,7 @@ static const struct amdgpu_asic_funcs soc21_asic_funcs =
513527 .supports_baco = & amdgpu_dpm_is_baco_supported ,
514528 .pre_asic_init = & soc21_pre_asic_init ,
515529 .query_video_codecs = & soc21_query_video_codecs ,
530+ .update_umd_stable_pstate = & soc21_update_umd_stable_pstate ,
516531};
517532
518533static int soc21_common_early_init (void * handle )
You can’t perform that action at this time.
0 commit comments