diff options
author | Marek Olšák <[email protected]> | 2019-04-22 20:00:10 -0400 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2019-04-23 21:20:26 -0400 |
commit | d8b296d3ad96cb04ee57234a0b1a6a046e08a1a7 (patch) | |
tree | 70c9d4183d333f6b17f616b8e638b2eb8c572bcd /src/gallium/include | |
parent | 8ae50e6004e6279493d7ea771f540cc871a90149 (diff) |
gallium: replace drm_driver_descriptor::configuration with driconf_xml
PIPE_CAPs are better.
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/gallium/include')
-rw-r--r-- | src/gallium/include/state_tracker/drm_driver.h | 45 |
1 files changed, 8 insertions, 37 deletions
diff --git a/src/gallium/include/state_tracker/drm_driver.h b/src/gallium/include/state_tracker/drm_driver.h index 3f52f1be885..f8d77a79721 100644 --- a/src/gallium/include/state_tracker/drm_driver.h +++ b/src/gallium/include/state_tracker/drm_driver.h @@ -11,32 +11,6 @@ struct pipe_screen_config; struct pipe_context; struct pipe_resource; -/** - * Configuration queries. - */ -enum drm_conf { - /* XML string describing the available config options. */ - DRM_CONF_XML_OPTIONS, /* DRM_CONF_POINTER */ - DRM_CONF_MAX -}; - -/** - * Type of configuration answer - */ -enum drm_conf_type { - DRM_CONF_POINTER -}; - -/** - * Return value from the configuration function. - */ -struct drm_conf_ret { - enum drm_conf_type type; - union { - void *val_pointer; - } val; -}; - struct drm_driver_descriptor { /** @@ -45,6 +19,12 @@ struct drm_driver_descriptor const char *driver_name; /** + * Pointer to the XML string describing driver-specific driconf options. + * Use DRI_CONF_* macros to create the string. + */ + const char **driconf_xml; + + /** * Create a pipe srcreen. * * This function does any wrapping of the screen. @@ -52,15 +32,6 @@ struct drm_driver_descriptor */ struct pipe_screen* (*create_screen)(int drm_fd, const struct pipe_screen_config *config); - - /** - * Return a configuration value. - * - * If this function is NULL, or if it returns NULL - * the state tracker- or state - * tracker manager should provide a reasonable default value. - */ - const struct drm_conf_ret *(*configuration) (enum drm_conf conf); }; extern const struct drm_driver_descriptor driver_descriptor; @@ -68,11 +39,11 @@ extern const struct drm_driver_descriptor driver_descriptor; /** * Instantiate a drm_driver_descriptor struct. */ -#define DRM_DRIVER_DESCRIPTOR(driver_name_str, func, conf) \ +#define DRM_DRIVER_DESCRIPTOR(driver_name_str, driconf, func) \ const struct drm_driver_descriptor driver_descriptor = { \ .driver_name = driver_name_str, \ + .driconf_xml = driconf, \ .create_screen = func, \ - .configuration = (conf), \ }; #endif |