From 769b10578083aa7bbee0052246d8ea6000435ae8 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Thu, 1 Oct 2009 19:09:26 -0700 Subject: intel: Add a new function to check if a BO's reloc tree references some BO. There are a bunch of places in GL where if we can't do this we have to flush the batchbuffer, and the cost of lookups here is outweighed by flush savings. --- libdrm/intel/intel_bufmgr_priv.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'libdrm/intel/intel_bufmgr_priv.h') diff --git a/libdrm/intel/intel_bufmgr_priv.h b/libdrm/intel/intel_bufmgr_priv.h index af17c12d..454d4574 100644 --- a/libdrm/intel/intel_bufmgr_priv.h +++ b/libdrm/intel/intel_bufmgr_priv.h @@ -207,6 +207,9 @@ struct _drm_intel_bufmgr { */ int (*get_pipe_from_crtc_id)(drm_intel_bufmgr *bufmgr, int crtc_id); + /** Returns true if target_bo is in the relocation tree rooted at bo. */ + int (*bo_references)(drm_intel_bo *bo, drm_intel_bo *target_bo); + int debug; /**< Enables verbose debugging printouts */ }; -- cgit v1.2.3