[igt-dev] [PATCH i-g-t 7/7] benchmarks/gem_exec_fault: Add softpin mode to support gens with ppgtt
Dixit, Ashutosh
ashutosh.dixit at intel.com
Thu Oct 14 20:07:37 UTC 2021
On Thu, 14 Oct 2021 01:19:17 -0700, Zbigniew Kempczyński wrote:
>
> @@ -127,9 +151,14 @@ static int loop(uint64_t size, unsigned ring, int reps, int ncpus,
> obj.alignment = 0;
> gem_execbuf(fd, &execbuf);
>
> - /* fault out */
> - obj.alignment = 1ull << 63;
> - __gem_execbuf(fd, &execbuf);
> + if (ahnd) {
> + obj.offset = get_offset(ahnd, obj.handle, size, 0);
> + obj.flags |= EXEC_OBJECT_PINNED | EXEC_OBJECT_SUPPORTS_48B_ADDRESS;
> + } else {
> + /* fault out */
> + obj.alignment = 1ull << 63;
> + __gem_execbuf(fd, &execbuf);
> + }
Bug above, __gem_execbuf should be moved out of the else {}.
With the bug fixed this is:
Reviewed-by: Ashutosh Dixit <ashutosh.dixit at intel.com>
More information about the igt-dev
mailing list