aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/gallium/winsys/sw/kms-dri/kms_dri_sw_winsys.c2
-rw-r--r--src/gbm/backends/dri/gbm_dri.c1
2 files changed, 2 insertions, 1 deletions
diff --git a/src/gallium/winsys/sw/kms-dri/kms_dri_sw_winsys.c b/src/gallium/winsys/sw/kms-dri/kms_dri_sw_winsys.c
index 49b2e6596ac..ed34dfa6cbc 100644
--- a/src/gallium/winsys/sw/kms-dri/kms_dri_sw_winsys.c
+++ b/src/gallium/winsys/sw/kms-dri/kms_dri_sw_winsys.c
@@ -131,10 +131,10 @@ kms_sw_displaytarget_create(struct sw_winsys *ws,
kms_sw_dt->width = width;
kms_sw_dt->height = height;
+ memset(&create_req, 0, sizeof(create_req));
create_req.bpp = 32;
create_req.width = width;
create_req.height = height;
- create_req.handle = 0;
ret = drmIoctl(kms_sw->fd, DRM_IOCTL_MODE_CREATE_DUMB, &create_req);
if (ret)
goto free_bo;
diff --git a/src/gbm/backends/dri/gbm_dri.c b/src/gbm/backends/dri/gbm_dri.c
index 066426617ba..39e6b30d473 100644
--- a/src/gbm/backends/dri/gbm_dri.c
+++ b/src/gbm/backends/dri/gbm_dri.c
@@ -774,6 +774,7 @@ create_dumb(struct gbm_device *gbm,
if (bo == NULL)
return NULL;
+ memset(&create_arg, 0, sizeof(create_arg));
create_arg.bpp = 32;
create_arg.width = width;
create_arg.height = height;