1. 27 12月, 2016 1 次提交
  2. 16 12月, 2016 2 次提交
  3. 28 11月, 2016 1 次提交
  4. 24 11月, 2016 1 次提交
  5. 08 11月, 2016 1 次提交
  6. 08 8月, 2016 1 次提交
  7. 25 11月, 2015 1 次提交
  8. 24 11月, 2015 1 次提交
  9. 05 3月, 2015 1 次提交
  10. 04 4月, 2014 1 次提交
    • L
      drm: Add support for two-ended allocation, v3 · 62347f9e
      Lauri Kasanen 提交于
      Clients like i915 need to segregate cache domains within the GTT which
      can lead to small amounts of fragmentation. By allocating the uncached
      buffers from the bottom and the cacheable buffers from the top, we can
      reduce the amount of wasted space and also optimize allocation of the
      mappable portion of the GTT to only those buffers that require CPU
      access through the GTT.
      
      For other drivers, allocating small bos from one end and large ones
      from the other helps improve the quality of fragmentation.
      
      Based on drm_mm work by Chris Wilson.
      
      v3: Changed to use a TTM placement flag
      v2: Updated kerneldoc
      
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Cc: Ben Widawsky <ben@bwidawsk.net>
      Cc: Christian König <deathsimple@vodafone.de>
      Signed-off-by: NLauri Kasanen <cand@gmx.com>
      Signed-off-by: NDavid Airlie <airlied@redhat.com>
      62347f9e
  11. 13 3月, 2014 1 次提交
  12. 07 8月, 2013 2 次提交
    • D
      drm/mm: remove unused API · c700c67b
      David Herrmann 提交于
      We used to pre-allocate drm_mm nodes and save them in a linked list for
      later usage so we always have spare ones in atomic contexts. However, this
      is really racy if multiple threads are in an atomic context at the same
      time and we don't have enough spare nodes. Moreover, all remaining users
      run in user-context and just lock drm_mm with a spinlock. So we can easily
      preallocate the node, take the spinlock and insert the node.
      
      This may have worked well with BKL in place, however, with today's
      infrastructure it really doesn't make any sense. Besides, most users can
      easily embed drm_mm_node into their objects so no allocation is needed at
      all.
      
      Thus, remove the old pre-alloc API and all the helpers that it provides.
      Drivers have already been converted and we should not use the old API for
      new code, anymore.
      Signed-off-by: NDavid Herrmann <dh.herrmann@gmail.com>
      Acked-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      c700c67b
    • D
      drm/mm: add "best_match" flag to drm_mm_insert_node() · 31e5d7c6
      David Herrmann 提交于
      Add a "best_match" flag similar to the drm_mm_search_*() helpers so we
      can convert TTM to use them in follow up patches. We can also inline the
      non-generic helpers and move them into the header to allow compile-time
      optimizations.
      
      To make calls to drm_mm_{search,insert}_node() more readable, this
      converts the boolean argument to a flagset. There are pending patches that
      add additional flags for top-down allocators and more.
      
      v2:
       - use flag parameter instead of boolean "best_match"
       - convert *_search_free() helpers to also use flags argument
      Signed-off-by: NDavid Herrmann <dh.herrmann@gmail.com>
      Reviewed-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      31e5d7c6
  13. 01 8月, 2013 1 次提交
    • D
      drm/mm: include required headers in drm_mm.h · 86e81f0e
      David Herrmann 提交于
      We need BUG_ON(), spinlock_t and standard kernel data-types so include the
      right headers.
      
      Subject: [drm-intel:drm-intel-nightly 154/166] include/drm/drm_mm.h:67:2:
       error: unknown type name 'spinlock_t'
      Message-ID: <51f14693.g5HGdcuw2v3m8FOd%fengguang.wu@intel.com>
      
      In case it didn't link to it correctly. Somehow this bug doesn't occur
      here on my machine, hmm. But I think fixing drm_mm.h is better than
      changing the include-order in drm_vma_manager.h, so this is what I
      did.
      Signed-off-by: NDavid Herrmann <dh.herrmann@gmail.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      86e81f0e
  14. 09 7月, 2013 2 次提交
    • B
      drm: Change create block to reserve node · 338710e7
      Ben Widawsky 提交于
      With the previous patch we no longer actually create a node, we simply
      find the correct hole and occupy it. This very well could have been
      squashed with the last patch, but since I already had David's review, I
      figured it's easiest to keep it distinct.
      
      Also update the users in i915. Conveniently this is the only user of the
      interface.
      
      CC: David Airlie <airlied@linux.ie>
      CC: <dri-devel@lists.freedesktop.org>
      Signed-off-by: NBen Widawsky <ben@bwidawsk.net>
      Acked-by: NDavid Airlie <airlied@linux.ie>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      338710e7
    • B
      drm: pre allocate node for create_block · b3a070cc
      Ben Widawsky 提交于
      For an upcoming patch where we introduce the i915 VMA, it's ideal to
      have the drm_mm_node as part of the VMA struct (ie. it's pre-allocated).
      Part of the conversion to VMAs is to kill off obj->gtt_space. Doing this
      will break a bunch of code, but amongst them are 2 callers of
      drm_mm_create_block(), both related to stolen memory.
      
      It also allows us to embed the drm_mm_node into the object currently
      which provides a nice transition over to the new code.
      
      v2: Reordered to do before ripping out obj->gtt_offset.
      Some minor cleanups made available because of reordering.
      
      v3: s/continue/break on failed stolen node allocation (David)
      Set obj->gtt_space on failed node allocation (David)
      Only unref stolen (fix double free) on failed create_stolen (David)
      Free node, and NULL it in failed create_stolen (David)
      Add back accidentally removed newline (David)
      
      CC: <dri-devel@lists.freedesktop.org>
      Reviewed-by: NDavid Herrmann <dh.herrmann@gmail.com>
      Signed-off-by: NBen Widawsky <ben@bwidawsk.net>
      Acked-by: NDavid Airlie <airlied@linux.ie>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      b3a070cc
  15. 04 7月, 2013 1 次提交
  16. 02 7月, 2013 1 次提交
  17. 08 1月, 2013 1 次提交
    • C
      drm: Only evict the blocks required to create the requested hole · 901593f2
      Chris Wilson 提交于
      Avoid clobbering adjacent blocks if they happen to expire earlier and
      amalgamate together to form the requested hole.
      
      In passing this fixes a regression from
      commit ea7b1dd4
      Author: Daniel Vetter <daniel.vetter@ffwll.ch>
      Date:   Fri Feb 18 17:59:12 2011 +0100
      
          drm: mm: track free areas implicitly
      
      which swaps the end address for size (with a potential overflow) and
      effectively causes the eviction code to clobber almost all earlier
      buffers above the evictee.
      
      v2: Check the original hole not the adjusted as the coloring may confuse
      us when later searching for the overlapping nodes. Also make sure that
      we do apply the range restriction and color adjustment in the same
      order for both scanning, searching and insertion.
      
      v3: Send the version that was actually tested.
      
      Note that this seems to be ducttape of decent quality ot paper over
      some of our unbind related gpu hangs reported since 3.7. It is not
      fully effective though, and certainly doesn't fix the underlying bug.
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
      [danvet: Added note plus bugzilla link and tested-by.]
      Cc: stable@vger.kernel.org
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=55984Tested-by: NNorbert Preining <preining@logic.at>
      Acked-by: Dave Airlie <airlied@gmail.com
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      901593f2
  18. 19 12月, 2012 1 次提交
  19. 01 12月, 2012 2 次提交
  20. 16 7月, 2012 1 次提交
    • C
      drm: Add colouring to the range allocator · 6b9d89b4
      Chris Wilson 提交于
      In order to support snoopable memory on non-LLC architectures (so that
      we can bind vgem objects into the i915 GATT for example), we have to
      avoid the prefetcher on the GPU from crossing memory domains and so
      prevent allocation of a snoopable PTE immediately following an uncached
      PTE. To do that, we need to extend the range allocator with support for
      tracking and segregating different node colours.
      
      This will be used by i915 to segregate memory domains within the GTT.
      
      v2: Now with more drm_mm helpers and less driver interference.
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Dave Airlie <airlied@redhat.com
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Ben Skeggs <bskeggs@redhat.com>
      Cc: Jerome Glisse <jglisse@redhat.com>
      Cc: Alex Deucher <alexander.deucher@amd.com>
      Reviewed-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Signed-off-by: NDave Airlie <airlied@gmail.com>
      6b9d89b4
  21. 09 5月, 2011 1 次提交
  22. 31 3月, 2011 1 次提交
  23. 23 2月, 2011 4 次提交
  24. 28 10月, 2010 1 次提交
  25. 07 7月, 2010 3 次提交
  26. 10 12月, 2009 2 次提交
  27. 08 9月, 2009 1 次提交
  28. 02 9月, 2009 1 次提交
  29. 19 6月, 2009 1 次提交
  30. 12 6月, 2009 1 次提交