[Intel-gfx] [PATCH 43/49] drm/i915: Do not zero initialise page tables

Mika Kuoppala mika.kuoppala at linux.intel.com
Tue Apr 7 07:46:19 PDT 2015


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

> After we successfully allocate them, we will fill them with their
> initial contents (either the chain of page tables, or a pointer to the
> scratch page).
>
> Regression from
> commit 06fda602dbca9c59d87db7da71192e4b54c9f5ff
> Author: Ben Widawsky <benjamin.widawsky at intel.com>
> Date:   Tue Feb 24 16:22:36 2015 +0000
>
>     drm/i915: Create page table allocators
>
> Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
> Cc: Michel Thierry <michel.thierry at intel.com> (v3+)
> Cc: Mika Kuoppala <mika.kuoppala at intel.com>
> Cc: Daniel Vetter <daniel.vetter at ffwll.ch>
> ---

The gen8 parts of dynamic page table series, which Michel will resend
in near future, address this by not zero filling but pointing
unused page directory entries to scratch page table.

-Mika


>  drivers/gpu/drm/i915/i915_gem_gtt.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
> index 543fff104401..4a50e1db63dc 100644
> --- a/drivers/gpu/drm/i915/i915_gem_gtt.c
> +++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
> @@ -426,7 +426,7 @@ static struct i915_page_directory_entry *alloc_pd_single(void)
>  	if (!pd)
>  		return ERR_PTR(-ENOMEM);
>  
> -	pd->page = alloc_page(GFP_KERNEL | __GFP_ZERO);
> +	pd->page = alloc_page(GFP_KERNEL);
>  	if (!pd->page) {
>  		kfree(pd);
>  		return ERR_PTR(-ENOMEM);
> -- 
> 2.1.4


More information about the Intel-gfx mailing list