tests: Add drm_import_export

Multithreaded test to validate the (lack of) locking in the flink/open
code in libdrm-intel. Based on a testcase from Rafel Sapala.

Cc: Rafal Sapala <rafal.a.sapala@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
tests/drm_import_export: Add subtest for prime

Cc: Rafal Sapala <rafal.a.sapala@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
tests/pm_rpm: factor out drm_open_any_master

Signed-off-by: Imre Deak <imre.deak@intel.com>
test/kms, pm: use drm_open_any_master

Signed-off-by: Imre Deak <imre.deak@intel.com>