Lines Matching refs:kms
48 exynos_get_prop(struct kms_driver *kms, unsigned key, unsigned *out) in exynos_get_prop() argument
61 exynos_destroy(struct kms_driver *kms) in exynos_destroy() argument
63 free(kms); in exynos_destroy()
68 exynos_bo_create(struct kms_driver *kms, in exynos_bo_create() argument
108 ret = drmCommandWriteRead(kms->fd, DRM_EXYNOS_GEM_CREATE, &arg, sizeof(arg)); in exynos_bo_create()
112 bo->base.kms = kms; in exynos_bo_create()
152 ret = drmIoctl(bo->base.kms->fd, DRM_IOCTL_MODE_MAP_DUMB, &arg); in exynos_bo_map()
156 map = drm_mmap(0, bo->base.size, PROT_READ | PROT_WRITE, MAP_SHARED, bo->base.kms->fd, arg.offset); in exynos_bo_map()
191 ret = drmIoctl(bo->base.kms->fd, DRM_IOCTL_GEM_CLOSE, &arg); in exynos_bo_destroy()
202 struct kms_driver *kms; in exynos_create() local
204 kms = calloc(1, sizeof(*kms)); in exynos_create()
205 if (!kms) in exynos_create()
208 kms->fd = fd; in exynos_create()
210 kms->bo_create = exynos_bo_create; in exynos_create()
211 kms->bo_map = exynos_bo_map; in exynos_create()
212 kms->bo_unmap = exynos_bo_unmap; in exynos_create()
213 kms->bo_get_prop = exynos_bo_get_prop; in exynos_create()
214 kms->bo_destroy = exynos_bo_destroy; in exynos_create()
215 kms->get_prop = exynos_get_prop; in exynos_create()
216 kms->destroy = exynos_destroy; in exynos_create()
217 *out = kms; in exynos_create()