Re: [PATCH 3/5] drm/i915: nonblocking commit

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On 14 June 2016 at 00:13, Daniel Vetter <daniel.vetter@xxxxxxxx> wrote:
> +static void intel_atomic_commit_tail(struct drm_atomic_state *state)
>  {
> +       struct drm_device *dev = state->dev;
>         struct intel_atomic_state *intel_state = to_intel_atomic_state(state);
>         struct drm_i915_private *dev_priv = dev->dev_private;
>         struct drm_crtc_state *old_crtc_state;
>         struct drm_crtc *crtc;
>         struct intel_crtc_state *intel_cstate;
> -       int ret = 0, i;
> +       struct drm_plane *plane;
> +       struct drm_plane_state *plane_state;
>         bool hw_check = intel_state->modeset;
>         unsigned long put_domains[I915_MAX_PIPES] = {};
>         unsigned crtc_vblank_mask = 0;
> +       int i, ret;
>
> -       ret = drm_atomic_helper_setup_commit(state, nonblock);
> -       if (ret)
> -               return ret;
> +       for_each_plane_in_state(state, plane, plane_state, i) {
> +               struct intel_plane_state *intel_plane_state =
> +                       to_intel_plane_state(plane_state);

Nope nope nope - as we're now after swap_state, this needs to be
plane->state rather than plane_state.

Renaming the arg to this function to old_state probably would've made
this clearer. It showed up pretty violently when running
Mutter/Wayland though. Changing this lets me run it without seeing
tearing on every draw, and no ill effects seen thus far.

Cheers,
Daniel
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux