diff options
Diffstat (limited to 'tests/kms_sysfs_edid_timing')
-rwxr-xr-x | tests/kms_sysfs_edid_timing | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/tests/kms_sysfs_edid_timing b/tests/kms_sysfs_edid_timing new file mode 100755 index 000000000..ec704f672 --- /dev/null +++ b/tests/kms_sysfs_edid_timing @@ -0,0 +1,25 @@ +#!/bin/bash +# +# This check the time we take to read the content of all the possible connectors. +# Without the edid -ENXIO patch (http://permalink.gmane.org/gmane.comp.video.dri.devel/62083), +# we sometimes take a *really* long time. So let's just check for some reasonable timing here +# + +DRM_LIB_ALLOW_NO_MASTER=1 + +SOURCE_DIR="$( dirname "${BASH_SOURCE[0]}" )" +. $SOURCE_DIR/drm_lib.sh + +TIME1=$(date +%s%N) +cat $(find /sys/devices/|grep drm | grep /status) > /dev/null +TIME2=$(date +%s%N) + +# time in ms +RES=$(((TIME2 - TIME1) / 1000000)) + +if [ $RES -gt 600 ]; then + echo "Talking to outputs took ${RES}ms, something is wrong" + exit 1 +fi + +exit 0 |