[Mesa-dev] [RFC 07/12] i965: Add intel_screen::has_fence_fd

Chad Versace chadversary at chromium.org
Mon Oct 10 17:43:54 UTC 2016


From: Chad Versace <chad.versace at intel.com>

This bool maps to I915_PARAM_HAS_EXEC_FENCE_FD.

TODO: The i915 param is not yet upstream.  Wait for the kernel interface
  before committing.
---
 src/mesa/drivers/dri/i965/intel_screen.c | 3 +++
 src/mesa/drivers/dri/i965/intel_screen.h | 2 +-
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/drivers/dri/i965/intel_screen.c
index 9b23bac..e12c7bd 100644
--- a/src/mesa/drivers/dri/i965/intel_screen.c
+++ b/src/mesa/drivers/dri/i965/intel_screen.c
@@ -1698,6 +1698,9 @@ __DRIconfig **intelInitScreen2(__DRIscreen *dri_screen)
         intel_get_boolean(screen, I915_PARAM_HAS_RESOURCE_STREAMER);
    }
 
+   screen->has_exec_fence =
+     intel_get_boolean(screen, I915_PARAM_HAS_EXEC_FENCE);
+
    return (const __DRIconfig**) intel_screen_make_configs(dri_screen);
 }
 
diff --git a/src/mesa/drivers/dri/i965/intel_screen.h b/src/mesa/drivers/dri/i965/intel_screen.h
index 51c1d4e..bf4cd41 100644
--- a/src/mesa/drivers/dri/i965/intel_screen.h
+++ b/src/mesa/drivers/dri/i965/intel_screen.h
@@ -47,8 +47,8 @@ struct intel_screen
    uint64_t max_gtt_map_object_size;
 
    bool no_hw;
-
    bool hw_has_swizzling;
+   bool has_exec_fence; /**< I915_PARAM_HAS_EXEC_FENCE */
 
    int hw_has_timestamp;
 
-- 
2.10.0



More information about the mesa-dev mailing list