summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDerek Foreman <derekf@osg.samsung.com>2017-08-03 15:09:06 -0500
committerDerek Foreman <derekf@osg.samsung.com>2017-08-09 14:56:59 -0500
commit70c1ce3be376ed29a25247b2d8c13e4d73edae64 (patch)
tree06f0dd9666f4ee78738d36a4d1bced038c1c6975
parentafd65a8a99592de563bd6c3afac015b259c6aa0c (diff)
ecore_drm2: Remove useless safety checks
Now that the device is opened and found in one operation it's impossible to have fd == -1, so we can stop testing for it.
-rw-r--r--src/lib/ecore_drm2/ecore_drm2_device.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/src/lib/ecore_drm2/ecore_drm2_device.c b/src/lib/ecore_drm2/ecore_drm2_device.c
index 7ec429523b..e5a41fd9c8 100644
--- a/src/lib/ecore_drm2/ecore_drm2_device.c
+++ b/src/lib/ecore_drm2/ecore_drm2_device.c
@@ -701,7 +701,6 @@ ecore_drm2_device_clock_id_get(Ecore_Drm2_Device *device)
701 int ret; 701 int ret;
702 702
703 EINA_SAFETY_ON_NULL_RETURN_VAL(device, -1); 703 EINA_SAFETY_ON_NULL_RETURN_VAL(device, -1);
704 EINA_SAFETY_ON_TRUE_RETURN_VAL((device->fd < 0), -1);
705 704
706 ret = sym_drmGetCap(device->fd, DRM_CAP_TIMESTAMP_MONOTONIC, &caps); 705 ret = sym_drmGetCap(device->fd, DRM_CAP_TIMESTAMP_MONOTONIC, &caps);
707 if ((ret == 0) && (caps == 1)) 706 if ((ret == 0) && (caps == 1))
@@ -717,7 +716,6 @@ ecore_drm2_device_cursor_size_get(Ecore_Drm2_Device *device, int *width, int *he
717 int ret; 716 int ret;
718 717
719 EINA_SAFETY_ON_NULL_RETURN(device); 718 EINA_SAFETY_ON_NULL_RETURN(device);
720 EINA_SAFETY_ON_TRUE_RETURN((device->fd < 0));
721 719
722 if (width) 720 if (width)
723 { 721 {
@@ -857,7 +855,6 @@ ecore_drm2_device_prefer_shadow(Ecore_Drm2_Device *device)
857 int ret; 855 int ret;
858 856
859 EINA_SAFETY_ON_NULL_RETURN_VAL(device, EINA_FALSE); 857 EINA_SAFETY_ON_NULL_RETURN_VAL(device, EINA_FALSE);
860 EINA_SAFETY_ON_TRUE_RETURN_VAL((device->fd < 0), EINA_FALSE);
861 858
862 ret = sym_drmGetCap(device->fd, DRM_CAP_DUMB_PREFER_SHADOW, &caps); 859 ret = sym_drmGetCap(device->fd, DRM_CAP_DUMB_PREFER_SHADOW, &caps);
863 if ((ret == 0) && (caps == 1)) 860 if ((ret == 0) && (caps == 1))