[igt-dev] [PATCH i-g-t v2 17/18] tests/i915/gem_ppgtt: make copying more readable
Dominik Grzegorzek
dominik.grzegorzek at intel.com
Wed Sep 30 09:21:54 UTC 2020
Use intel_bb_copy_intel_buf instead of intel_bb_blit_copy
to make the code simplier.
Signed-off-by: Dominik Grzegorzek <dominik.grzegorzek at intel.com>
Cc: Zbigniew Kempczyński <zbigniew.kempczynski at intel.com>
Cc: Chris Wilson <chris at chris-wilson.co.uk>
---
tests/i915/gem_ppgtt.c | 16 ++++------------
1 file changed, 4 insertions(+), 12 deletions(-)
diff --git a/tests/i915/gem_ppgtt.c b/tests/i915/gem_ppgtt.c
index 949601ac..9426a027 100644
--- a/tests/i915/gem_ppgtt.c
+++ b/tests/i915/gem_ppgtt.c
@@ -165,12 +165,8 @@ static void fork_bcs_copy(int timeout, uint32_t final,
src[1] = create_bo(dst[child]->bops,
i++ | child << 16);
- intel_bb_blt_copy(ibb, src[1], 0, 0, 4096,
- src[0], 0, 0, 4096,
- 4096/4, SIZE/4096, 32);
- intel_bb_blt_copy(ibb, src[0], 0, 0, 4096,
- dst[child], 0, 0, 4096,
- 4096/4, SIZE/4096, 32);
+ intel_bb_copy_intel_buf(ibb, src[1], src[0], SIZE);
+ intel_bb_copy_intel_buf(ibb, src[0], dst[child], SIZE);
intel_buf_destroy(src[1]);
intel_buf_destroy(src[0]);
@@ -180,12 +176,8 @@ static void fork_bcs_copy(int timeout, uint32_t final,
src[1] = create_bo(dst[child]->bops,
final | child << 16);
- intel_bb_blt_copy(ibb, src[1], 0, 0, 4096,
- src[0], 0, 0, 4096,
- 4096/4, SIZE/4096, 32);
- intel_bb_blt_copy(ibb, src[0], 0, 0, 4096,
- dst[child], 0, 0, 4096,
- 4096/4, SIZE/4096, 32);
+ intel_bb_copy_intel_buf(ibb, src[1], src[0], SIZE);
+ intel_bb_copy_intel_buf(ibb, src[0], dst[child], SIZE);
intel_buf_destroy(src[1]);
intel_buf_destroy(src[0]);
--
2.20.1
More information about the igt-dev
mailing list