Skip to content

Commit c188622

Browse files
committed
drm/i915: Record default rps threshold values
Record the default values as preparation for exposing the sysfs controls. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Rodrigo Vivi <rodrigo.vivi@kernel.org> Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com> Reviewed-by: Andi Shyti <andi.shyti@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20230717164013.826614-2-tvrtko.ursulin@linux.intel.com
1 parent c2307b7 commit c188622

2 files changed

Lines changed: 5 additions & 0 deletions

File tree

drivers/gpu/drm/i915/gt/intel_gt_types.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,9 @@ enum intel_submission_method {
8383
struct gt_defaults {
8484
u32 min_freq;
8585
u32 max_freq;
86+
87+
u8 rps_up_threshold;
88+
u8 rps_down_threshold;
8689
};
8790

8891
enum intel_gt_type {

drivers/gpu/drm/i915/gt/intel_rps.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2014,7 +2014,9 @@ void intel_rps_init(struct intel_rps *rps)
20142014

20152015
/* Set default thresholds in % */
20162016
rps->power.up_threshold = 95;
2017+
rps_to_gt(rps)->defaults.rps_up_threshold = rps->power.up_threshold;
20172018
rps->power.down_threshold = 85;
2019+
rps_to_gt(rps)->defaults.rps_down_threshold = rps->power.down_threshold;
20182020

20192021
/* Finally allow us to boost to max by default */
20202022
rps->boost_freq = rps->max_freq;

0 commit comments

Comments
 (0)