[igt-dev] [PATCH i-g-t v27 10/30] tests/gem_caching|partial: adopt to batch flush function cleanup

Zbigniew Kempczyński
2020-08-10T09:47:57Z

intel_bb API has been cleaned so flush generates also BBE and executes
the batch. Remove redundant code to use flush properly.

Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
Cc: Dominik Grzegorzek <dominik.grzegorzek@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
---
tests/i915/gem_caching.c | 5 -----
tests/i915/gem_partial_pwrite_pread.c | 3 ---
2 files changed, 8 deletions(-)

diff --git a/tests/i915/gem_caching.c b/tests/i915/gem_caching.c
index 894c4b12..c178c98e 100644
--- a/tests/i915/gem_caching.c
+++ b/tests/i915/gem_caching.c
@@ -99,11 +99,6 @@ copy_bo(struct intel_bb *ibb, struct intel_buf *src, struct intel_buf *dst)
intel_bb_emit_reloc_fenced(ibb, src->handle,
I915_GEM_DOMAIN_RENDER,
0, 0, 0x0);
-
- /* Mark the end of the buffer. */
- intel_bb_out(ibb, MI_BATCH_BUFFER_END);
- intel_bb_ptr_align(ibb, 8);
-
intel_bb_flush_blit(ibb);
intel_bb_sync(ibb);
}
diff --git a/tests/i915/gem_partial_pwrite_pread.c b/tests/i915/gem_partial_pwrite_pread.c
index b4bae9b6..b1028472 100644
--- a/tests/i915/gem_partial_pwrite_pread.c
+++ b/tests/i915/gem_partial_pwrite_pread.c
@@ -101,9 +101,6 @@ static void copy_bo(struct intel_buf *src, struct intel_buf *dst)
I915_GEM_DOMAIN_RENDER,
0, 0, 0x0);

- intel_bb_out(ibb, MI_BATCH_BUFFER_END);
- intel_bb_ptr_align(ibb, 8);
-
intel_bb_flush_blit(ibb);
intel_bb_sync(ibb);