summaryrefslogtreecommitdiff
path: root/src/lib/ecore_drm2/ecore_drm2_device.c
diff options
context:
space:
mode:
authorChris Michael <cpmichael@osg.samsung.com>2016-05-11 09:45:38 -0400
committerChris Michael <cpmichael@osg.samsung.com>2016-05-27 11:57:53 -0400
commit92553e167e6c03611e299f41fe538f8963e45723 (patch)
tree1a2c97cf0a4484324bcdccce0878f06171333546 /src/lib/ecore_drm2/ecore_drm2_device.c
parent6697584fb9d553c2cd317ab3adffba04b5f710a3 (diff)
ecore-drm2: Initialize elput input when device gets opened
Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
Diffstat (limited to 'src/lib/ecore_drm2/ecore_drm2_device.c')
-rw-r--r--src/lib/ecore_drm2/ecore_drm2_device.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/lib/ecore_drm2/ecore_drm2_device.c b/src/lib/ecore_drm2/ecore_drm2_device.c
index ec180adade..530adcf6d9 100644
--- a/src/lib/ecore_drm2/ecore_drm2_device.c
+++ b/src/lib/ecore_drm2/ecore_drm2_device.c
@@ -134,6 +134,12 @@ ecore_drm2_device_open(Ecore_Drm2_Device *device)
134 134
135 device->fd = elput_manager_open(device->em, device->path, -1); 135 device->fd = elput_manager_open(device->em, device->path, -1);
136 136
137 if (!elput_input_init(device->em, NULL))
138 {
139 ERR("Could not initialize Elput Input");
140 goto err;
141 }
142
137 DBG("Device Path: %s", device->path); 143 DBG("Device Path: %s", device->path);
138 DBG("Device Fd: %d", device->fd); 144 DBG("Device Fd: %d", device->fd);
139 145
@@ -146,6 +152,10 @@ ecore_drm2_device_open(Ecore_Drm2_Device *device)
146 /* ERR("Could not set Universal Plane support: %m"); */ 152 /* ERR("Could not set Universal Plane support: %m"); */
147 153
148 return device->fd; 154 return device->fd;
155
156err:
157 elput_manager_close(device->em, device->fd);
158 return -1;
149} 159}
150 160
151EAPI void 161EAPI void
@@ -154,6 +164,7 @@ ecore_drm2_device_close(Ecore_Drm2_Device *device)
154 EINA_SAFETY_ON_NULL_RETURN(device); 164 EINA_SAFETY_ON_NULL_RETURN(device);
155 EINA_SAFETY_ON_TRUE_RETURN(device->fd < 0); 165 EINA_SAFETY_ON_TRUE_RETURN(device->fd < 0);
156 166
167 elput_input_shutdown(device->em);
157 elput_manager_close(device->em, device->fd); 168 elput_manager_close(device->em, device->fd);
158} 169}
159 170