Re: [PATCH 2/4] drm/i915/gtt: Warn if the next layer scratch dma is invalid

Mika Kuoppala
2015-07-01T10:55:46Z

Chris Wilson <chris@chris-wilson.co.uk> writes:

> On Tue, Jun 30, 2015 at 05:59:27PM +0100, Michel Thierry wrote:
>> On 6/30/2015 4:16 PM, Mika Kuoppala wrote:
>> >When dma page is setup, warn if we try to point the entries
>> >to a uninitialized (zero) dma address. Like we do with gen6
>
> Just a note that 0 looks only to be reserved due to a quirk of the
> intel-iommu implementation. There is nothing preventing a different
> iommu or future implementation using 0 as a valid dma_addr_t afaict.
>
> This should presumably be
> WARN_ON(dma_mapping_error(&dev->pdev->dev, px_dma()));
> -Chris
>

Ah yes. This was my paranoia from the times we updated
execlists pdps with zero dma addresses.

Michel pointed out that we do a proper dma_mapping_error
check when we allocate the dma page. So I think this patch
can be ignored.

-Mika

> --
> Chris Wilson, Intel Open Source Technology Centre