summaryrefslogtreecommitdiff
path: root/src/lib/ecore_drm/ecore_drm_device.c
diff options
context:
space:
mode:
authorChris Michael <cp.michael@samsung.com>2014-10-08 10:06:45 -0400
committerChris Michael <cp.michael@samsung.com>2014-10-08 10:06:45 -0400
commit7135d1967df70b83bd07fca1a1e749caf90d0159 (patch)
tree3e28e8813c405fad74ca0980e1507da842d6685f /src/lib/ecore_drm/ecore_drm_device.c
parent1c77bdf2d1094ec8f00bd3e61fd585238a8cef32 (diff)
ecore-drm: Fix drm cards on ARM platform not having boot_vga parameter
Summary: On some ARM platforms, the drivers do not list boot_vga as an attribute, so we cannot do checks for that. This patch fixes finding drm cards on those platforms by skipping the boot_vga check if we had to use "platform" to find it. Thanks to shiin for the report :) @fix Signed-off-by: Chris Michael <cp.michael@samsung.com>
Diffstat (limited to 'src/lib/ecore_drm/ecore_drm_device.c')
-rw-r--r--src/lib/ecore_drm/ecore_drm_device.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/src/lib/ecore_drm/ecore_drm_device.c b/src/lib/ecore_drm/ecore_drm_device.c
index 7e43ad21a0..e3e46be613 100644
--- a/src/lib/ecore_drm/ecore_drm_device.c
+++ b/src/lib/ecore_drm/ecore_drm_device.c
@@ -152,6 +152,7 @@ ecore_drm_device_find(const char *name, const char *seat)
152{ 152{
153 Ecore_Drm_Device *dev = NULL; 153 Ecore_Drm_Device *dev = NULL;
154 Eina_Bool found = EINA_FALSE; 154 Eina_Bool found = EINA_FALSE;
155 Eina_Bool platform = EINA_FALSE;
155 Eina_List *devs, *l; 156 Eina_List *devs, *l;
156 const char *device; 157 const char *device;
157 158
@@ -189,17 +190,23 @@ ecore_drm_device_find(const char *name, const char *seat)
189 { 190 {
190 devparent = 191 devparent =
191 eeze_udev_syspath_get_parent_filtered(device, "platform", NULL); 192 eeze_udev_syspath_get_parent_filtered(device, "platform", NULL);
193 platform = EINA_TRUE;
192 } 194 }
193 195
194 if (devparent) 196 if (devparent)
195 { 197 {
196 const char *id; 198 if (!platform)
197
198 if ((id = eeze_udev_syspath_get_sysattr(devparent, "boot_vga")))
199 { 199 {
200 if (!strcmp(id, "1")) found = EINA_TRUE; 200 const char *id;
201 eina_stringshare_del(id); 201
202 if ((id = eeze_udev_syspath_get_sysattr(devparent, "boot_vga")))
203 {
204 if (!strcmp(id, "1")) found = EINA_TRUE;
205 eina_stringshare_del(id);
206 }
202 } 207 }
208 else
209 found = EINA_TRUE;
203 210
204 eina_stringshare_del(devparent); 211 eina_stringshare_del(devparent);
205 } 212 }