1. 16 5月, 2014 1 次提交
  2. 13 5月, 2014 2 次提交
    • O
      drm/i915: Ringbuffer signal func for the second BSD ring · d1533379
      Oscar Mateo 提交于
      This is missing in:
      
      commit 78325f2d
      Author: Ben Widawsky <benjamin.widawsky@intel.com>
      Date:   Tue Apr 29 14:52:29 2014 -0700
      
          drm/i915: Virtualize the ringbuffer signal func
      
      Looks to me like a rebase side-effect...
      Signed-off-by: NOscar Mateo <oscar.mateo@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      d1533379
    • B
      drm/i915: Use hash tables for the command parser · 44e895a8
      Brad Volkin 提交于
      For clients that submit large batch buffers the command parser has
      a substantial impact on performance. On my HSW ULT system performance
      drops as much as ~20% on some tests. Most of the time is spent in the
      command lookup code. Converting that from the current naive search to
      a hash table lookup reduces the performance drop to ~10%.
      
      The choice of value for I915_CMD_HASH_ORDER allows all commands
      currently used in the parser tables to hash to their own bucket (except
      for one collision on the render ring). The tradeoff is that it wastes
      memory. Because the opcodes for the commands in the tables are not
      particularly well distributed, reducing the order still leaves many
      buckets empty. The increased collisions don't seem to have a huge
      impact on the performance gain, but for now anyhow, the parser trades
      memory for performance.
      
      NB: Ville noticed that the error paths through the ring init code
      will leak memory. I've not addressed that here. We can do a follow
      up pass to handle all of the leaks.
      
      v2: improved comment describing selection of hash key mask (Damien)
      replace a BUG_ON() with an error return (Tvrtko, Ville)
      commit message improvements
      Signed-off-by: NBrad Volkin <bradley.d.volkin@intel.com>
      Reviewed-by: NDamien Lespiau <damien.lespiau@intel.com>
      Reviewed-by: NTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      44e895a8
  3. 08 5月, 2014 2 次提交
  4. 05 5月, 2014 9 次提交
  5. 25 4月, 2014 1 次提交
  6. 09 4月, 2014 1 次提交
  7. 03 4月, 2014 2 次提交
    • C
      drm/i915: Move all ring resets before setting the HWS page · 9991ae78
      Chris Wilson 提交于
      In commit a51435a3
      Author: Naresh Kumar Kachhi <naresh.kumar.kachhi@intel.com>
      Date:   Wed Mar 12 16:39:40 2014 +0530
      
          drm/i915: disable rings before HW status page setup
      
      we reordered stopping the rings to do so before we set the HWS register.
      However, there is an extra workaround for g45 to reset the rings twice,
      and for consistency we should apply that workaround before setting the
      HWS to be sure that the rings are truly stopped.
      
      Cc: Naresh Kumar Kachhi <naresh.kumar.kachhi@intel.com>
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      9991ae78
    • B
      drm/i915: Invariably invalidate before ctx switch · 057f6a8a
      Ben Widawsky 提交于
      We have been setting the bit which was originally BIOS dependent since:
      commit f05bb0c7
      Author: Chris Wilson <chris@chris-wilson.co.uk>
      Date:   Sun Jan 20 16:33:32 2013 +0000
      
          drm/i915: GFX_MODE Flush TLB Invalidate Mode must be '1' for scanline waits
      
      Therefore, we do not need to try to figure it out dynamically and we can
      just always invalidate the TLBs.
      
      It's a partial revert of:
      commit 12b0286f
      Author: Ben Widawsky <ben@bwidawsk.net>
      Date:   Mon Jun 4 14:42:50 2012 -0700
      
          drm/i915: possibly invalidate TLB before context switch
      
      The original commit attempted to only invalidate when necessary
      (very much a relic from the old days). Now, we can just always invalidate.
      
      I guess the old TODO still exists. Since we seem to have abandoned ILK
      contexts however, there isn't much point in even remembering.
      
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: NBen Widawsky <ben@bwidawsk.net>
      Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      057f6a8a
  8. 02 4月, 2014 2 次提交
  9. 31 3月, 2014 1 次提交
  10. 29 3月, 2014 2 次提交
  11. 13 3月, 2014 1 次提交
  12. 12 3月, 2014 3 次提交
  13. 08 3月, 2014 1 次提交
    • B
      drm/i915: Implement command buffer parsing logic · 351e3db2
      Brad Volkin 提交于
      The command parser scans batch buffers submitted via execbuffer ioctls before
      the driver submits them to hardware. At a high level, it looks for several
      things:
      
      1) Commands which are explicitly defined as privileged or which should only be
         used by the kernel driver. The parser generally rejects such commands, with
         the provision that it may allow some from the drm master process.
      2) Commands which access registers. To support correct/enhanced userspace
         functionality, particularly certain OpenGL extensions, the parser provides a
         whitelist of registers which userspace may safely access (for both normal and
         drm master processes).
      3) Commands which access privileged memory (i.e. GGTT, HWS page, etc). The
         parser always rejects such commands.
      
      See the overview comment in the source for more details.
      
      This patch only implements the logic. Subsequent patches will build the tables
      that drive the parser.
      
      v2: Don't set the secure bit if the parser succeeds
      Fail harder during init
      Makefile cleanup
      Kerneldoc cleanup
      Clarify module param description
      Convert ints to bools in a few places
      Move client/subclient defs to i915_reg.h
      Remove the bits_count field
      
      OTC-Tracker: AXIA-4631
      Change-Id: I50b98c71c6655893291c78a2d1b8954577b37a30
      Signed-off-by: NBrad Volkin <bradley.d.volkin@intel.com>
      Reviewed-by: NJani Nikula <jani.nikula@intel.com>
      [danvet: Appease checkpatch.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      351e3db2
  14. 06 3月, 2014 1 次提交
  15. 14 2月, 2014 5 次提交
  16. 13 2月, 2014 1 次提交
  17. 12 2月, 2014 1 次提交
  18. 07 2月, 2014 1 次提交
    • C
      drm/i915: Prevent recursion by retiring requests when the ring is full · 1f70999f
      Chris Wilson 提交于
      As the VM do not track activity of objects and instead use a large
      hammer to forcibly idle and evict all of their associated objects when
      one is released, it is possible for that to cause a recursion when we
      need to wait for free space on a ring and call retire requests.
      (intel_ring_begin -> intel_ring_wait_request ->
      i915_gem_retire_requests_ring -> i915_gem_context_free ->
      i915_gem_evict_vm -> i915_gpu_idle -> intel_ring_begin etc)
      
      In order to remove the requirement for calling retire-requests from
      intel_ring_wait_request, we have to inline a couple of steps from
      retiring requests, notably we have to record the position of the request
      we wait for and use that to update the available ring space.
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      1f70999f
  19. 22 1月, 2014 1 次提交
  20. 07 1月, 2014 1 次提交
    • C
      drm/i915: Flush outstanding requests before allocating new seqno · 304d695c
      Chris Wilson 提交于
      In very rare cases (such as a memory failure stress test) it is possible
      to fill the entire ring without emitting a request. Under this
      circumstance, the outstanding request is flushed and waited upon. After
      space on the ring is cleared, we return to emitting the new command -
      except that we just cleared the seqno allocated for this operation and
      trigger the sanity check that a request is only ever emitted with a
      valid seqno. The fix is to rearrange the code to make sure the
      allocation of the seqno for this operation is after any required flushes
      of outstanding operations.
      
      The bug exists since the preallocation was introduced in
      commit 9d773091
      Author: Chris Wilson <chris@chris-wilson.co.uk>
      Date:   Tue Nov 27 16:22:52 2012 +0000
      
          drm/i915: Preallocate next seqno before touching the ring
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Mika Kuoppala <mika.kuoppala@intel.com>
      Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
      Cc: stable@vger.kernel.org
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: NJani Nikula <jani.nikula@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      304d695c
  21. 18 12月, 2013 1 次提交