Return-Path: Date: Wed, 05 Jan 2022 11:00:57 -0800 Message-ID: <87y23u9fdi.wl-ashutosh.dixit@intel.com> From: "Dixit, Ashutosh" In-Reply-To: <20220105172106.154217-1-matthew.auld@intel.com> References: <20220105172106.154217-1-matthew.auld@intel.com> MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [igt-dev] [PATCH i-g-t] tests/i915/userptr: fix mapping type List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: igt-dev-bounces@lists.freedesktop.org Sender: "igt-dev" To: Matthew Auld Cc: igt-dev@lists.freedesktop.org, Thomas =?ISO-8859-1?Q?Hellstr=F6m?= , intel-gfx@lists.freedesktop.org List-ID: On Wed, 05 Jan 2022 09:21:06 -0800, Matthew Auld wrote: > > We need to use the FIXED mapping type on discrete platforms. Reviewed-by: Ashutosh Dixit > Signed-off-by: Matthew Auld > Cc: Thomas Hellstr=F6m > Cc: Priyanka Dandamudi > --- > tests/i915/gem_userptr_blits.c | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/tests/i915/gem_userptr_blits.c b/tests/i915/gem_userptr_blit= s.c > index 3464db66..a4dca4c0 100644 > --- a/tests/i915/gem_userptr_blits.c > +++ b/tests/i915/gem_userptr_blits.c > @@ -2185,7 +2185,10 @@ static void test_probe(int fd) > */ > memset(&mmap_offset, 0, sizeof(mmap_offset)); > mmap_offset.handle =3D gem_create(fd, PAGE_SIZE); > - mmap_offset.flags =3D I915_MMAP_OFFSET_WB; > + if (gem_has_lmem(fd)) > + mmap_offset.flags =3D I915_MMAP_OFFSET_FIXED; > + else > + mmap_offset.flags =3D I915_MMAP_OFFSET_WB; > igt_assert_eq(igt_ioctl(fd, DRM_IOCTL_I915_GEM_MMAP_OFFSET, &mmap_offset)= , 0); > > for (unsigned long pass =3D 0; pass < 4 * 4 * 4 * 4 * 4; pass++) { > -- > 2.31.1 >