drm/tests/amdgpu
Alex Xie e1ee01a758 amdgpu: Provide more specific error message if non-privileged user runs amdgpu_test
Before this change, the error message is:
"WARNING - Suite initialization failed..."
People might think this is a driver problem.

Tested with non-privileged user. Now the error message is like:
...
Error:Permission denied. Hint:Try to run this test program as root.
WARNING - Suite initialization failed for 'Basic Tests'.
...

Tested as root with no regression.

amdgpu_test uses CUnit. CUnit outputs warning message to stdout.
To be consistent, this commit outputs error message to stdout.

v2: Use strerror instead of %m. %m is a GNU C Library extension.
v3: Limit code and commit message within 80 characters per line.
    Update commit message.
    Remove a space before starting parenthesis in function call.

Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Xie <AlexBin.Xie@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-01-13 10:35:43 -05:00
..
Makefile.am tests/amdgpu: implement VCE unit tests 2015-08-05 13:47:50 -04:00
amdgpu_test.c tests/amdgpu: ensure tests work by using c99 initializers 2015-09-04 21:39:06 +01:00
amdgpu_test.h amdgpu/tests: Use buf_handle in amdgpu_bo_alloc_and_map() error paths 2015-08-05 13:47:52 -04:00
basic_tests.c amdgpu: Provide more specific error message if non-privileged user runs amdgpu_test 2017-01-13 10:35:43 -05:00
bo_tests.c amdgpu: Provide more specific error message if non-privileged user runs amdgpu_test 2017-01-13 10:35:43 -05:00
cs_tests.c amdgpu: Provide more specific error message if non-privileged user runs amdgpu_test 2017-01-13 10:35:43 -05:00
frame.h tests/amdgpu: implement VCE unit tests 2015-08-05 13:47:50 -04:00
uvd_messages.h tests/amdgpu: annotate the uvd message templates as const data 2015-09-04 21:39:06 +01:00
vce_ib.h tests/amdgpu: update vce encRefPic addr mode to tiled 2016-09-30 14:28:03 -04:00
vce_tests.c amdgpu: Provide more specific error message if non-privileged user runs amdgpu_test 2017-01-13 10:35:43 -05:00