ecore_drm2: simplify device selection code
The platform check was added for systems (like ARM) that don't generally have PCI graphics devices. However, now we pick a fallback device that doesn't have a PCI constraint, so the platform check should no longer be necessary.
This commit is contained in:
parent
324c917a20
commit
54fede47a9
|
@ -97,7 +97,6 @@ _drm2_device_find(Elput_Manager *em, const char *seat)
|
||||||
Eina_List *devs, *l;
|
Eina_List *devs, *l;
|
||||||
const char *dev, *ret = NULL, *chosen_dev = NULL;
|
const char *dev, *ret = NULL, *chosen_dev = NULL;
|
||||||
Eina_Bool found = EINA_FALSE;
|
Eina_Bool found = EINA_FALSE;
|
||||||
Eina_Bool platform = EINA_FALSE;
|
|
||||||
Eina_Bool modeset;
|
Eina_Bool modeset;
|
||||||
int fd;
|
int fd;
|
||||||
|
|
||||||
|
@ -130,16 +129,7 @@ _drm2_device_find(Elput_Manager *em, const char *seat)
|
||||||
chosen_dev = dev;
|
chosen_dev = dev;
|
||||||
|
|
||||||
dparent = eeze_udev_syspath_get_parent_filtered(dev, "pci", NULL);
|
dparent = eeze_udev_syspath_get_parent_filtered(dev, "pci", NULL);
|
||||||
if (!dparent)
|
|
||||||
{
|
|
||||||
dparent =
|
|
||||||
eeze_udev_syspath_get_parent_filtered(dev, "platform", NULL);
|
|
||||||
platform = EINA_TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (dparent)
|
if (dparent)
|
||||||
{
|
|
||||||
if (!platform)
|
|
||||||
{
|
{
|
||||||
const char *id;
|
const char *id;
|
||||||
|
|
||||||
|
@ -149,9 +139,6 @@ _drm2_device_find(Elput_Manager *em, const char *seat)
|
||||||
if (!strcmp(id, "1")) found = EINA_TRUE;
|
if (!strcmp(id, "1")) found = EINA_TRUE;
|
||||||
eina_stringshare_del(id);
|
eina_stringshare_del(id);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
else
|
|
||||||
found = EINA_TRUE;
|
|
||||||
|
|
||||||
eina_stringshare_del(dparent);
|
eina_stringshare_del(dparent);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue