diff options
Diffstat (limited to 'src/gallium/auxiliary/target-helpers/drm_helper.h')
-rw-r--r-- | src/gallium/auxiliary/target-helpers/drm_helper.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/target-helpers/drm_helper.h b/src/gallium/auxiliary/target-helpers/drm_helper.h index 2a2f57d20d..a4fcde385f 100644 --- a/src/gallium/auxiliary/target-helpers/drm_helper.h +++ b/src/gallium/auxiliary/target-helpers/drm_helper.h @@ -4,6 +4,31 @@ #include <stdio.h> #include "target-helpers/inline_debug_helper.h" #include "target-helpers/drm_helper_public.h" +#include "state_tracker/drm_driver.h" + +static const struct drm_conf_ret throttle_ret = { + .type = DRM_CONF_INT, + .val.val_int = 2, +}; + +static const struct drm_conf_ret share_fd_ret = { + .type = DRM_CONF_BOOL, + .val.val_bool = true, +}; + +const struct drm_conf_ret * +pipe_default_configuration_query(enum drm_conf conf) +{ + switch (conf) { + case DRM_CONF_THROTTLE: + return &throttle_ret; + case DRM_CONF_SHARE_FD: + return &share_fd_ret; + default: + break; + } + return NULL; +} #ifdef GALLIUM_I915 #include "i915/drm/i915_drm_public.h" |