mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-21 17:15:24 -04:00
drm/i915/bw: abstract intel_bw_qgv_point_peakbw()
Add intel_bw_qgv_point_peakbw() helper to avoid looking at struct intel_bw_state internals outside of intel_bw.c. Reviewed-by: Imre Deak <imre.deak@intel.com> Link: https://lore.kernel.org/r/49a723e0f23e06a6045f8f9e0d06648a6bc899c7.1750847509.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
This commit is contained in:
@@ -1739,3 +1739,8 @@ bool intel_bw_can_enable_sagv(struct intel_display *display,
|
||||
|
||||
return bw_state->pipe_sagv_reject == 0;
|
||||
}
|
||||
|
||||
int intel_bw_qgv_point_peakbw(const struct intel_bw_state *bw_state)
|
||||
{
|
||||
return bw_state->qgv_point_peakbw;
|
||||
}
|
||||
|
||||
@@ -79,5 +79,6 @@ bool intel_bw_can_enable_sagv(struct intel_display *display,
|
||||
const struct intel_bw_state *bw_state);
|
||||
void icl_sagv_pre_plane_update(struct intel_atomic_state *state);
|
||||
void icl_sagv_post_plane_update(struct intel_atomic_state *state);
|
||||
int intel_bw_qgv_point_peakbw(const struct intel_bw_state *bw_state);
|
||||
|
||||
#endif /* __INTEL_BW_H__ */
|
||||
|
||||
@@ -346,7 +346,7 @@ int intel_pmdemand_atomic_check(struct intel_atomic_state *state)
|
||||
|
||||
/* firmware will calculate the qclk_gv_index, requirement is set to 0 */
|
||||
new_pmdemand_state->params.qclk_gv_index = 0;
|
||||
new_pmdemand_state->params.qclk_gv_bw = new_bw_state->qgv_point_peakbw;
|
||||
new_pmdemand_state->params.qclk_gv_bw = intel_bw_qgv_point_peakbw(new_bw_state);
|
||||
|
||||
new_dbuf_state = intel_atomic_get_dbuf_state(state);
|
||||
if (IS_ERR(new_dbuf_state))
|
||||
|
||||
Reference in New Issue
Block a user