[igt-dev] [PATCH i-g-t 3/7] lib/rendercopy: Set the upper 32bits of surface base address on gen8+

Ville Syrjälä ville.syrjala at linux.intel.com
Wed Jul 4 18:47:05 UTC 2018


On Wed, Jul 04, 2018 at 05:41:37PM +0100, Chris Wilson wrote:
> Quoting Ville Syrjala (2018-07-04 17:16:42)
> > diff --git a/lib/rendercopy_gen8.c b/lib/rendercopy_gen8.c
> > index 4406a0a0e6eb..5a9bf32e6b9b 100644
> > --- a/lib/rendercopy_gen8.c
> > +++ b/lib/rendercopy_gen8.c
> > @@ -172,7 +172,8 @@ gen8_bind_buf(struct intel_batchbuffer *batch,
> >         else if (buf->tiling == I915_TILING_Y)
> >                 ss->ss0.tiled_mode = 3;
> >  
> > -       ss->ss8.base_addr = buf->bo->offset;
> > +       ss->ss8.base_addr = buf->bo->offset64;
> > +       ss->ss9.base_addr_hi = buf->bo->offset64 >> 32;
> 
> To be pedantic, we might want to use gen8_canonical_addr(x)
> { return (int64_t)((uint64_t)x << (63-47)) >> (63-47); }

Looks to me like bo->offset64 should already be a canonical
address as that's what the kernel hands back out after relocating.
Or am I missing something?

-- 
Ville Syrjälä
Intel


More information about the igt-dev mailing list