All of lore.kernel.org
 help / color / mirror / Atom feed
From: John Harrison <John.C.Harrison@Intel.com>
To: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>,
	Intel-GFX@Lists.FreeDesktop.Org
Subject: Re: [Intel-gfx] [PATCH 02/12] drm/i915/guc: Support logical engine mapping table in ADS
Date: Wed, 16 Sep 2020 18:19:11 -0700	[thread overview]
Message-ID: <e12da086-1f4c-d915-f16b-30c8fb7b04e6@Intel.com> (raw)
In-Reply-To: <973cb6c0-3286-0c72-216d-2bd32e5d98f9@intel.com>

On 9/16/2020 16:27, Daniele Ceraolo Spurio wrote:
> On 9/16/2020 10:16 AM, John.C.Harrison@Intel.com wrote:
>> From: Matthew Brost <matthew.brost@intel.com>
>>
>> The new GuC FW introduces a physical to logical engine mapping table in
>> the GuC additional data structures which needs to be configured in order
>> for the firmware to load. This patch initializes the table with a 1 to 1
>> mapping.
>>
>> Signed-off-by: Matthew Brost <matthew.brost@intel.com>
>> CC: John Harrison <John.C.Harrison@Intel.com>
>> ---
>>   drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c  | 23 +++++++++++++++++++++
>>   drivers/gpu/drm/i915/gt/uc/intel_guc_fwif.h |  4 +++-
>>   2 files changed, 26 insertions(+), 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c 
>> b/drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c
>> index d44061033f23..57954c6360e0 100644
>> --- a/drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c
>> +++ b/drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c
>> @@ -48,6 +48,27 @@ static void guc_ct_pool_entries_init(struct 
>> guc_ct_pool_entry *pool, u32 num)
>>       memset(pool, 0, num * sizeof(*pool));
>>   }
>>   +static void guc_mapping_table_init(struct intel_gt *gt,
>> +                   struct guc_gt_system_info *system_info)
>> +{
>> +    unsigned int i, j;
>> +    struct intel_engine_cs *engine;
>> +    enum intel_engine_id id;
>> +
>> +    /* Table must be set to invalid values for entries not used */
>> +    for (i = 0; i < GUC_MAX_ENGINE_CLASSES; ++i)
>> +        for (j = 0; j < GUC_MAX_INSTANCES_PER_CLASS; ++j)
>> +            system_info->mapping_table[i][j] =
>> +                GUC_MAX_INSTANCES_PER_CLASS;
>> +
>> +    for_each_engine(engine, gt, id) {
>> +        u8 guc_class = engine->class;
>> +
>> + system_info->mapping_table[guc_class][engine->instance] =
>> +            engine->instance;
>> +    }
>> +}
>> +
>>   /*
>>    * The first 80 dwords of the register state context, containing the
>>    * execlists and ppgtt registers.
>> @@ -107,6 +128,8 @@ static void __guc_ads_init(struct intel_guc *guc)
>>       blob->system_info.vebox_enable_mask = VEBOX_MASK(gt);
>>       blob->system_info.vdbox_sfc_support_mask = 
>> gt->info.vdbox_sfc_access;
>>   +    guc_mapping_table_init(guc_to_gt(guc), &blob->system_info);
>> +
>>       base = intel_guc_ggtt_offset(guc, guc->ads_vma);
>>         /* Clients info  */
>> diff --git a/drivers/gpu/drm/i915/gt/uc/intel_guc_fwif.h 
>> b/drivers/gpu/drm/i915/gt/uc/intel_guc_fwif.h
>> index 8b3684c6a9a1..e283156624b5 100644
>> --- a/drivers/gpu/drm/i915/gt/uc/intel_guc_fwif.h
>> +++ b/drivers/gpu/drm/i915/gt/uc/intel_guc_fwif.h
>> @@ -388,7 +388,9 @@ struct guc_gt_system_info {
>>       u32 vdbox_enable_mask;
>>       u32 vdbox_sfc_support_mask;
>>       u32 vebox_enable_mask;
>> -    u32 reserved[9];
>> +    u32 reserved1;
>> +    u8 
>> mapping_table[GUC_MAX_ENGINE_CLASSES][GUC_MAX_INSTANCES_PER_CLASS];
>> +    u32 reserved2[8];
>
> I think this patch should be squashed with patch 8 to move directly to 
> the v49 version of guc_gt_system_info.
> Apart from this the patch LGTM.
>
> Daniele
The whole set is going to be squashed into a single patch for merging. 
For review purposes, the discussion was that it makes sense to keep each 
as a separate functional change. This patch adds logical engine 
mappings. Patch #8 adds extra engine classes. These are different 
functional changes.

John.



>
>>   } __packed;
>>     /* Clients info */
>

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2020-09-17  1:19 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-16 17:16 [Intel-gfx] [PATCH 00/12] drm/i915/guc: Update to GuC v49 John.C.Harrison
2020-09-16 17:16 ` [Intel-gfx] [PATCH 01/12] drm/i915/guc: New GuC IDs based on engine class and instance John.C.Harrison
2020-09-16 17:16 ` [Intel-gfx] [PATCH 02/12] drm/i915/guc: Support logical engine mapping table in ADS John.C.Harrison
2020-09-16 23:27   ` Daniele Ceraolo Spurio
2020-09-17  1:19     ` John Harrison [this message]
2020-09-16 17:16 ` [Intel-gfx] [PATCH 03/12] drm/i915/guc: Setup private_data pointer in GuC ADS John.C.Harrison
2020-09-16 23:30   ` Daniele Ceraolo Spurio
2020-09-16 17:16 ` [Intel-gfx] [PATCH 04/12] drm/i915/guc: Remove GUC_CTL_CTXINFO init param John.C.Harrison
2020-09-16 23:32   ` Daniele Ceraolo Spurio
2020-09-16 17:16 ` [Intel-gfx] [PATCH 05/12] drm/i915/guc: Kill guc_ads.reg_state_buffer John.C.Harrison
2020-09-16 23:46   ` Daniele Ceraolo Spurio
2020-09-16 17:16 ` [Intel-gfx] [PATCH 06/12] drm/i915/guc: ADS changes for GuC v42 John.C.Harrison
2020-09-16 17:16 ` [Intel-gfx] [PATCH 07/12] drm/i915/guc: Setup doorbells data in ADS John.C.Harrison
2020-09-16 17:16 ` [Intel-gfx] [PATCH 08/12] drm/i915/guc: Increased engine classes " John.C.Harrison
2020-09-16 17:16 ` [Intel-gfx] [PATCH 09/12] drm/i915/guc: Update firmware to v49.0.1 John.C.Harrison
2020-09-16 17:16 ` [Intel-gfx] [PATCH 10/12] drm/i915/guc: Improved reporting when GuC fails to load John.C.Harrison
2020-09-16 17:16 ` [Intel-gfx] [PATCH 11/12] drm/i915/guc: Clear pointers on free John.C.Harrison
2020-09-16 17:16 ` [Intel-gfx] [PATCH 12/12] drm/i915/uc: turn on GuC/HuC auto mode by default John.C.Harrison
2020-09-16 18:09 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for drm/i915/guc: Update to GuC v49 Patchwork
2020-09-16 18:35 ` [Intel-gfx] ✗ Fi.CI.BAT: failure " Patchwork
2020-09-17  1:22   ` John Harrison
2020-09-17  6:35     ` Saarinen, Jani
2020-09-17  6:48     ` Petri Latvala
2020-09-21 19:22       ` John Harrison
2020-09-21 20:36         ` Daniele Ceraolo Spurio
2020-09-21 21:21           ` John Harrison
2020-09-16 23:21 ` [Intel-gfx] [PATCH 00/12] " Daniele Ceraolo Spurio

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=e12da086-1f4c-d915-f16b-30c8fb7b04e6@Intel.com \
    --to=john.c.harrison@intel.com \
    --cc=Intel-GFX@Lists.FreeDesktop.Org \
    --cc=daniele.ceraolospurio@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.