[Intel-gfx] [PATCH v2] drm/i915 : Restore PWM_GRANULARITY after resume
Jani Nikula
jani.nikula at intel.com
Mon Sep 19 08:41:28 UTC 2016
On Mon, 19 Sep 2016, "Lee, Shawn C" <shawn.c.lee at intel.com> wrote:
> + if (HAS_PCH_LPT(dev_priv)) {
> + mul = I915_READ(SOUTH_CHICKEN2);
> + mul &= ~LPT_PWM_GRANULARITY;
> + I915_WRITE(SOUTH_CHICKEN2, mul | (panel->backlight.pwm_alternate_increment << LPT_PWM_GRANULARITY));
> + } else {
> + mul = I915_READ(SOUTH_CHICKEN1);
> + mul &= ~SPT_PWM_GRANULARITY;
> + I915_WRITE(SOUTH_CHICKEN1, mul | (panel->backlight.pwm_alternate_increment << SPT_PWM_GRANULARITY));
> + }
Also, both of the shifts are wrong here. The *_PWM_GRANULARITY macros
already contain the shifts.
BR,
Jani.
--
Jani Nikula, Intel Open Source Technology Center
More information about the Intel-gfx
mailing list