]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Report context GTT size
authorChris Wilson <chris@chris-wilson.co.uk>
Wed, 14 Oct 2015 13:17:11 +0000 (14:17 +0100)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Mon, 19 Oct 2015 10:16:46 +0000 (12:16 +0200)
commit6648c4c1970e0a5b9ebc600ca2ab9c550acb0a25
tree574d5262ba138457d11eb7b7c9e83a1d9254ac97
parent235f8d8c34fa3b011194b68b34a263e237f64361
drm/i915: Report context GTT size

Since the beginning we have conflated the size of the global GTT with
that of the per-process context sizes. In recent times (gen8+), those
are no longer the same where the global GTT is limited to 2/4GiB but the
per-process GTT may be anything up to 256TiB. Userspace knows nothing of
this discrepancy and outside of one or two hacks, uses the getaperture
ioctl to determine the maximum size it can use. Let's leave that as
reporting the global GTT and use the context reporting method to
describe the per-process value (which naturally fallsback to reporting
the aliasing or global on older platforms, so userspace can always use
this method where available).

Testcase: igt/gem_userptr_blits/minor-normal-sync
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=90065
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/i915_gem_context.c
include/uapi/drm/i915_drm.h