From 5b5ce301287fb8ef74b45fad3c10b2d4ac3a9cc6 Mon Sep 17 00:00:00 2001 From: Keith Packard Date: Mon, 11 May 2009 13:42:12 -0700 Subject: libdrm/intel: add drm_intel_bo_disable_reuse api Scanout buffers need to be freed through the kernel as it holds a reference to them; exposing this API allows applications allocating scanout buffers to flag them as not reusable. Signed-off-by: Keith Packard Reviewed-by: Eric Anholt --- libdrm/intel/intel_bufmgr.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'libdrm/intel/intel_bufmgr.c') diff --git a/libdrm/intel/intel_bufmgr.c b/libdrm/intel/intel_bufmgr.c index 25a6828c..5057fe69 100644 --- a/libdrm/intel/intel_bufmgr.c +++ b/libdrm/intel/intel_bufmgr.c @@ -212,3 +212,10 @@ int drm_intel_bo_get_tiling(drm_intel_bo *bo, uint32_t *tiling_mode, *swizzle_mode = I915_BIT_6_SWIZZLE_NONE; return 0; } + +int drm_intel_bo_disable_reuse(drm_intel_bo *bo) +{ + if (bo->bufmgr->bo_disable_reuse) + return bo->bufmgr->bo_disable_reuse(bo); + return 0; +} -- cgit v1.2.3