mesa-drm/tests/amdgpu
Aaron Liu 5de99b1fa6 tests/amdgpu: add atomic_mem cp_packet to verify the secure buffer
Secure buffer is only able to be read with trusted ip block.
So we need use GFX ip to read it back instead of CPU.
Steps:
1. use write_data packet to write 0xdeadbeaf to secure buffer,
2. use atmoic_mem packet and ATOMIC_CMPSWAP_RTN_32 opcode to compare
the cmp_data(0xdeadbeaf) to the written data which has been encrypted.
If the result is equal, then overwrite the src_data(0x12345678) to the
secure buffer and return directly. Otherwise loop again until gfx timeout
and the secure buffer data unchanged.

Acked-by: Huang Rui <ray.huang@amd.com>
Acked-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Aaron Liu <aaron.liu@amd.com>
Reviewed-by: Huang Rui <ray.huang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2020-10-15 13:46:22 -04:00
..
.editorconfig amdgpu: Symlink .editorconfig to tests/amdgpu 2018-01-18 10:12:37 +01:00
amdgpu_test.c tests/amdgpu: add security test suite (v2) 2020-10-15 13:45:41 -04:00
amdgpu_test.h tests/amdgpu: add device handle as input param for exec_cs_helper and write_linear_helper (v4) 2020-10-15 13:46:11 -04:00
basic_tests.c tests/amdgpu: add atomic_mem cp_packet to verify the secure buffer 2020-10-15 13:46:22 -04:00
bo_tests.c test/amdgpu: don't free unused bo handle 2019-10-15 13:18:12 +02:00
cs_tests.c tests/amdgpu: disable unsupported test cases for Arcturus 2020-10-15 13:45:27 -04:00
deadlock_tests.c tests/amdgpu: disable unsupported test cases for Arcturus 2020-10-15 13:45:27 -04:00
decode_messages.h tests/amdgpu: clear the extension flag 2020-06-18 10:08:23 -04:00
frame.h tests/amdgpu: add uvd encode unit tests 2017-08-16 16:16:50 -04:00
meson.build tests/amdgpu: add security test suite (v2) 2020-10-15 13:45:41 -04:00
ras_tests.c tests/amdgpu: Fix buffer overflow (v3) 2020-01-08 13:21:40 -05:00
security_tests.c tests/amdgpu: add secure buffer allocation test for invisible VRAM 2020-10-15 13:46:00 -04:00
syncobj_tests.c tests/amdgpu: Fix various warnings (v2) 2020-01-08 13:18:50 -05:00
uvd_enc_tests.c meson,configure: include config.h automatically 2018-03-20 18:19:26 +00:00
uve_ib.h tests/amdgpu: fix uvd enc data corruption issue 2017-10-06 09:40:06 -04:00
vce_ib.h tests/amdgpu: add vce mv tests support and sets 2018-04-06 09:35:14 -04:00
vce_tests.c tests/amdgpu: disable unsupported test cases for Arcturus 2020-10-15 13:45:27 -04:00
vcn_tests.c tests/amdgpu/vcn: add Arcturus decode test support 2020-10-15 13:45:17 -04:00
vm_tests.c tests/amdgpu: disable unsupported test cases for Arcturus 2020-10-15 13:45:27 -04:00