OSDN Git Service

amdgpu: verify the tested device
authorAlex Xie <AlexBin.Xie@amd.com>
Tue, 24 Jan 2017 22:29:50 +0000 (17:29 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 27 Jan 2017 16:53:26 +0000 (11:53 -0500)
commit5e0f7c5c65ca6714cd7352d72303ec2cbec35cb5
treef9a6eac3b42907850c8e9cb8d618f19daf205e78
parent8ef7e5b7026d06a803f0bf75fe323c14f142db3a
amdgpu: verify the tested device

Verify the vender ID and driver name.
Open all AMDGPU devices.
Provide an option to open render node.

Tested as root: PASS
Tested as non-privileged user:
All tests failed as expected

v2: Return value in the ene of function amdgpu_open_devices.
    Check the return value of amdgpu_open_devices.
    amdgpu_test is not for USB device for the time being.
    Get the name of node from function drmGetDevices2.
    Drop the legacy drmAvailable() from the test.

Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
Signed-off-by: Alex Xie <AlexBin.Xie@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
tests/amdgpu/amdgpu_test.c