diff options
author | Emil Velikov <emil.veliikov@collabora.com> | 2016-08-25 11:08:30 +0100 |
---|---|---|
committer | Emil Velikov <emil.l.velikov@gmail.com> | 2016-10-14 12:53:35 +0100 |
commit | 9caacb39b9f27919a7c986ad0c5d671a81b1f1e0 (patch) | |
tree | e4450a7f3fcd470353351d67512d74094f036a18 | |
parent | fdd373acca4a17093d7973c210174c1a12dd7da1 (diff) |
loader/dri3: constify the loader_dri3_vtable
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
-rw-r--r-- | src/egl/drivers/dri2/platform_x11_dri3.c | 2 | ||||
-rw-r--r-- | src/glx/dri3_glx.c | 2 | ||||
-rw-r--r-- | src/loader/loader_dri3_helper.c | 2 | ||||
-rw-r--r-- | src/loader/loader_dri3_helper.h | 4 |
4 files changed, 5 insertions, 5 deletions
diff --git a/src/egl/drivers/dri2/platform_x11_dri3.c b/src/egl/drivers/dri2/platform_x11_dri3.c index 26bb4301150..3dc9b98a909 100644 --- a/src/egl/drivers/dri2/platform_x11_dri3.c +++ b/src/egl/drivers/dri2/platform_x11_dri3.c @@ -123,7 +123,7 @@ egl_dri3_flush_drawable(struct loader_dri3_drawable *draw, unsigned flags) dri2_flush_drawable_for_swapbuffers(disp, &dri3_surf->base); } -static struct loader_dri3_vtable egl_dri3_vtable = { +static const struct loader_dri3_vtable egl_dri3_vtable = { .get_swap_interval = egl_dri3_get_swap_interval, .clamp_swap_interval = egl_dri3_clamp_swap_interval, .set_swap_interval = egl_dri3_set_swap_interval, diff --git a/src/glx/dri3_glx.c b/src/glx/dri3_glx.c index 51b6b1cdfa6..db010071719 100644 --- a/src/glx/dri3_glx.c +++ b/src/glx/dri3_glx.c @@ -172,7 +172,7 @@ glx_dri3_show_fps(struct loader_dri3_drawable *draw, uint64_t current_ust) } } -static struct loader_dri3_vtable glx_dri3_vtable = { +static const struct loader_dri3_vtable glx_dri3_vtable = { .get_swap_interval = glx_dri3_get_swap_interval, .clamp_swap_interval = glx_dri3_clamp_swap_interval, .set_swap_interval = glx_dri3_set_swap_interval, diff --git a/src/loader/loader_dri3_helper.c b/src/loader/loader_dri3_helper.c index 817929740f2..ca02e97c9e9 100644 --- a/src/loader/loader_dri3_helper.c +++ b/src/loader/loader_dri3_helper.c @@ -130,7 +130,7 @@ loader_dri3_drawable_init(xcb_connection_t *conn, bool is_different_gpu, const __DRIconfig *dri_config, struct loader_dri3_extensions *ext, - struct loader_dri3_vtable *vtable, + const struct loader_dri3_vtable *vtable, struct loader_dri3_drawable *draw) { xcb_get_geometry_cookie_t cookie; diff --git a/src/loader/loader_dri3_helper.h b/src/loader/loader_dri3_helper.h index 658e190a3d7..1d1f15ebb9a 100644 --- a/src/loader/loader_dri3_helper.h +++ b/src/loader/loader_dri3_helper.h @@ -159,7 +159,7 @@ struct loader_dri3_drawable { bool first_init; struct loader_dri3_extensions *ext; - struct loader_dri3_vtable *vtable; + const struct loader_dri3_vtable *vtable; }; void @@ -176,7 +176,7 @@ loader_dri3_drawable_init(xcb_connection_t *conn, bool is_different_gpu, const __DRIconfig *dri_config, struct loader_dri3_extensions *ext, - struct loader_dri3_vtable *vtable, + const struct loader_dri3_vtable *vtable, struct loader_dri3_drawable*); bool loader_dri3_wait_for_msc(struct loader_dri3_drawable *draw, |