diff options
author | 2023-04-17 11:57:42 +0300 | |
---|---|---|
committer | 2023-04-18 09:45:39 +0300 | |
commit | 088248f4b0ee089cb78a318411d23566e3737dd1 (patch) | |
tree | 55c6f780b21a6e27c2b16e496985e9efbbdf16d7 | |
parent | drm/i915/display: add intel_display_driver_early_probe() (diff) | |
download | wireguard-linux-088248f4b0ee089cb78a318411d23566e3737dd1.tar.xz wireguard-linux-088248f4b0ee089cb78a318411d23566e3737dd1.zip |
drm/i915/pps: use intel_de_rmw() for panel unlock
Use rmw where needed.
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Reviewed-by: Andi Shyti <andi.shyti@linux.intel.com>
Reviewed-by: Andrzej Hajda <andrzej.hajda@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20230417085742.793379-1-jani.nikula@intel.com
-rw-r--r-- | drivers/gpu/drm/i915/display/intel_pps.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/drivers/gpu/drm/i915/display/intel_pps.c b/drivers/gpu/drm/i915/display/intel_pps.c index 7f9926672a6a..4f0b0cca03cc 100644 --- a/drivers/gpu/drm/i915/display/intel_pps.c +++ b/drivers/gpu/drm/i915/display/intel_pps.c @@ -1653,12 +1653,9 @@ void intel_pps_unlock_regs_wa(struct drm_i915_private *dev_priv) */ pps_num = intel_num_pps(dev_priv); - for (pps_idx = 0; pps_idx < pps_num; pps_idx++) { - u32 val = intel_de_read(dev_priv, PP_CONTROL(pps_idx)); - - val = (val & ~PANEL_UNLOCK_MASK) | PANEL_UNLOCK_REGS; - intel_de_write(dev_priv, PP_CONTROL(pps_idx), val); - } + for (pps_idx = 0; pps_idx < pps_num; pps_idx++) + intel_de_rmw(dev_priv, PP_CONTROL(pps_idx), + PANEL_UNLOCK_MASK, PANEL_UNLOCK_REGS); } void intel_pps_setup(struct drm_i915_private *i915) |