diff options
author | Hoegeun Kwon <hoegeun.kwon@samsung.com> | 2017-04-18 14:17:15 +0900 |
---|---|---|
committer | Hoegeun Kwon <hoegeun.kwon@samsung.com> | 2017-04-18 14:20:56 +0900 |
commit | 2380ed1c9a31bde6015219091cbb5463a44ba215 (patch) | |
tree | 861a511973a8f80f45d5610fdeccc155cf36f5ce | |
parent | 1010a2b8163d7d495a343c0acd52cc1ede837ae6 (diff) | |
download | libdrm-2380ed1c9a31bde6015219091cbb5463a44ba215.tar.gz libdrm-2380ed1c9a31bde6015219091cbb5463a44ba215.tar.bz2 libdrm-2380ed1c9a31bde6015219091cbb5463a44ba215.zip |
ipptest: Remove strerror()tizen_4.0.m1_releasesubmit/tizen/20170418.065107accepted/tizen/unified/20170419.054145
To remove warning of static analysis tool, this removes strerror().
Change-Id: I132cf0271ac9a1641c1c88611aca5c3f311240a7
Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
-rw-r--r-- | tests/ipptest/fimc.c | 45 | ||||
-rw-r--r-- | tests/ipptest/fimctest.c | 31 | ||||
-rw-r--r-- | tests/ipptest/gem.c | 18 | ||||
-rw-r--r-- | tests/ipptest/util.c | 9 | ||||
-rw-r--r-- | tests/rottest/gem.c | 11 | ||||
-rw-r--r-- | tests/rottest/rotator.c | 34 | ||||
-rw-r--r-- | tests/rottest/rottest.c | 27 | ||||
-rw-r--r-- | tests/rottest/util.c | 4 |
8 files changed, 81 insertions, 98 deletions
diff --git a/tests/ipptest/fimc.c b/tests/ipptest/fimc.c index c18986d9..037b5202 100644 --- a/tests/ipptest/fimc.c +++ b/tests/ipptest/fimc.c @@ -108,8 +108,7 @@ struct resources *get_resources(struct device *dev) res->res = drmModeGetResources(dev->fd); if (!res->res) { - fprintf(stderr, "drmModeGetResources failed: %s\n", - strerror(errno)); + fprintf(stderr, "drmModeGetResources failed: %d\n", errno); goto error; } @@ -133,9 +132,9 @@ struct resources *get_resources(struct device *dev) (_res)->type##s[i].type = \ drmModeGet##Type(dev->fd, (_res)->__res->type##s[i]); \ if (!(_res)->type##s[i].type) \ - fprintf(stderr, "could not get %s %i: %s\n", \ + fprintf(stderr, "could not get %s %i: %d\n", \ #type, (_res)->__res->type##s[i], \ - strerror(errno)); \ + errno); \ } \ } while (0) @@ -155,9 +154,9 @@ struct resources *get_resources(struct device *dev) DRM_MODE_OBJECT_##Type); \ if (!obj->props) { \ fprintf(stderr, \ - "could not get %s %i properties: %s\n", \ + "could not get %s %i properties: %d\n", \ #type, obj->type->type##_id, \ - strerror(errno)); \ + errno); \ continue; \ } \ obj->props_info = malloc(obj->props->count_props * \ @@ -185,9 +184,9 @@ struct resources *get_resources(struct device *dev) DRM_MODE_OBJECT_CONNECTOR); if (!obj->props) { - fprintf(stderr, "could not get %s %u properties: %s\n", + fprintf(stderr, "could not get %s %u properties: %d\n", "drm_connector", obj->connector->connector_id, - strerror(errno)); + errno); continue; } @@ -208,8 +207,7 @@ struct resources *get_resources(struct device *dev) res->plane_res = drmModeGetPlaneResources(dev->fd); if (!res->plane_res) { - fprintf(stderr, "drmModeGetPlaneResources failed: %s\n", - strerror(errno)); + fprintf(stderr, "drmModeGetPlaneResources failed: %d\n", errno); return res; } @@ -507,8 +505,8 @@ static int exynos_drm_ipp_set_property(int fd, ret = ioctl(fd, DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY, property); if (ret) fprintf(stderr, - "failed to DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY : %s\n", - strerror(errno)); + "failed to DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY : %d\n", + errno); printf("DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY : prop_id[%d]\n", property->prop_id); @@ -541,8 +539,8 @@ static int exynos_drm_ipp_queue_buf(int fd, struct drm_exynos_ipp_queue_buf *qbu ret = ioctl(fd, DRM_IOCTL_EXYNOS_IPP_QUEUE_BUF, qbuf); if (ret) fprintf(stderr, - "failed to DRM_IOCTL_EXYNOS_IPP_QUEUE_BUF[id:%d][buf_type:%d] : %s\n", - ops_id, buf_type, strerror(errno)); + "failed to DRM_IOCTL_EXYNOS_IPP_QUEUE_BUF[id:%d][buf_type:%d] : %d\n", + ops_id, buf_type, errno); return ret; } @@ -561,8 +559,8 @@ static int exynos_drm_ipp_cmd_ctrl(int fd, struct drm_exynos_ipp_cmd_ctrl *cmd_c ret = ioctl(fd, DRM_IOCTL_EXYNOS_IPP_CMD_CTRL, cmd_ctrl); if (ret) fprintf(stderr, - "failed to DRM_IOCTL_EXYNOS_IPP_CMD_CTRL[prop_id:%d][ctrl:%d] : %s\n", - prop_id, ctrl, strerror(errno)); + "failed to DRM_IOCTL_EXYNOS_IPP_CMD_CTRL[prop_id:%d][ctrl:%d] : %d\n", + prop_id, ctrl, errno); return ret; } @@ -833,9 +831,9 @@ void fimc_m2m_set_mode(struct device *dev, struct connector *c, int count, pipe.fourcc, handles, pitches, offsets, &fb_id_dst, 0); if (ret) { - fprintf(stderr, "failed to add fb (%ux%u):%s\n", + fprintf(stderr, "failed to add fb (%ux%u):%d\n", dev->mode.width, dev->mode.height, - strerror(errno)); + errno); goto err_ipp_quque_close; } @@ -844,8 +842,7 @@ void fimc_m2m_set_mode(struct device *dev, struct connector *c, int count, fb_id_dst, 0, 0, pipe.con_ids, pipe.num_cons, pipe.mode); if (ret) { - fprintf(stderr, "failed to set crtc: %s\n", - strerror(errno)); + fprintf(stderr, "failed to set crtc: %d\n", errno); goto err_ipp_quque_close; } @@ -870,8 +867,8 @@ void fimc_m2m_set_mode(struct device *dev, struct connector *c, int count, fb_id_dst, DRM_MODE_PAGE_FLIP_EVENT, &pipe); if (ret) { - fprintf(stderr, "failed to page flip: %s\n", - strerror(errno)); + fprintf(stderr, "failed to page flip: %d\n", + errno); goto err_ipp_quque_close; } @@ -999,8 +996,8 @@ void fimc_wb_set_mode(struct connector *c, int count, int page_flip, for (i = 0; i < MAX_BUF; i++) { ret = util_gem_create_mmap(fd, &gem[i], &mmap[i], stride * height); if (ret) { - fprintf(stderr, "failed to gem create mmap: %s\n", - strerror(errno)); + fprintf(stderr, "failed to gem create mmap: %d\n", + errno); if (ret == -1) return; else if (ret == -2) goto err_ipp_ctrl_close; } diff --git a/tests/ipptest/fimctest.c b/tests/ipptest/fimctest.c index 196f3c4b..09c8b676 100644 --- a/tests/ipptest/fimctest.c +++ b/tests/ipptest/fimctest.c @@ -123,8 +123,8 @@ static void dump_encoders(void) encoder = drmModeGetEncoder(fd, resources->encoders[i]); if (!encoder) { - fprintf(stderr, "could not get encoder %i: %s\n", - resources->encoders[i], strerror(errno)); + fprintf(stderr, "could not get encoder %i: %d\n", + resources->encoders[i], errno); continue; } printf("%d\t%d\t%s\t0x%08x\t0x%08x\n", @@ -179,8 +179,8 @@ static void dump_connectors(void) connector = drmModeGetConnector(fd, resources->connectors[i]); if (!connector) { - fprintf(stderr, "could not get connector %i: %s\n", - resources->connectors[i], strerror(errno)); + fprintf(stderr, "could not get connector %i: %d\n", + resources->connectors[i], errno); continue; } @@ -225,8 +225,8 @@ static void dump_crtcs(void) crtc = drmModeGetCrtc(fd, resources->crtcs[i]); if (!crtc) { - fprintf(stderr, "could not get crtc %i: %s\n", - resources->crtcs[i], strerror(errno)); + fprintf(stderr, "could not get crtc %i: %d\n", + resources->crtcs[i], errno); continue; } printf("%d\t%d\t(%d,%d)\t(%dx%d)\n", @@ -252,8 +252,8 @@ static void dump_framebuffers(void) fb = drmModeGetFB(fd, resources->fbs[i]); if (!fb) { - fprintf(stderr, "could not get fb %i: %s\n", - resources->fbs[i], strerror(errno)); + fprintf(stderr, "could not get fb %i: %d\n", + resources->fbs[i], errno); continue; } printf("%u\t(%ux%u)\t%u\n", @@ -288,8 +288,8 @@ void connector_find_mode(struct connector *c) connector = drmModeGetConnector(fd, resources->connectors[i]); if (!connector) { - fprintf(stderr, "could not get connector %i: %s\n", - resources->connectors[i], strerror(errno)); + fprintf(stderr, "could not get connector %i: %d\n", + resources->connectors[i], errno); continue; } @@ -337,8 +337,8 @@ void connector_find_mode(struct connector *c) encoder = drmModeGetEncoder(fd, resources->encoders[i]); if (!encoder) { - fprintf(stderr, "could not get encoder %i: %s\n", - resources->encoders[i], strerror(errno)); + fprintf(stderr, "could not get encoder %i: %d\n", + resources->encoders[i], errno); continue; } @@ -456,8 +456,7 @@ int main(int argc, char **argv) dev.resources = get_resources(&dev); if (!dev.resources) { - fprintf(stderr, "get_resources failed: %s\n", - strerror(errno)); + fprintf(stderr, "get_resources failed: %d\n", errno); drmClose(dev.fd); return 1; } @@ -483,8 +482,8 @@ int main(int argc, char **argv) ret = kms_create(dev.fd, &dev.kms); if (ret) { fprintf(stderr, - "failed to create kms driver: %s\n", - strerror(-ret)); + "failed to create kms driver: %d\n", + ret); break; } diff --git a/tests/ipptest/gem.c b/tests/ipptest/gem.c index a60bc250..ea7426c1 100644 --- a/tests/ipptest/gem.c +++ b/tests/ipptest/gem.c @@ -54,8 +54,8 @@ int exynos_gem_create(int fd, struct drm_exynos_gem_create *gem) } ret = ioctl(fd, DRM_IOCTL_EXYNOS_GEM_CREATE, gem); if (ret < 0) - fprintf(stderr, "failed to create gem buffer: %s\n", - strerror(-ret)); + fprintf(stderr, "failed to create gem buffer: %d\n", ret); + return ret; } @@ -70,8 +70,7 @@ int exynos_gem_mmap(int fd, struct exynos_gem_mmap_data *in_mmap) ret = ioctl(fd, DRM_IOCTL_EXYNOS_GEM_MAP, &arg); if (ret) { - fprintf(stderr, "failed to map dumb buffer: %s\n", - strerror(errno)); + fprintf(stderr, "failed to map dumb buffer: %d\n", errno); return ret; } @@ -80,8 +79,7 @@ int exynos_gem_mmap(int fd, struct exynos_gem_mmap_data *in_mmap) map = mmap(NULL, (size_t)in_mmap->size, PROT_READ | PROT_WRITE, MAP_SHARED, fd, (off_t)arg.offset); if (map == MAP_FAILED) { - fprintf(stderr, "failed to mmap buffer: %s\n", - strerror(errno)); + fprintf(stderr, "failed to mmap buffer: %d\n", errno); return -EFAULT; } @@ -96,7 +94,7 @@ int exynos_gem_close(int fd, struct drm_gem_close *gem_close) ret = ioctl(fd, DRM_IOCTL_GEM_CLOSE, gem_close); if (ret < 0) - fprintf(stderr, "failed to close: %s\n", strerror(-ret)); + fprintf(stderr, "failed to close: %d\n", ret); return ret; } @@ -117,15 +115,13 @@ struct kms_bo* exynos_kms_gem_create(struct kms_driver *kms, ret = kms_bo_create(kms, bo_attribs, &bo); if (ret) { - fprintf(stderr, "failed to alloc buffer: %s\n", - strerror(-ret)); + fprintf(stderr, "failed to alloc buffer: %d\n", ret); return NULL; } ret = kms_bo_get_prop(bo, KMS_PITCH, stride); if (ret) { - fprintf(stderr, "failed to retreive buffer stride: %s\n", - strerror(-ret)); + fprintf(stderr, "failed to retreive buffer stride: %d\n", ret); kms_bo_destroy(&bo); return NULL; } diff --git a/tests/ipptest/util.c b/tests/ipptest/util.c index bf06b3c1..c8efe3d3 100644 --- a/tests/ipptest/util.c +++ b/tests/ipptest/util.c @@ -159,7 +159,7 @@ int util_gem_create_mmap(int fd, struct drm_exynos_gem_create *gem, gem->size = size; if (exynos_gem_create(fd, gem) < 0) { - fprintf(stderr, "failed to gem create: %s\n", strerror(errno)); + fprintf(stderr, "failed to gem create: %d\n", errno); return -1; } @@ -169,7 +169,7 @@ int util_gem_create_mmap(int fd, struct drm_exynos_gem_create *gem, mmap->size = gem->size; if (exynos_gem_mmap(fd, mmap) < 0) { - fprintf(stderr, "failed to gem mmap: %s\n", strerror(errno)); + fprintf(stderr, "failed to gem mmap: %d\n", errno); return -2; } @@ -208,8 +208,7 @@ struct kms_bo *util_kms_gem_create_mmap(struct kms_driver *kms, ret = kms_bo_map(bo, &virtual); if (ret) { - fprintf(stderr, "failed to map buffer: %s\n", - strerror(-ret)); + fprintf(stderr, "failed to map buffer: %d\n", ret); kms_bo_destroy(&bo); return NULL; } @@ -307,7 +306,7 @@ int util_kms_gem_destroy_mmap(struct kms_bo **bo) ret = kms_bo_destroy(bo); if (ret < 0) - fprintf(stderr, "failed kms bo destroy: %s\n", strerror(errno)); + fprintf(stderr, "failed kms bo destroy: %d\n", errno); return ret; } diff --git a/tests/rottest/gem.c b/tests/rottest/gem.c index 69c5a8cf..9a871f63 100644 --- a/tests/rottest/gem.c +++ b/tests/rottest/gem.c @@ -53,8 +53,7 @@ int exynos_gem_create(int fd, struct drm_exynos_gem_create *gem) } ret = ioctl(fd, DRM_IOCTL_EXYNOS_GEM_CREATE, gem); if (ret < 0) - fprintf(stderr, "failed to create gem buffer: %s\n", - strerror(-ret)); + fprintf(stderr, "failed to create gem buffer: %d\n", ret); return ret; } @@ -69,8 +68,7 @@ int exynos_gem_mmap(int fd, struct exynos_gem_mmap_data *in_mmap) ret = ioctl(fd, DRM_IOCTL_EXYNOS_GEM_MAP, &arg); if (ret) { - fprintf(stderr, "failed to map dumb buffer: %s\n", - strerror(errno)); + fprintf(stderr, "failed to map dumb buffer: %d\n", errno); return ret; } @@ -79,8 +77,7 @@ int exynos_gem_mmap(int fd, struct exynos_gem_mmap_data *in_mmap) map = mmap(NULL, (size_t)in_mmap->size, PROT_READ | PROT_WRITE, MAP_SHARED, fd, (off_t)arg.offset); if (map == MAP_FAILED) { - fprintf(stderr, "failed to mmap buffer: %s\n", - strerror(errno)); + fprintf(stderr, "failed to mmap buffer: %d\n", errno); return -EFAULT; } @@ -95,6 +92,6 @@ int exynos_gem_close(int fd, struct drm_gem_close *gem_close) ret = ioctl(fd, DRM_IOCTL_GEM_CLOSE, gem_close); if (ret < 0) - fprintf(stderr, "failed to close: %s\n", strerror(-ret)); + fprintf(stderr, "failed to close: %d\n", ret); return ret; } diff --git a/tests/rottest/rotator.c b/tests/rottest/rotator.c index 10972cac..06002ada 100644 --- a/tests/rottest/rotator.c +++ b/tests/rottest/rotator.c @@ -73,8 +73,8 @@ static int exynos_drm_ipp_set_property(int fd, ret = ioctl(fd, DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY, property); if (ret) fprintf(stderr, - "failed to DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY : %s\n", - strerror(errno)); + "failed to DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY : %d\n", + errno); return ret; } @@ -103,8 +103,8 @@ static int exynos_drm_ipp_queue_buf(int fd, int prop_id, if (ret) fprintf(stderr, "failed to DRM_IOCTL_EXYNOS_IPP_QUEUE_BUF[prop_id:%d]"\ - "[ops_id:%d][buf_id:%d][buf_type:%d] : %s\n", - prop_id, ops_id, buf_id, buf_type, strerror(errno)); + "[ops_id:%d][buf_id:%d][buf_type:%d] : %d\n", + prop_id, ops_id, buf_id, buf_type, errno); return ret; } @@ -124,7 +124,7 @@ static int exynos_drm_ipp_cmd_ctrl(int fd, int prop_id, if (ret) fprintf(stderr, "failed to DRM_IOCTL_EXYNOS_IPP_CMD_CTRL[prop_id:%d]"\ - "[ctrl:%d] : %s\n", prop_id, ctrl, strerror(errno)); + "[ctrl:%d] : %d\n", prop_id, ctrl, errno); return ret; } @@ -163,8 +163,7 @@ static int rotator_set_mode_property(struct connector *c, int count, ret = exynos_drm_ipp_set_property(fd, property, &src_pos, &src_sz, &dst_pos, &dst_sz); if (ret) - fprintf(stderr, "failed to ipp set property: %s\n", - strerror(errno)); + fprintf(stderr, "failed to ipp set property: %d\n", errno); return ret; } @@ -249,8 +248,7 @@ void rotator_1_N_set_mode(struct connector *c, int count, int page_flip, ret = rotator_set_mode_property(c, count, &width, &height, &stride, &property); if (ret) { - fprintf(stderr, "failed to set mode property : %s\n", - strerror(errno)); + fprintf(stderr, "failed to set mode property : %d\n", errno); return; } @@ -258,8 +256,7 @@ void rotator_1_N_set_mode(struct connector *c, int count, int page_flip, /* For source buffer */ ret = util_gem_create_mmap(fd, &gem1, &mmap1, stride * height); if (ret) { - fprintf(stderr, "failed to gem create mmap: %s\n", - strerror(errno)); + fprintf(stderr, "failed to gem create mmap: %d\n", errno); return; } usr_addr1 = mmap1.addr; @@ -272,8 +269,8 @@ void rotator_1_N_set_mode(struct connector *c, int count, int page_flip, ret = util_gem_create_mmap(fd, &gem2[i], &mmap2[i], stride * height); if (ret) { - fprintf(stderr, "failed to gem create mmap: %d : %s\n", - i, strerror(errno)); + fprintf(stderr, "failed to gem create mmap: %d : %d\n", + i, errno); goto err_gem_create_mmap; } usr_addr2[i] = mmap2[i].addr; @@ -439,8 +436,7 @@ void rotator_N_N_set_mode(struct connector *c, int count, int page_flip, ret = rotator_set_mode_property(c, count, &width, &height, &stride, &property); if (ret) { - fprintf(stderr, "failed to set mode property : %s\n", - strerror(errno)); + fprintf(stderr, "failed to set mode property : %d\n", errno); return; } @@ -450,8 +446,8 @@ void rotator_N_N_set_mode(struct connector *c, int count, int page_flip, ret = util_gem_create_mmap(fd, &gem1[i], &mmap1[i], stride * height); if (ret) { - fprintf(stderr, "failed to gem create mmap: %d : %s\n", - i, strerror(errno)); + fprintf(stderr, "failed to gem create mmap: %d : %d\n", + i, errno); goto err_gem_create_mmap; } usr_addr1[i] = mmap1[i].addr; @@ -463,8 +459,8 @@ void rotator_N_N_set_mode(struct connector *c, int count, int page_flip, ret = util_gem_create_mmap(fd, &gem2[i], &mmap2[i], stride * height); if (ret) { - fprintf(stderr, "failed to gem create mmap: %d : %s\n", - i, strerror(errno)); + fprintf(stderr, "failed to gem create mmap: %d : %d\n", + i, errno); goto err_gem_create_mmap; } usr_addr2[i] = mmap2[i].addr; diff --git a/tests/rottest/rottest.c b/tests/rottest/rottest.c index a035e2e0..5546a6de 100644 --- a/tests/rottest/rottest.c +++ b/tests/rottest/rottest.c @@ -123,8 +123,8 @@ static void dump_encoders(void) encoder = drmModeGetEncoder(fd, resources->encoders[i]); if (!encoder) { - fprintf(stderr, "could not get encoder %i: %s\n", - resources->encoders[i], strerror(errno)); + fprintf(stderr, "could not get encoder %i: %d\n", + resources->encoders[i], errno); continue; } printf("%d\t%d\t%s\t0x%08x\t0x%08x\n", @@ -179,8 +179,8 @@ static void dump_connectors(void) connector = drmModeGetConnector(fd, resources->connectors[i]); if (!connector) { - fprintf(stderr, "could not get connector %i: %s\n", - resources->connectors[i], strerror(errno)); + fprintf(stderr, "could not get connector %i: %d\n", + resources->connectors[i], errno); continue; } @@ -227,8 +227,8 @@ static void dump_crtcs(void) crtc = drmModeGetCrtc(fd, resources->crtcs[i]); if (!crtc) { - fprintf(stderr, "could not get crtc %i: %s\n", - resources->crtcs[i], strerror(errno)); + fprintf(stderr, "could not get crtc %i: %d\n", + resources->crtcs[i], errno); continue; } printf("%d\t%d\t(%d,%d)\t(%dx%d)\n", @@ -254,8 +254,8 @@ static void dump_framebuffers(void) fb = drmModeGetFB(fd, resources->fbs[i]); if (!fb) { - fprintf(stderr, "could not get fb %i: %s\n", - resources->fbs[i], strerror(errno)); + fprintf(stderr, "could not get fb %i: %d\n", + resources->fbs[i], errno); continue; } printf("%u\t(%ux%u)\t%u\n", @@ -290,8 +290,8 @@ void connector_find_mode(struct connector *c) connector = drmModeGetConnector(fd, resources->connectors[i]); if (!connector) { - fprintf(stderr, "could not get connector %i: %s\n", - resources->connectors[i], strerror(errno)); + fprintf(stderr, "could not get connector %i: %d\n", + resources->connectors[i], errno); continue; } @@ -339,8 +339,8 @@ void connector_find_mode(struct connector *c) encoder = drmModeGetEncoder(fd, resources->encoders[i]); if (!encoder) { - fprintf(stderr, "could not get encoder %i: %s\n", - resources->encoders[i], strerror(errno)); + fprintf(stderr, "could not get encoder %i: %d\n", + resources->encoders[i], errno); continue; } @@ -440,8 +440,7 @@ int main(int argc, char **argv) resources = drmModeGetResources(fd); if (!resources) { - fprintf(stderr, "drmModeGetResources failed: %s\n", - strerror(errno)); + fprintf(stderr, "drmModeGetResources failed: %d\n", errno); drmClose(fd); return 1; } diff --git a/tests/rottest/util.c b/tests/rottest/util.c index 3456278a..8aa793dd 100644 --- a/tests/rottest/util.c +++ b/tests/rottest/util.c @@ -47,7 +47,7 @@ int util_gem_create_mmap(int fd, struct drm_exynos_gem_create *gem, gem->size = size; if (exynos_gem_create(fd, gem) < 0) { - fprintf(stderr, "failed to gem create: %s\n", strerror(errno)); + fprintf(stderr, "failed to gem create: %d\n", errno); return -1; } @@ -57,7 +57,7 @@ int util_gem_create_mmap(int fd, struct drm_exynos_gem_create *gem, mmap->size = gem->size; if (exynos_gem_mmap(fd, mmap) < 0) { - fprintf(stderr, "failed to gem mmap: %s\n", strerror(errno)); + fprintf(stderr, "failed to gem mmap: %d\n", errno); memset(&args, 0x00, sizeof(struct drm_gem_close)); args.handle = gem->handle; exynos_gem_close(fd, &args); |