summaryrefslogtreecommitdiff
path: root/src/gallium/include/frontend/drm_driver.h
blob: f1824128e3aa31eca503e8e435fed2972198c137 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42

#ifndef _DRM_DRIVER_H_
#define _DRM_DRIVER_H_

#include "pipe/p_compiler.h"

#include "winsys_handle.h"

struct pipe_screen;
struct pipe_screen_config;
struct pipe_context;
struct pipe_resource;

struct drm_driver_descriptor
{
   /**
    * Identifying prefix/suffix of the binary, used by the pipe-loader.
    */
   const char *driver_name;

   /**
    * Optional pointer to the array of driOptionDescription describing
    * driver-specific driconf options.
    */
   const struct driOptionDescription *driconf;

   /* Number of entries in the driconf array. */
   unsigned driconf_count;

   /**
    * Create a pipe srcreen.
    *
    * This function does any wrapping of the screen.
    * For example wrapping trace or rbug debugging drivers around it.
    */
   struct pipe_screen* (*create_screen)(int drm_fd,
                                        const struct pipe_screen_config *config);
};

extern const struct drm_driver_descriptor driver_descriptor;

#endif