igt/gem_userptr_blits: Fix forked access test
[platform/upstream/intel-gpu-tools.git] / tests / kms_sysfs_edid_timing
1 #!/bin/bash
2 #
3 # This check the time we take to read the content of all the possible connectors.
4 # Without the edid -ENXIO patch (http://permalink.gmane.org/gmane.comp.video.dri.devel/62083),
5 # we sometimes take a *really* long time. So let's just check for some reasonable timing here
6 #
7
8 DRM_LIB_ALLOW_NO_MASTER=1
9
10 SOURCE_DIR="$( dirname "${BASH_SOURCE[0]}" )"
11 . $SOURCE_DIR/drm_lib.sh
12
13 TIME1=$(date +%s%N)
14 cat $(find /sys/devices/|grep drm | grep /status) > /dev/null
15 TIME2=$(date +%s%N)
16
17 # time in ms
18 RES=$(((TIME2 - TIME1) / 1000000))
19
20 if [ $RES -gt 600 ]; then
21         echo "Talking to outputs took ${RES}ms, something is wrong"
22         exit 1
23 fi
24
25 exit 0