[Mesa-dev] [PATCH 26/30] egl/dri2: annotate dri2_extension_match instances as const data
Emil Velikov
emil.l.velikov at gmail.com
Thu Aug 25 16:18:48 UTC 2016
From: Emil Velikov <emil.velikov at collabora.com>
Signed-off-by: Emil Velikov <emil.velikov at collabora.com>
---
src/egl/drivers/dri2/egl_dri2.c | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/src/egl/drivers/dri2/egl_dri2.c b/src/egl/drivers/dri2/egl_dri2.c
index 6edee68..3ec2c53 100644
--- a/src/egl/drivers/dri2/egl_dri2.c
+++ b/src/egl/drivers/dri2/egl_dri2.c
@@ -357,37 +357,37 @@ struct dri2_extension_match {
bool optional;
};
-static struct dri2_extension_match dri3_driver_extensions[] = {
+static const struct dri2_extension_match dri3_driver_extensions[] = {
{ __DRI_CORE, 1, offsetof(struct dri2_egl_display, core) },
{ __DRI_IMAGE_DRIVER, 1, offsetof(struct dri2_egl_display, image_driver) },
{ NULL, 0, 0 }
};
-static struct dri2_extension_match dri2_driver_extensions[] = {
+static const struct dri2_extension_match dri2_driver_extensions[] = {
{ __DRI_CORE, 1, offsetof(struct dri2_egl_display, core) },
{ __DRI_DRI2, 2, offsetof(struct dri2_egl_display, dri2) },
{ NULL, 0, 0 }
};
-static struct dri2_extension_match dri2_core_extensions[] = {
+static const struct dri2_extension_match dri2_core_extensions[] = {
{ __DRI2_FLUSH, 1, offsetof(struct dri2_egl_display, flush) },
{ __DRI_TEX_BUFFER, 2, offsetof(struct dri2_egl_display, tex_buffer) },
{ __DRI_IMAGE, 1, offsetof(struct dri2_egl_display, image) },
{ NULL, 0, 0 }
};
-static struct dri2_extension_match swrast_driver_extensions[] = {
+static const struct dri2_extension_match swrast_driver_extensions[] = {
{ __DRI_CORE, 1, offsetof(struct dri2_egl_display, core) },
{ __DRI_SWRAST, 2, offsetof(struct dri2_egl_display, swrast) },
{ NULL, 0, 0 }
};
-static struct dri2_extension_match swrast_core_extensions[] = {
+static const struct dri2_extension_match swrast_core_extensions[] = {
{ __DRI_TEX_BUFFER, 2, offsetof(struct dri2_egl_display, tex_buffer) },
{ NULL, 0, 0 }
};
-static struct dri2_extension_match optional_core_extensions[] = {
+static const struct dri2_extension_match optional_core_extensions[] = {
{ __DRI2_ROBUSTNESS, 1, offsetof(struct dri2_egl_display, robustness), true },
{ __DRI2_CONFIG_QUERY, 1, offsetof(struct dri2_egl_display, config), true },
{ __DRI2_FENCE, 1, offsetof(struct dri2_egl_display, fence), true },
@@ -398,7 +398,7 @@ static struct dri2_extension_match optional_core_extensions[] = {
static EGLBoolean
dri2_bind_extensions(struct dri2_egl_display *dri2_dpy,
- struct dri2_extension_match *matches,
+ const struct dri2_extension_match *matches,
const __DRIextension **extensions)
{
int i, j, ret = EGL_TRUE;
--
2.9.0
More information about the mesa-dev
mailing list