Re: [RFC PATCH 2/4] drm/i915: extract per-ctx/indirect bb programming

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Quoting Lionel Landwerlin (2017-08-30 19:20:04)
> Let's put this in its own function to reuse it later.
> 
> Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@xxxxxxxxx>
> ---
>  drivers/gpu/drm/i915/intel_lrc.c | 33 +++++++++++++++++++--------------
>  1 file changed, 19 insertions(+), 14 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_lrc.c b/drivers/gpu/drm/i915/intel_lrc.c
> index 5b96b1e2353d..6da2b4f0c5a5 100644
> --- a/drivers/gpu/drm/i915/intel_lrc.c
> +++ b/drivers/gpu/drm/i915/intel_lrc.c
> @@ -1906,6 +1906,23 @@ static u32 intel_lr_indirect_ctx_offset(struct intel_engine_cs *engine)
>         return indirect_ctx_offset;
>  }
>  
> +static void execlists_init_reg_state_wa_bb(u32 *regs,
> +                                          struct intel_engine_cs *engine)
> +{
> +       struct i915_ctx_workarounds *wa_ctx = &engine->wa_ctx;
> +       u32 ggtt_offset = i915_ggtt_offset(wa_ctx->vma);

You are going to repeat the !wa_ctx->vma so you might as well pull it
in.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux