[PATCH i-g-t 11/12] Revert "lib/igt_dummyload: change addr calc for reloc"

Kamil Konieczny kamil.konieczny at linux.intel.com
Wed Sep 21 18:11:43 UTC 2022


This reverts commit 2035c075016814629b35d64e09dc547010ac92b3.
---
 lib/igt_dummyload.c | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)

diff --git a/lib/igt_dummyload.c b/lib/igt_dummyload.c
index 25550dfa..17ae21f5 100644
--- a/lib/igt_dummyload.c
+++ b/lib/igt_dummyload.c
@@ -130,18 +130,15 @@ emit_recursive_batch(igt_spin_t *spin,
 	 * that wrap.
 	 */
 
-	addr = gem_aperture_size(fd);
+	addr = gem_aperture_size(fd) / 2;
 	if (addr >> 32)
 		objflags |= EXEC_OBJECT_SUPPORTS_48B_ADDRESS;
 
 	if (!ahnd) {
-		uint64_t size;
+		addr /= 2;
 		if (addr >> 31)
 			addr = 1u << 31;
-
-		size = addr / 2;
-		addr /= 4;
-		addr += random() % size;
+		addr += random() % addr / 2;
 		addr &= -4096;
 	} else {
 		objflags |= EXEC_OBJECT_PINNED;
-- 
2.34.1



More information about the Intel-gfx-trybot mailing list