1. 10 May, 2013 22 commits
  2. 06 May, 2013 12 commits
  3. 03 May, 2013 2 commits
  4. 02 May, 2013 1 commit
  5. 30 Apr, 2013 3 commits
    • Mika Kuoppala's avatar
      drm/i915: reference count for i915_hw_contexts · dce3271b
      Mika Kuoppala authored
      Enabling PPGTT and also the need to track which context was guilty of
      gpu hang (arb robustness enabling) have put pressure for struct i915_hw_context
      to be more than just a placeholder for hw context state.
      
      In order to track object lifetime properly in a multi peer usage, add reference
      counting for i915_hw_context.
      
      v2: track i915_hw_context pointers instead of using ctx_ids
      (from Chris Wilson)
      
      v3 (Ben): Get rid of do_release() and handle refcounting more compactly.
      (recommended by Chis)
      
      v4: kref_* put inside static inlines (Daniel Vetter)
      remove code duplication on freeing context (Chris Wilson)
      
      v5: idr_remove and ctx->file_priv = NULL in destroy ioctl (Chris)
      This actually will cause a problem if one destroys a context and later
      refers to the idea of the context (multiple contexts may have the same
      id, but only 1 will exist in the idr).
      
      v6: Strip out the request related stuff. Reworded commit message.
      Got rid of do_destroy and introduced i915_gem_context_release_handle,
      suggested by Chris Wilson.
      
      v7: idr_remove can't be called inside idr_for_each (Chris Wilson)
      
      Signed-off-by: Ben Widawsky <ben@bwidawsk.net> (v5)
      Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> (v7)
      Reviewed-by: default avatarBen Widawsky <ben@bwidawsk.net>
      Reviewed-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      [danvet: Squash sob lines, the patch ping-ponged between Ben and Mika
      a bit ...]
      Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
      dce3271b
    • Ville Syrjälä's avatar
      drm/i915: Relax the sprite scaling limits checks · 3c3686cd
      Ville Syrjälä authored
      Reduce the size of the the src/dst viewport to keep the scalign ratios
      in check.
      
      v2: Below min size sprite handling squashed to previous patch
      Reviewed-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: default avatarVille Syrjälä <ville.syrjala@linux.intel.com>
      Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
      3c3686cd
    • Ville Syrjälä's avatar
      drm/i915: Implement proper clipping for video sprites · 1731693a
      Ville Syrjälä authored
      Properly clip the source when the destination gets clipped
      by the pipe dimensions.
      
      Sadly the video sprite hardware is rather limited so it can't do proper
      sub-pixel postitioning. Resort to truncating the source coordinates to
      (macro)pixel boundary.
      
      The scaling checks are done using the strict drm_region functions.
      Which means that an error is returned when the min/max scaling
      ratios are exceeded.
      
      Also do some additional checking against various hardware limits.
      
      v2: Truncate src coords instead of rounding to avoid increasing src
          viewport size, and adapt to changes in drm_calc_{h,v}scale().
      v3: Adapt to drm_region->drm_rect rename. Fix misaligned crtc_w for
          packed YUV formats when scaling isn't supported.
      v4: Use stricter scaling checks, use drm_rect_equals()
      v5: If sprite is below min size, make it invisible instead returning
          an error.
          Use WARN_ON() instead if BUG_ON(), and add one to sanity check the
          src viewport size.
      v6: Add comments to remind about src and dst coordinate types
      Reviewed-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: default avatarVille Syrjälä <ville.syrjala@linux.intel.com>
      Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
      1731693a