GuC 32.0.3
Subsystems (2)
v5 cover GuC 32.0.3
New GuC firmwares (for SKL, BXT, KBL, GLK, ICL) with updated ABI interface.
v2: only HuC authentication is supported
v3: never allow to turn on GuC submission mode
v4: rebased + newer HuC + GLK
v5: squashed + last minutes small fixups
Michal Wajdeczko (15):
drm/i915/guc: Change platform default GuC mode drm/i915/guc: Don't allow GuC submission drm/i915/guc: Updates for GuC 32.0.3 firmware drm/i915/guc: Reset GuC ADS during sanitize drm/i915/guc: Always ask GuC to update power domain states drm/i915/guc: Define GuC firmware version for Geminilake drm/i915/huc: Define HuC firmware version for Geminilake drm/i915/guc: New GuC interrupt register for Gen11 drm/i915/guc: New GuC scratch registers for Gen11 drm/i915/huc: New HuC status register for Gen11 drm/i915/guc: Update GuC CTB response definition drm/i915/guc: Enable GuC CTB communication on Gen11 drm/i915/guc: Define GuC firmware version for Icelake drm/i915/huc: Define HuC firmware version for Icelake
HAX: Turn on GuC/HuC auto mode
Oscar Mateo (2):
drm/i915/guc: Create vfuncs for the GuC interrupts control functions drm/i915/guc: Correctly handle GuC interrupts on Gen11
drivers/gpu/drm/i915/gt/intel_engine.h | 2 + drivers/gpu/drm/i915/gt/intel_engine_cs.c | 9 +- drivers/gpu/drm/i915/i915_irq.c | 59 +++++- drivers/gpu/drm/i915/i915_irq.h | 3 + drivers/gpu/drm/i915/i915_params.h | 2 +- drivers/gpu/drm/i915/i915_pci.c | 1 + drivers/gpu/drm/i915/i915_reg.h | 4 + drivers/gpu/drm/i915/intel_guc.c | 121 ++++++------ drivers/gpu/drm/i915/intel_guc.h | 8 +- drivers/gpu/drm/i915/intel_guc_ads.c | 167 ++++++++++------ drivers/gpu/drm/i915/intel_guc_ads.h | 1 + drivers/gpu/drm/i915/intel_guc_ct.c | 2 +- drivers/gpu/drm/i915/intel_guc_fw.c | 97 ++++++---- drivers/gpu/drm/i915/intel_guc_fwif.h | 199 +++++++++----------- drivers/gpu/drm/i915/intel_guc_reg.h | 25 +++ drivers/gpu/drm/i915/intel_guc_submission.c | 4 - drivers/gpu/drm/i915/intel_huc.c | 26 ++- drivers/gpu/drm/i915/intel_huc.h | 7 + drivers/gpu/drm/i915/intel_huc_fw.c | 24 +++ drivers/gpu/drm/i915/intel_uc.c | 51 +++-- drivers/gpu/drm/i915/intel_uc_fw.c | 20 +- 21 files changed, 530 insertions(+), 302 deletions(-)
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 1/17 drm/i915/guc: Change platform default GuC mode
Today our most desired GuC configuration is to only enable HuC if it is available (as we need authenticated HuC firmware to enable all media codecs on the hardware) and we really don't care about having GuC submission enabled.
Change platform default GuC mode to match our goal, but note that we still don't change default modparam value (GuC/HuC disabled).
v2: add why HuC is so important (Joonas)
--- drivers/gpu/drm/i915/intel_uc.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/gpu/drm/i915/intel_uc.c +2 -4
@@ -57,10 +57,8 @@ static int __get_platform_enable_guc(struct drm_i915_private *i915)struct intel_uc_fw *huc_fw = &i915->huc.fw;int enable_guc =0 ; -/* Default is to enable GuC/HuC if we know their firmwares */ -if (intel_uc_fw_is_selected (guc_fw)) - enable_guc |=ENABLE_GUC_SUBMISSION ; -if (intel_uc_fw_is_selected (huc_fw)) +/* Default is to use HuC if we know GuC and HuC firmwares */ +if (intel_uc_fw_is_selected (guc_fw) &&intel_uc_fw_is_selected (huc_fw)) enable_guc |=ENABLE_GUC_LOAD_HUC ;/* Any platform specific fine-tuning can be done here */
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 2/17 drm/i915/guc: Don't allow GuC submission
In reply to Michal WajdeczkoDue to the upcoming changes to the GuC ABI interface, we must disable GuC submission mode until final ABI will be available on all GuC firmwares.
To avoid regressions on systems configured to run with no longer supported configuration "enable_guc=3" or "enable_guc=1" clear GuC submission bit.
v2: force switch to non-GuC submission mode
v3: use GEM_BUG_ON (Joonas)
--- drivers/gpu/drm/i915/intel_uc.c | 12 ++++++++++++ 1 file changed, 12 insertions(+)
drivers/gpu/drm/i915/intel_uc.c +12 -0
@@ -130,6 +130,15 @@ static void sanitize_options_early(struct drm_i915_private *i915) "no HuC firmware"); } +/* XXX: GuC submission is unavailable for now */ +if (intel_uc_is_using_guc_submission (i915)) { +DRM_INFO ("Incompatible option detected: %s=%d, %s!\n" , +"enable_guc" , i915_modparams.enable_guc, +"GuC submission not supported" ); +DRM_INFO ("Switching to non-GuC submission mode!\n" ); + i915_modparams.enable_guc &= ~ENABLE_GUC_SUBMISSION ; + } +/* A negative value means "use platform/config default" */ if (i915_modparams.guc_log_level <0 ) i915_modparams.guc_log_level =
@@ -298,6 +307,9 @@ int intel_uc_init(struct drm_i915_private *i915)if (!HAS_GUC (i915))return -ENODEV ; +/* XXX: GuC submission is unavailable for now */ +GEM_BUG_ON (USES_GUC_SUBMISSION (i915)); + ret =intel_guc_init (guc);if (ret)return ret;
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 3/17 drm/i915/guc: Updates for GuC 32.0.3 firmware
In reply to Michal WajdeczkoNew GuC 32.0.3 firmware made many changes around its ABI that require driver updates:
* FW release version numbering schema now includes patch number
* FW release version encoding in CSS header
* Boot parameters
* Suspend/resume protocol
* Sample-forcewake command
* Additional Data Structures (ADS)
This commit is a squash of patches 3-8 from series [1].
[1] https://patchwork.freedesktop.org/series/58760/
--- drivers/gpu/drm/i915/gt/intel_engine.h | 2 + drivers/gpu/drm/i915/gt/intel_engine_cs.c | 9 +- drivers/gpu/drm/i915/intel_guc.c | 88 ++++------ drivers/gpu/drm/i915/intel_guc_ads.c | 95 +++++++---- drivers/gpu/drm/i915/intel_guc_fw.c | 75 +++++---- drivers/gpu/drm/i915/intel_guc_fwif.h | 191 ++++++++++------------ drivers/gpu/drm/i915/intel_uc_fw.c | 20 +-- 7 files changed, 237 insertions(+), 243 deletions(-)
drivers/gpu/drm/i915/gt/intel_engine.h +2 -0
@@ -526,6 +526,8 @@ ktime_t intel_engine_get_busy_time(struct intel_engine_cs *engine);struct i915_request *intel_engine_find_active_request (struct intel_engine_cs *engine); +u32 intel_engine_context_size (struct drm_i915_private *i915,u8 class); +#if IS_ENABLED (CONFIG_DRM_I915_SELFTEST )static inline bool inject_preempt_hang (struct intel_engine_execlists *execlists)
drivers/gpu/drm/i915/gt/intel_engine_cs.c +4 -5
@@ -156,7 +156,7 @@ static const struct engine_info intel_engines[] = { };/** -* ___intel_engine_context_size() - return the size of the context for an engine +* intel_engine_context_size() - return the size of the context for an engine * @dev_priv: i915 device private * @class: engine class *
@@ -169,8 +169,7 @@ static const struct engine_info intel_engines[] = {* in LRC mode, but does not include the "shared data page" used with * GuC submission. The caller should account for this if using the GuC. */ -static u32 -__intel_engine_context_size (struct drm_i915_private *dev_priv,u8 class) +u32 intel_engine_context_size (struct drm_i915_private *dev_priv,u8 class) {u32 cxt_size;
@@ -327,8 +326,8 @@ intel_engine_setup(struct drm_i915_private *dev_priv, engine->uabi_class = intel_engine_classes[info->class].uabi_class; - engine->context_size =__intel_engine_context_size (dev_priv, - engine->class); + engine->context_size =intel_engine_context_size (dev_priv, + engine->class);if (WARN_ON (engine->context_size >BIT (20 ))) engine->context_size =0 ;if (engine->context_size)
drivers/gpu/drm/i915/intel_guc.c +34 -54
144 lines not on this page · raw message
drivers/gpu/drm/i915/intel_guc_ads.c +59 -36
143 lines not on this page · raw message
drivers/gpu/drm/i915/intel_guc_fw.c +41 -34
94 lines not on this page · raw message
drivers/gpu/drm/i915/intel_guc_fwif.h +87 -104
304 lines not on this page · raw message
drivers/gpu/drm/i915/intel_uc_fw.c +10 -10
@@ -22,6 +22,7 @@* */ +#include <linux/bitfield.h> #include <linux/firmware.h> #include <drm/drm_print.h>
@@ -119,21 +120,20 @@ void intel_uc_fw_fetch(struct drm_i915_private *dev_priv, goto fail; } -/* -* The GuC firmware image has the version number embedded at a -* well-known offset within the firmware blob; note that major / minor -* version are TWO bytes each (i.e. u16), although all pointers and -* offsets are defined in terms of bytes (u8). -*/ +/* Get version numbers from the CSS header */ switch (uc_fw->type) {case INTEL_UC_FW_TYPE_GUC : - uc_fw->major_ver_found = css->guc.sw_version >>16 ; - uc_fw->minor_ver_found = css->guc.sw_version &0xFFFF ; + uc_fw->major_ver_found =FIELD_GET (CSS_SW_VERSION_GUC_MAJOR , + css->sw_version); + uc_fw->minor_ver_found =FIELD_GET (CSS_SW_VERSION_GUC_MINOR , + css->sw_version);break ;case INTEL_UC_FW_TYPE_HUC : - uc_fw->major_ver_found = css->huc.sw_version >>16 ; - uc_fw->minor_ver_found = css->huc.sw_version &0xFFFF ; + uc_fw->major_ver_found =FIELD_GET (CSS_SW_VERSION_HUC_MAJOR , + css->sw_version); + uc_fw->minor_ver_found =FIELD_GET (CSS_SW_VERSION_HUC_MINOR , + css->sw_version);break ;default :
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 4/17 drm/i915/guc: Reset GuC ADS during sanitize
In reply to Michal WajdeczkoGuC stores some data in there, which might be stale after a reset. Reinitialize whole ADS in case any part of it was corrupted during previous GuC run.
v2: s/reinit/init, update functions descriptions (Tomek/Michal)
v3: reset ADS right before fw upload
--- drivers/gpu/drm/i915/intel_guc_ads.c | 90 ++++++++++++++++++---------- drivers/gpu/drm/i915/intel_guc_ads.h | 1 + drivers/gpu/drm/i915/intel_uc.c | 4 +- 3 files changed, 63 insertions(+), 32 deletions(-)
drivers/gpu/drm/i915/intel_guc_ads.c +59 -31
@@ -72,43 +72,28 @@ static void guc_ct_pool_entries_init(struct guc_ct_pool_entry *pool, u32 num)*/ #define LR_HW_CONTEXT_SIZE (80 * sizeof(u32)) -/** -* intel_guc_ads_create() - creates GuC ADS -* @guc: intel_guc struct -* -*/ -int intel_guc_ads_create (struct intel_guc *guc) +/* The ads obj includes the struct itself and buffers passed to GuC */ +struct __guc_ads_blob { +struct guc_ads ads; +struct guc_policies policies; +struct guc_mmio_reg_state reg_state; +struct guc_gt_system_info system_info; +struct guc_clients_info clients_info; +struct guc_ct_pool_entry ct_pool[GUC_CT_POOL_SIZE ]; +u8 reg_state_buffer[GUC_S3_SAVE_SPACE_PAGES *PAGE_SIZE ]; +} __packed; + +static int __guc_ads_init (struct intel_guc *guc) {struct drm_i915_private *dev_priv =guc_to_i915 (guc); -struct i915_vma *vma; -/* The ads obj includes the struct itself and buffers passed to GuC */ -struct { -struct guc_ads ads; -struct guc_policies policies; -struct guc_mmio_reg_state reg_state; -struct guc_gt_system_info system_info; -struct guc_clients_info clients_info; -struct guc_ct_pool_entry ct_pool[GUC_CT_POOL_SIZE ]; -u8 reg_state_buffer[GUC_S3_SAVE_SPACE_PAGES *PAGE_SIZE ]; - } __packed *blob; +struct __guc_ads_blob *blob;const u32 skipped_size =LRC_PPHWSP_SZ *PAGE_SIZE +LR_HW_CONTEXT_SIZE ;u32 base;u8 engine_class; -int ret; - -GEM_BUG_ON (guc->ads_vma); - - vma =intel_guc_allocate_vma (guc,PAGE_ALIGN (sizeof (*blob))); -if (IS_ERR (vma)) -return PTR_ERR (vma); - - guc->ads_vma = vma; blob =i915_gem_object_pin_map (guc->ads_vma->obj,I915_MAP_WB ); -if (IS_ERR (blob)) { - ret =PTR_ERR (blob); - goto err_vma; - } +if (IS_ERR (blob)) +return PTR_ERR (blob);/* GuC scheduling policies */ guc_policies_init (&blob->policies);
@@ -143,7 +128,7 @@ int intel_guc_ads_create(struct intel_guc *guc) blob->system_info.vebox_enable_mask =VEBOX_MASK (dev_priv); blob->system_info.vdbox_sfc_support_mask =RUNTIME_INFO (dev_priv)->vdbox_sfc_access; - base =intel_guc_ggtt_offset (guc, vma); + base =intel_guc_ggtt_offset (guc, guc->ads_vma);/* Clients info */ guc_ct_pool_entries_init (blob->ct_pool,ARRAY_SIZE (blob->ct_pool));
@@ -162,6 +147,34 @@ int intel_guc_ads_create(struct intel_guc *guc)i915_gem_object_unpin_map (guc->ads_vma->obj);return 0 ; +} + +/** +* intel_guc_ads_create() - allocates and initializes GuC ADS. +* @guc: intel_guc struct +* +* GuC needs memory block (Additional Data Struct), where it will store +* some data. Allocate and initialize such memory block for GuC use. +*/ +int intel_guc_ads_create (struct intel_guc *guc) +{ +const u32 size =PAGE_ALIGN (sizeof (struct __guc_ads_blob )); +struct i915_vma *vma; +int ret; + +GEM_BUG_ON (guc->ads_vma); + + vma =intel_guc_allocate_vma (guc, size); +if (IS_ERR (vma)) +return PTR_ERR (vma); + + guc->ads_vma = vma; + + ret =__guc_ads_init (guc); +if (ret) + goto err_vma; + +return 0 ; err_vma:i915_vma_unpin_and_release (&guc->ads_vma,0 );
@@ -172,3 +185,18 @@ void intel_guc_ads_destroy(struct intel_guc *guc) {i915_vma_unpin_and_release (&guc->ads_vma,0 ); } + +/** +* intel_guc_ads_reset() - prepares GuC Additional Data Struct for reuse +* @guc: intel_guc struct +* +* GuC stores some data in ADS, which might be stale after a reset. +* Reinitialize whole ADS in case any part of it was corrupted during +* previous GuC run. +*/ +void intel_guc_ads_reset (struct intel_guc *guc) +{ +if (!guc->ads_vma) +return ; +__guc_ads_init (guc); +}
drivers/gpu/drm/i915/intel_guc_ads.h +1 -0
@@ -29,5 +29,6 @@ struct intel_guc;int intel_guc_ads_create (struct intel_guc *guc);void intel_guc_ads_destroy (struct intel_guc *guc); +void intel_guc_ads_reset (struct intel_guc *guc);#endif
drivers/gpu/drm/i915/intel_uc.c +3 -1
@@ -24,8 +24,9 @@#include "gt/intel_reset.h" #include "intel_uc.h" -#include "intel_guc_submission.h" #include "intel_guc.h" +#include "intel_guc_ads.h" +#include "intel_guc_submission.h" #include "i915_drv.h" static void guc_free_load_err_log (struct intel_guc *guc);
@@ -414,6 +415,7 @@ int intel_uc_init_hw(struct drm_i915_private *i915) goto err_out; } +intel_guc_ads_reset (guc);intel_guc_init_params (guc); ret =intel_guc_fw_upload (guc);if (ret ==0 )
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 5/17 drm/i915/guc: Always ask GuC to update power domain states
In reply to Michal WajdeczkoWith newer GuC firmware it is always ok to ask GuC to update power domain states. Make it an unconditional initialization step.
--- drivers/gpu/drm/i915/intel_guc_submission.c | 4 ---- drivers/gpu/drm/i915/intel_uc.c | 8 ++++---- 2 files changed, 4 insertions(+), 8 deletions(-)
drivers/gpu/drm/i915/intel_guc_submission.c +0 -4
@@ -1426,10 +1426,6 @@ int intel_guc_submission_enable(struct intel_guc *guc)GEM_BUG_ON (!guc->execbuf_client); - err =intel_guc_sample_forcewake (guc); -if (err) -return err; - err =guc_clients_enable (guc);if (err)return err;
drivers/gpu/drm/i915/intel_uc.c +4 -4
@@ -439,14 +439,14 @@ int intel_uc_init_hw(struct drm_i915_private *i915) goto err_communication; } + ret =intel_guc_sample_forcewake (guc); +if (ret) + goto err_communication; +if (USES_GUC_SUBMISSION (i915)) { ret =intel_guc_submission_enable (guc);if (ret) goto err_communication; - }else if (INTEL_GEN (i915) <11 ) { - ret =intel_guc_sample_forcewake (guc); -if (ret) - goto err_communication; } dev_info(i915->drm.dev, "GuC firmware version %u.%u\n",
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 6/17 drm/i915/guc: Define GuC firmware version for Geminilake
In reply to Michal WajdeczkoDefine GuC firmware version for Geminilake.
--- drivers/gpu/drm/i915/intel_guc_fw.c | 11 +++++++++++ 1 file changed, 11 insertions(+)
drivers/gpu/drm/i915/intel_guc_fw.c +11 -0
@@ -58,6 +58,13 @@ MODULE_FIRMWARE(BXT_GUC_FIRMWARE_PATH);#define KBL_GUC_FIRMWARE_PATH __MAKE_GUC_FW_PATH(KBL)MODULE_FIRMWARE (KBL_GUC_FIRMWARE_PATH ); +#define GLK_GUC_FW_PREFIX glk +#define GLK_GUC_FW_MAJOR 32 +#define GLK_GUC_FW_MINOR 0 +#define GLK_GUC_FW_PATCH 3 +#define GLK_GUC_FIRMWARE_PATH __MAKE_GUC_FW_PATH(GLK) +MODULE_FIRMWARE (GLK_GUC_FIRMWARE_PATH ); +static void guc_fw_select (struct intel_uc_fw *guc_fw) { struct intel_guc *guc = container_of(guc_fw, struct intel_guc, fw);
@@ -72,6 +79,10 @@ static void guc_fw_select(struct intel_uc_fw *guc_fw) guc_fw->path = i915_modparams.guc_firmware_path; guc_fw->major_ver_wanted =0 ; guc_fw->minor_ver_wanted =0 ; + }else if (IS_GEMINILAKE (i915)) { + guc_fw->path =GLK_GUC_FIRMWARE_PATH ; + guc_fw->major_ver_wanted =GLK_GUC_FW_MAJOR ; + guc_fw->minor_ver_wanted =GLK_GUC_FW_MINOR ; }else if (IS_KABYLAKE (i915) ||IS_COFFEELAKE (i915)) { guc_fw->path =KBL_GUC_FIRMWARE_PATH ; guc_fw->major_ver_wanted =KBL_GUC_FW_MAJOR ;
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 7/17 drm/i915/huc: Define HuC firmware version for Geminilake
In reply to Michal WajdeczkoDefine HuC firmware version for Geminilake.
--- drivers/gpu/drm/i915/intel_huc_fw.c | 12 ++++++++++++ 1 file changed, 12 insertions(+)
drivers/gpu/drm/i915/intel_huc_fw.c +12 -0
@@ -34,6 +34,10 @@#define KBL_HUC_FW_MINOR 00#define KBL_BLD_NUM 1810 +#define GLK_HUC_FW_MAJOR 03 +#define GLK_HUC_FW_MINOR 01 +#define GLK_BLD_NUM 2893 +#define HUC_FW_PATH (platform, major, minor, bld_num) \ "i915/" __stringify(platform) "_huc_ver" __stringify(major) "_" \ __stringify(minor) "_" __stringify(bld_num) ".bin"
@@ -50,6 +54,10 @@ MODULE_FIRMWARE(I915_BXT_HUC_UCODE); KBL_HUC_FW_MINOR, KBL_BLD_NUM)MODULE_FIRMWARE (I915_KBL_HUC_UCODE ); +#define I915_GLK_HUC_UCODE HUC_FW_PATH(glk, GLK_HUC_FW_MAJOR, \ + GLK_HUC_FW_MINOR, GLK_BLD_NUM) +MODULE_FIRMWARE (I915_GLK_HUC_UCODE ); +static void huc_fw_select (struct intel_uc_fw *huc_fw) { struct intel_huc *huc = container_of(huc_fw, struct intel_huc, fw);
@@ -76,6 +84,10 @@ static void huc_fw_select(struct intel_uc_fw *huc_fw) huc_fw->path =I915_KBL_HUC_UCODE ; huc_fw->major_ver_wanted =KBL_HUC_FW_MAJOR ; huc_fw->minor_ver_wanted =KBL_HUC_FW_MINOR ; + }else if (IS_GEMINILAKE (dev_priv)) { + huc_fw->path =I915_GLK_HUC_UCODE ; + huc_fw->major_ver_wanted =GLK_HUC_FW_MAJOR ; + huc_fw->minor_ver_wanted =GLK_HUC_FW_MINOR ; } }
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 8/17 drm/i915/guc: New GuC interrupt register for Gen11
In reply to Michal WajdeczkoGen11 defines new more flexible Host-to-GuC interrupt register. Now the host can write any 32-bit payload to trigger an interrupt and GuC can additionally read this payload from the register. Current GuC firmware ignores the payload so we just write 0.
Bspec: 21043
--- drivers/gpu/drm/i915/intel_guc.c | 14 +++++++++++++- drivers/gpu/drm/i915/intel_guc_reg.h | 1 + 2 files changed, 14 insertions(+), 1 deletion(-)
drivers/gpu/drm/i915/intel_guc.c +13 -1
@@ -34,6 +34,13 @@ static void gen8_guc_raise_irq(struct intel_guc *guc)I915_WRITE (GUC_SEND_INTERRUPT ,GUC_SEND_TRIGGER ); } +static void gen11_guc_raise_irq (struct intel_guc *guc) +{ +struct drm_i915_private *dev_priv =guc_to_i915 (guc); + +I915_WRITE (GEN11_GUC_HOST_INTERRUPT ,0 ); +} +static inline i915_reg_t guc_send_reg (struct intel_guc *guc,u32 i) {GEM_BUG_ON (!guc->send_regs.base);
@@ -63,6 +70,8 @@ void intel_guc_init_send_regs(struct intel_guc *guc)void intel_guc_init_early (struct intel_guc *guc) { +struct drm_i915_private *i915 =guc_to_i915 (guc); +intel_guc_fw_init_early (guc);intel_guc_ct_init_early (&guc->ct);intel_guc_log_init_early (&guc->log);
@@ -71,7 +80,10 @@ void intel_guc_init_early(struct intel_guc *guc)spin_lock_init (&guc->irq_lock); guc->send = intel_guc_send_nop; guc->handler = intel_guc_to_host_event_handler_nop; - guc->notify = gen8_guc_raise_irq; +if (INTEL_GEN (i915) >=11 ) + guc->notify = gen11_guc_raise_irq; +else + guc->notify = gen8_guc_raise_irq; }static int guc_init_wq (struct intel_guc *guc)
drivers/gpu/drm/i915/intel_guc_reg.h +1 -0
@@ -103,6 +103,7 @@#define GUC_SEND_INTERRUPT _MMIO(0xc4c8)#define GUC_SEND_TRIGGER (1<<0) +#define GEN11_GUC_HOST_INTERRUPT _MMIO(0x1901f0)#define GUC_NUM_DOORBELLS 256
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 9/17 drm/i915/guc: New GuC scratch registers for Gen11
In reply to Michal WajdeczkoGen11 adds new set of scratch registers that can be used for MMIO based Host-to-Guc communication. Due to limited number of these registers it is expected that host will use them only for command transport buffers (CTB) communication setup if one is available.
Bspec: 21044
--- drivers/gpu/drm/i915/intel_guc.c | 12 +++++++++--- drivers/gpu/drm/i915/intel_guc_reg.h | 3 +++ 2 files changed, 12 insertions(+), 3 deletions(-)
drivers/gpu/drm/i915/intel_guc.c +9 -3
@@ -56,9 +56,15 @@ void intel_guc_init_send_regs(struct intel_guc *guc)enum forcewake_domains fw_domains =0 ;unsigned int i; - guc->send_regs.base =i915_mmio_reg_offset (SOFT_SCRATCH (0 )); - guc->send_regs.count =GUC_MAX_MMIO_MSG_LEN ; -BUILD_BUG_ON (GUC_MAX_MMIO_MSG_LEN >SOFT_SCRATCH_COUNT ); +if (HAS_GUC_CT (dev_priv) &&INTEL_GEN (dev_priv) >=11 ) { + guc->send_regs.base = +i915_mmio_reg_offset (GEN11_SOFT_SCRATCH (0 )); + guc->send_regs.count =GEN11_SOFT_SCRATCH_COUNT ; + }else { + guc->send_regs.base =i915_mmio_reg_offset (SOFT_SCRATCH (0 )); + guc->send_regs.count =GUC_MAX_MMIO_MSG_LEN ; +BUILD_BUG_ON (GUC_MAX_MMIO_MSG_LEN >SOFT_SCRATCH_COUNT ); + }for (i =0 ; i < guc->send_regs.count; i++) { fw_domains |= intel_uncore_forcewake_for_reg(&dev_priv->uncore,
drivers/gpu/drm/i915/intel_guc_reg.h +3 -0
@@ -51,6 +51,9 @@#define SOFT_SCRATCH (n) _MMIO(0xc180 + (n) * 4)#define SOFT_SCRATCH_COUNT 16 +#define GEN11_SOFT_SCRATCH (n) _MMIO(0x190240 + (n) * 4) +#define GEN11_SOFT_SCRATCH_COUNT 4 +#define UOS_RSA_SCRATCH (i) _MMIO(0xc200 + (i) * 4)#define UOS_RSA_SCRATCH_COUNT 64
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 10/17 drm/i915/huc: New HuC status register for Gen11
In reply to Michal WajdeczkoGen11 defines new register for checking HuC authentication status. Look into the right register and bit.
v2: use reg/mask/value instead of dedicated functions (Daniele)
BSpec: 19686
--- drivers/gpu/drm/i915/intel_guc_reg.h | 3 +++ drivers/gpu/drm/i915/intel_huc.c | 26 +++++++++++++++++++------- drivers/gpu/drm/i915/intel_huc.h | 7 +++++++ 3 files changed, 29 insertions(+), 7 deletions(-)
drivers/gpu/drm/i915/intel_guc_reg.h +3 -0
@@ -79,6 +79,9 @@#define HUC_STATUS2 _MMIO(0xD3B0)#define HUC_FW_VERIFIED (1<<7) +#define GEN11_HUC_KERNEL_LOAD_INFO _MMIO(0xC1DC) +#define HUC_LOAD_SUCCESSFUL (1 << 0) +#define GUC_WOPCM_SIZE _MMIO(0xc050)#define GUC_WOPCM_SIZE_LOCKED (1<<0)#define GUC_WOPCM_SIZE_SHIFT 12
drivers/gpu/drm/i915/intel_huc.c +19 -7
@@ -29,7 +29,19 @@void intel_huc_init_early (struct intel_huc *huc) { +struct drm_i915_private *i915 =huc_to_i915 (huc); +intel_huc_fw_init_early (huc); + +if (INTEL_GEN (i915) >=11 ) { + huc->status.reg =GEN11_HUC_KERNEL_LOAD_INFO ; + huc->status.mask =HUC_LOAD_SUCCESSFUL ; + huc->status.value =HUC_LOAD_SUCCESSFUL ; + }else { + huc->status.reg =HUC_STATUS2 ; + huc->status.mask =HUC_FW_VERIFIED ; + huc->status.value =HUC_FW_VERIFIED ; + } }int intel_huc_init_misc (struct intel_huc *huc)
@@ -110,7 +122,6 @@ int intel_huc_auth(struct intel_huc *huc) {struct drm_i915_private *i915 =huc_to_i915 (huc);struct intel_guc *guc = &i915->guc; -u32 status;int ret;if (huc->fw.load_status !=INTEL_UC_FIRMWARE_SUCCESS )
@@ -125,12 +136,12 @@ int intel_huc_auth(struct intel_huc *huc)/* Check authentication status, it should be done by now */ ret =__intel_wait_for_register (&i915->uncore, -HUC_STATUS2 , -HUC_FW_VERIFIED , -HUC_FW_VERIFIED , -2 ,50 , &status); + huc->status.reg, + huc->status.mask, + huc->status.value, +2 ,50 ,NULL );if (ret) { -DRM_ERROR ("HuC: Firmware not verified %#x\n" , status); +DRM_ERROR ("HuC: Firmware not verified %d\n" , ret); goto fail; }
@@ -164,7 +175,8 @@ int intel_huc_check_status(struct intel_huc *huc)return -ENODEV ;with_intel_runtime_pm (dev_priv, wakeref) - status = I915_READ(HUC_STATUS2) & HUC_FW_VERIFIED; + status = (I915_READ(huc->status.reg) & huc->status.mask) == + huc->status.value;return status; }
drivers/gpu/drm/i915/intel_huc.h +7 -0
@@ -25,6 +25,7 @@#ifndef _INTEL_HUC_H_#define _INTEL_HUC_H_ +#include "i915_reg.h" #include "intel_uc_fw.h" #include "intel_huc_fw.h"
@@ -35,6 +36,12 @@ struct intel_huc {/* HuC-specific additions */ struct i915_vma *rsa_data;void *rsa_data_vaddr; + +struct { +i915_reg_t reg; +u32 mask; +u32 value; + } status; };void intel_huc_init_early (struct intel_huc *huc);
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 11/17 drm/i915/guc: Create vfuncs for the GuC interrupts control functions
In reply to Michal WajdeczkoFrom: Oscar Mateo <[email protected]>
Controlling and handling of the GuC interrupts is Gen specific. Create virtual functions to avoid redundant runtime Gen checks. Gen-specific versions of these functions will follow.
v2: move vfuncs to struct guc (Daniele)
v3: rebased
--- drivers/gpu/drm/i915/i915_irq.c | 6 +++--- drivers/gpu/drm/i915/intel_guc.c | 8 ++++++-- drivers/gpu/drm/i915/intel_guc.h | 8 +++++++- drivers/gpu/drm/i915/intel_uc.c | 21 ++++++++++++++++++--- 4 files changed, 34 insertions(+), 9 deletions(-)
drivers/gpu/drm/i915/i915_irq.c +3 -3
@@ -600,10 +600,10 @@ void gen9_enable_guc_interrupts(struct drm_i915_private *dev_priv)assert_rpm_wakelock_held (dev_priv);spin_lock_irq (&dev_priv->irq_lock); -if (!dev_priv->guc.interrupts_enabled) { +if (!dev_priv->guc.interrupts.enabled) {WARN_ON_ONCE (I915_READ (gen6_pm_iir (dev_priv)) & dev_priv->pm_guc_events); - dev_priv->guc.interrupts_enabled = true; + dev_priv->guc.interrupts.enabled = true;gen6_enable_pm_irq (dev_priv, dev_priv->pm_guc_events); }spin_unlock_irq (&dev_priv->irq_lock);
@@ -614,7 +614,7 @@ void gen9_disable_guc_interrupts(struct drm_i915_private *dev_priv)assert_rpm_wakelock_held (dev_priv);spin_lock_irq (&dev_priv->irq_lock); - dev_priv->guc.interrupts_enabled = false; + dev_priv->guc.interrupts.enabled = false;gen6_disable_pm_irq (dev_priv, dev_priv->pm_guc_events);
drivers/gpu/drm/i915/intel_guc.c +6 -2
@@ -86,10 +86,14 @@ void intel_guc_init_early(struct intel_guc *guc)spin_lock_init (&guc->irq_lock); guc->send = intel_guc_send_nop; guc->handler = intel_guc_to_host_event_handler_nop; -if (INTEL_GEN (i915) >=11 ) +if (INTEL_GEN (i915) >=11 ) { guc->notify = gen11_guc_raise_irq; -else + }else { guc->notify = gen8_guc_raise_irq; + guc->interrupts.reset = gen9_reset_guc_interrupts; + guc->interrupts.enable = gen9_enable_guc_interrupts; + guc->interrupts.disable = gen9_disable_guc_interrupts; + } }static int guc_init_wq (struct intel_guc *guc)
drivers/gpu/drm/i915/intel_guc.h +7 -1
@@ -55,9 +55,15 @@ struct intel_guc {/* intel_guc_recv interrupt related state */ spinlock_t irq_lock; -bool interrupts_enabled;unsigned int msg_enabled_mask; +struct { +bool enabled; +void (*reset)(struct drm_i915_private *i915); +void (*enable)(struct drm_i915_private *i915); +void (*disable)(struct drm_i915_private *i915); + } interrupts; +struct i915_vma *ads_vma;struct i915_vma *stage_desc_pool;void *stage_desc_pool_vaddr;
drivers/gpu/drm/i915/intel_uc.c +18 -3
@@ -218,11 +218,26 @@ static void guc_free_load_err_log(struct intel_guc *guc)i915_gem_object_put (guc->load_err_log); } +static void guc_reset_interrupts (struct intel_guc *guc) +{ + guc->interrupts.reset (guc_to_i915 (guc)); +} + +static void guc_enable_interrupts (struct intel_guc *guc) +{ + guc->interrupts.enable (guc_to_i915 (guc)); +} + +static void guc_disable_interrupts (struct intel_guc *guc) +{ + guc->interrupts.disable (guc_to_i915 (guc)); +} +static int guc_enable_communication (struct intel_guc *guc) {struct drm_i915_private *i915 =guc_to_i915 (guc); -gen9_enable_guc_interrupts (i915); +guc_enable_interrupts (guc);if (HAS_GUC_CT (i915))return intel_guc_ct_enable (&guc->ct);
@@ -250,7 +265,7 @@ static void guc_disable_communication(struct intel_guc *guc)if (HAS_GUC_CT (i915))intel_guc_ct_disable (&guc->ct); -gen9_disable_guc_interrupts (i915); +guc_disable_interrupts (guc); guc->send = intel_guc_send_nop; guc->handler = intel_guc_to_host_event_handler_nop;
@@ -391,7 +406,7 @@ int intel_uc_init_hw(struct drm_i915_private *i915)GEM_BUG_ON (!HAS_GUC (i915)); -gen9_reset_guc_interrupts (i915); +guc_reset_interrupts (guc);/* WaEnableuKernelHeaderValidFix:skl */ /* WaEnableGuCBootHashCheckNotSet:skl,bxt,kbl */
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 12/17 drm/i915/guc: Correctly handle GuC interrupts on Gen11
In reply to Michal WajdeczkoFrom: Oscar Mateo <[email protected]>
Starting Gen11 GuC shares interrupt registers with SG unit instead of PM. But for now we don't care about SG interrupts.
v2: (Chris)
v3: rebased (Michal)
v4: more bspec pages, use macros, update commit msg (Michal Wi)
Bspec: 19820, 19840, 19841, 20176
--- drivers/gpu/drm/i915/i915_irq.c | 53 +++++++++++++++++++++++++++- drivers/gpu/drm/i915/i915_irq.h | 3 ++ drivers/gpu/drm/i915/i915_reg.h | 4 +++ drivers/gpu/drm/i915/intel_guc.c | 3 ++ drivers/gpu/drm/i915/intel_guc_reg.h | 18 ++++++++++ 5 files changed, 80 insertions(+), 1 deletion(-)
drivers/gpu/drm/i915/i915_irq.c +52 -1
@@ -624,6 +624,42 @@ void gen9_disable_guc_interrupts(struct drm_i915_private *dev_priv)gen9_reset_guc_interrupts (dev_priv); } +void gen11_reset_guc_interrupts (struct drm_i915_private *i915) +{ +spin_lock_irq (&i915->irq_lock); +gen11_reset_one_iir (i915,0 ,GEN11_GUC ); +spin_unlock_irq (&i915->irq_lock); +} + +void gen11_enable_guc_interrupts (struct drm_i915_private *dev_priv) +{ +spin_lock_irq (&dev_priv->irq_lock); +if (!dev_priv->guc.interrupts.enabled) { +u32 events =REG_FIELD_PREP (ENGINE1_MASK , +GEN11_GUC_INTR_GUC2HOST ); + +WARN_ON_ONCE (gen11_reset_one_iir (dev_priv,0 ,GEN11_GUC )); +I915_WRITE (GEN11_GUC_SG_INTR_ENABLE , events); +I915_WRITE (GEN11_GUC_SG_INTR_MASK , ~events); + dev_priv->guc.interrupts.enabled = true; + } +spin_unlock_irq (&dev_priv->irq_lock); +} + +void gen11_disable_guc_interrupts (struct drm_i915_private *dev_priv) +{ +spin_lock_irq (&dev_priv->irq_lock); + dev_priv->guc.interrupts.enabled = false; + +I915_WRITE (GEN11_GUC_SG_INTR_MASK , ~0 ); +I915_WRITE (GEN11_GUC_SG_INTR_ENABLE ,0 ); + +spin_unlock_irq (&dev_priv->irq_lock); +synchronize_irq (dev_priv->drm.irq); + +gen11_reset_guc_interrupts (dev_priv); +} +/** * bdw_update_port_irq - update DE port interrupt * @dev_priv: driver private
@@ -1893,6 +1929,12 @@ static void gen9_guc_irq_handler(struct drm_i915_private *dev_priv, u32 gt_iir)intel_guc_to_host_event_handler (&dev_priv->guc); } +static void gen11_guc_irq_handler (struct drm_i915_private *i915,u16 iir) +{ +if (iir &GEN11_GUC_INTR_GUC2HOST ) +intel_guc_to_host_event_handler (&i915->guc); +} +static void i9xx_pipestat_irq_reset (struct drm_i915_private *dev_priv) {enum pipe pipe;
@@ -3015,6 +3057,9 @@ static void gen11_other_irq_handler(struct drm_i915_private * const i915, const u8 instance, const u16 iir) { + if (instance == OTHER_GUC_INSTANCE) + return gen11_guc_irq_handler(i915, iir); +if (instance ==OTHER_GTPM_INSTANCE )return gen11_rps_irq_handler (i915, iir);
@@ -3545,6 +3590,8 @@ static void gen11_gt_irq_reset(struct drm_i915_private *dev_priv)I915_WRITE (GEN11_GPM_WGBOXPERF_INTR_ENABLE ,0 );I915_WRITE (GEN11_GPM_WGBOXPERF_INTR_MASK , ~0 ); +I915_WRITE (GEN11_GUC_SG_INTR_ENABLE ,0 ); +I915_WRITE (GEN11_GUC_SG_INTR_MASK , ~0 ); }static void gen11_irq_reset (struct drm_device *dev)
@@ -4200,6 +4247,10 @@ static void gen11_gt_irq_postinstall(struct drm_i915_private *dev_priv) dev_priv->pm_imr = ~dev_priv->pm_ier;I915_WRITE (GEN11_GPM_WGBOXPERF_INTR_ENABLE ,0 );I915_WRITE (GEN11_GPM_WGBOXPERF_INTR_MASK , ~0 ); + +/* Same thing for GuC interrupts */ +I915_WRITE (GEN11_GUC_SG_INTR_ENABLE ,0 ); +I915_WRITE (GEN11_GUC_SG_INTR_MASK , ~0 ); }static void icp_irq_postinstall (struct drm_device *dev)
@@ -4707,7 +4758,7 @@ void intel_irq_init(struct drm_i915_private *dev_priv)for (i =0 ; i <MAX_L3_SLICES ; ++i) dev_priv->l3_parity.remap_info[i] =NULL ; -if (HAS_GUC_SCHED (dev_priv)) +if (HAS_GUC_SCHED (dev_priv) &&INTEL_GEN (dev_priv) <11 ) dev_priv->pm_guc_events =GEN9_GUC_TO_HOST_INT_EVENT ;/* Let's track the enabled rps events */
drivers/gpu/drm/i915/i915_irq.h +3 -0
@@ -110,5 +110,8 @@ void gen8_irq_power_well_pre_disable(struct drm_i915_private *dev_priv,void gen9_reset_guc_interrupts (struct drm_i915_private *dev_priv);void gen9_enable_guc_interrupts (struct drm_i915_private *dev_priv);void gen9_disable_guc_interrupts (struct drm_i915_private *dev_priv); +void gen11_reset_guc_interrupts (struct drm_i915_private *i915); +void gen11_enable_guc_interrupts (struct drm_i915_private *i915); +void gen11_disable_guc_interrupts (struct drm_i915_private *i915);#endif /* __I915_IRQ_H__ */
drivers/gpu/drm/i915/i915_reg.h +4 -0
@@ -290,6 +290,7 @@ static inline bool i915_mmio_reg_valid(i915_reg_t reg)#define OTHER_CLASS 4#define MAX_ENGINE_CLASS 4 +#define OTHER_GUC_INSTANCE 0#define OTHER_GTPM_INSTANCE 1#define MAX_ENGINE_INSTANCE 3
@@ -7493,6 +7494,9 @@ enum {#define GEN11_CRYPTO_RSVD_INTR_MASK _MMIO(0x1900f0)#define GEN11_GUNIT_CSME_INTR_MASK _MMIO(0x1900f4) +#define ENGINE1_MASK REG_GENMASK(31, 16) +#define ENGINE0_MASK REG_GENMASK(15, 0) +#define ILK_DISPLAY_CHICKEN2 _MMIO(0x42004)/* Required on all Ironlake and Sandybridge according to the B-Spec. */ #define ILK_ELPIN_409_SELECT (1 << 25)
drivers/gpu/drm/i915/intel_guc.c +3 -0
@@ -88,6 +88,9 @@ void intel_guc_init_early(struct intel_guc *guc) guc->handler = intel_guc_to_host_event_handler_nop;if (INTEL_GEN (i915) >=11 ) { guc->notify = gen11_guc_raise_irq; + guc->interrupts.reset = gen11_reset_guc_interrupts; + guc->interrupts.enable = gen11_enable_guc_interrupts; + guc->interrupts.disable = gen11_disable_guc_interrupts; }else { guc->notify = gen8_guc_raise_irq; guc->interrupts.reset = gen9_reset_guc_interrupts;
drivers/gpu/drm/i915/intel_guc_reg.h +18 -0
@@ -134,4 +134,22 @@ struct guc_doorbell_info {#define GUC_WD_VECS_IER _MMIO(0xC558)#define GUC_PM_P24C_IER _MMIO(0xC55C) +/* GuC Interrupt Vector */ +#define GEN11_GUC_INTR_GUC2HOST (1 << 15) +#define GEN11_GUC_INTR_EXEC_ERROR (1 << 14) +#define GEN11_GUC_INTR_DISPLAY_EVENT (1 << 13) +#define GEN11_GUC_INTR_SEM_SIG (1 << 12) +#define GEN11_GUC_INTR_IOMMU2GUC (1 << 11) +#define GEN11_GUC_INTR_DOORBELL_RANG (1 << 10) +#define GEN11_GUC_INTR_DMA_DONE (1 << 9) +#define GEN11_GUC_INTR_FATAL_ERROR (1 << 8) +#define GEN11_GUC_INTR_NOTIF_ERROR (1 << 7) +#define GEN11_GUC_INTR_SW_INT_6 (1 << 6) +#define GEN11_GUC_INTR_SW_INT_5 (1 << 5) +#define GEN11_GUC_INTR_SW_INT_4 (1 << 4) +#define GEN11_GUC_INTR_SW_INT_3 (1 << 3) +#define GEN11_GUC_INTR_SW_INT_2 (1 << 2) +#define GEN11_GUC_INTR_SW_INT_1 (1 << 1) +#define GEN11_GUC_INTR_SW_INT_0 (1 << 0) +#endif
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 13/17 drm/i915/guc: Update GuC CTB response definition
In reply to Michal WajdeczkoCurrent GuC firmwares identify response message in a different way.
v2: update comments for other H2G bits (Daniele)
--- drivers/gpu/drm/i915/intel_guc_ct.c | 2 +- drivers/gpu/drm/i915/intel_guc_fwif.h | 8 +++++--- 2 files changed, 6 insertions(+), 4 deletions(-)
drivers/gpu/drm/i915/intel_guc_ct.c +1 -1
@@ -565,7 +565,7 @@ static inline unsigned int ct_header_get_action(u32 header)static inline bool ct_header_is_response (u32 header) { -return ct_header_get_action (header) ==INTEL_GUC_ACTION_DEFAULT ; +return !!(header &GUC_CT_MSG_IS_RESPONSE ); }static int ctb_read (struct intel_guc_ct_buffer *ctb,u32 *data)
drivers/gpu/drm/i915/intel_guc_fwif.h +5 -3
@@ -355,14 +355,16 @@ struct guc_ct_buffer_desc {* * bit[4..0] message len (in dwords) * bit[7..5] reserved -* bit[8] write fence to desc -* bit[9] write status to H2G buff -* bit[10] send status (via G2H) +* bit[8] response (G2H only) +* bit[8] write fence to desc (H2G only) +* bit[9] write status to H2G buff (H2G only) +* bit[10] send status back via G2H (H2G only) * bit[15..11] reserved * bit[31..16] action code */ #define GUC_CT_MSG_LEN_SHIFT 0#define GUC_CT_MSG_LEN_MASK 0x1F +#define GUC_CT_MSG_IS_RESPONSE (1 << 8)#define GUC_CT_MSG_WRITE_FENCE_TO_DESC (1 << 8)#define GUC_CT_MSG_WRITE_STATUS_TO_BUFF (1 << 9)#define GUC_CT_MSG_SEND_STATUS (1 << 10)
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 14/17 drm/i915/guc: Enable GuC CTB communication on Gen11
In reply to Michal WajdeczkoGen11 GuC firmware expects H2G command messages to be sent over CTB (command transport buffers).
--- drivers/gpu/drm/i915/i915_pci.c | 1 + 1 file changed, 1 insertion(+)
drivers/gpu/drm/i915/i915_pci.c +1 -0
@@ -746,6 +746,7 @@ static const struct intel_device_info intel_cannonlake_info = { }, \ GEN(11), \ .ddb_size = 2048, \ + .has_guc_ct = 1, \ .has_logical_ring_elsq = 1, \ .color = { .degamma_lut_size = 33, .gamma_lut_size = 1024 }
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 15/17 drm/i915/guc: Define GuC firmware version for Icelake
In reply to Michal WajdeczkoDefine GuC firmware version for Icelake.
--- drivers/gpu/drm/i915/intel_guc_fw.c | 11 +++++++++++ 1 file changed, 11 insertions(+)
drivers/gpu/drm/i915/intel_guc_fw.c +11 -0
@@ -65,6 +65,13 @@ MODULE_FIRMWARE(KBL_GUC_FIRMWARE_PATH);#define GLK_GUC_FIRMWARE_PATH __MAKE_GUC_FW_PATH(GLK)MODULE_FIRMWARE (GLK_GUC_FIRMWARE_PATH ); +#define ICL_GUC_FW_PREFIX icl +#define ICL_GUC_FW_MAJOR 32 +#define ICL_GUC_FW_MINOR 0 +#define ICL_GUC_FW_PATCH 3 +#define ICL_GUC_FIRMWARE_PATH __MAKE_GUC_FW_PATH(ICL) +MODULE_FIRMWARE (ICL_GUC_FIRMWARE_PATH ); +static void guc_fw_select (struct intel_uc_fw *guc_fw) { struct intel_guc *guc = container_of(guc_fw, struct intel_guc, fw);
@@ -79,6 +86,10 @@ static void guc_fw_select(struct intel_uc_fw *guc_fw) guc_fw->path = i915_modparams.guc_firmware_path; guc_fw->major_ver_wanted =0 ; guc_fw->minor_ver_wanted =0 ; + }else if (IS_ICELAKE (i915)) { + guc_fw->path =ICL_GUC_FIRMWARE_PATH ; + guc_fw->major_ver_wanted =ICL_GUC_FW_MAJOR ; + guc_fw->minor_ver_wanted =ICL_GUC_FW_MINOR ; }else if (IS_GEMINILAKE (i915)) { guc_fw->path =GLK_GUC_FIRMWARE_PATH ; guc_fw->major_ver_wanted =GLK_GUC_FW_MAJOR ;
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 16/17 drm/i915/huc: Define HuC firmware version for Icelake
In reply to Michal WajdeczkoDefine HuC firmware version for Icelake.
v2: 8.4.3238 is now available
--- drivers/gpu/drm/i915/intel_huc_fw.c | 12 ++++++++++++ 1 file changed, 12 insertions(+)
drivers/gpu/drm/i915/intel_huc_fw.c +12 -0
@@ -38,6 +38,10 @@#define GLK_HUC_FW_MINOR 01#define GLK_BLD_NUM 2893 +#define ICL_HUC_FW_MAJOR 8 +#define ICL_HUC_FW_MINOR 4 +#define ICL_BLD_NUM 3238 +#define HUC_FW_PATH (platform, major, minor, bld_num) \ "i915/" __stringify(platform) "_huc_ver" __stringify(major) "_" \ __stringify(minor) "_" __stringify(bld_num) ".bin"
@@ -58,6 +62,10 @@ MODULE_FIRMWARE(I915_KBL_HUC_UCODE); GLK_HUC_FW_MINOR, GLK_BLD_NUM)MODULE_FIRMWARE (I915_GLK_HUC_UCODE ); +#define I915_ICL_HUC_UCODE HUC_FW_PATH(icl, ICL_HUC_FW_MAJOR, \ + ICL_HUC_FW_MINOR, ICL_BLD_NUM) +MODULE_FIRMWARE (I915_ICL_HUC_UCODE ); +static void huc_fw_select (struct intel_uc_fw *huc_fw) { struct intel_huc *huc = container_of(huc_fw, struct intel_huc, fw);
@@ -88,6 +96,10 @@ static void huc_fw_select(struct intel_uc_fw *huc_fw) huc_fw->path =I915_GLK_HUC_UCODE ; huc_fw->major_ver_wanted =GLK_HUC_FW_MAJOR ; huc_fw->minor_ver_wanted =GLK_HUC_FW_MINOR ; + }else if (IS_ICELAKE (dev_priv)) { + huc_fw->path =I915_ICL_HUC_UCODE ; + huc_fw->major_ver_wanted =ICL_HUC_FW_MAJOR ; + huc_fw->minor_ver_wanted =ICL_HUC_FW_MINOR ; } }
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v5 17/17 HAX: Turn on GuC/HuC auto mode
In reply to Michal WajdeczkoRun GuC, run!
--- drivers/gpu/drm/i915/i915_params.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/i915/i915_params.h +1 -1
@@ -54,7 +54,7 @@ struct drm_printer; param(int, disable_power_well, -1) \ param(int, enable_ips, 1) \ param(int, invert_brightness, 0) \ - param(int, enable_guc, 0) \ + param(int, enable_guc, -1) \ param(int, guc_log_level, -1) \ param(char *, guc_firmware_path, NULL) \param (char *, huc_firmware_path, NULL) \
Signature · 6 lines
2.19.2 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Patchwork
CI✗ Fi.CI.BAT: failure for GuC 32.0.3 (rev6)
In reply to Michal Wajdeczko== Series Details ==
== Series Details ==
Series: GuC 32.0.3 (rev6)
URL : https://patchwork.freedesktop.org/series/58760/
State : failure
== Summary ==
CI Bug Log - changes from CI_DRM_6150 -> Patchwork_13108
====================================================
Summary
-------
**FAILURE**
Serious unknown changes coming with Patchwork_13108 absolutely need to be verified manually.
If you think the reported changes have nothing to do with the changes introduced in Patchwork_13108, please notify your bug team to allow them to document this new failure mode, which will reduce false positives in CI.
External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/
Possible new issues
-------------------
Here are the unknown changes that may have been introduced in Patchwork_13108:
### IGT changes ###
#### Possible regressions ####
* igt@i915_selftest@live_hangcheck:
- fi-icl-u3: [PASS][1] -> [DMESG-FAIL][2]
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-icl-u3/igt@i915_selftest@live_hangcheck.html
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-icl-u3/igt@i915_selftest@live_hangcheck.html
* igt@i915_selftest@live_workarounds:
- fi-icl-y: [PASS][3] -> [DMESG-FAIL][4] +1 similar issue
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-icl-y/igt@i915_selftest@live_workarounds.html
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-icl-y/igt@i915_selftest@live_workarounds.html
Known issues
------------
Here are the changes found in Patchwork_13108 that come from known issues:
### IGT changes ###
#### Issues hit ####
* igt@gem_exec_suspend@basic-s3:
- fi-skl-6260u: [PASS][5] -> [INCOMPLETE][6] ([fdo#104108])
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-skl-6260u/igt@[email protected]
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-skl-6260u/igt@[email protected]
* igt@i915_selftest@live_contexts:
- fi-bdw-gvtdvm: [PASS][7] -> [DMESG-FAIL][8] ([fdo#110235])
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-bdw-gvtdvm/igt@i915_selftest@live_contexts.html
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-bdw-gvtdvm/igt@i915_selftest@live_contexts.html
* igt@kms_chamelium@hdmi-hpd-fast:
- fi-kbl-7500u: [PASS][9] -> [FAIL][10] ([fdo#109485])
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-kbl-7500u/igt@[email protected]
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-kbl-7500u/igt@[email protected]
* igt@prime_vgem@basic-fence-flip:
- fi-ilk-650: [PASS][11] -> [DMESG-WARN][12] ([fdo#106387]) +1 similar issue
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-ilk-650/igt@[email protected]
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-ilk-650/igt@[email protected]
#### Possible fixes ####
* igt@gem_exec_suspend@basic-s3:
- fi-apl-guc: [DMESG-WARN][13] ([fdo#110512]) -> [PASS][14]
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-apl-guc/igt@[email protected]
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-apl-guc/igt@[email protected]
* igt@i915_module_load@reload:
- fi-apl-guc: [DMESG-WARN][15] ([fdo#110755]) -> [PASS][16]
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-apl-guc/igt@[email protected]
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-apl-guc/igt@[email protected]
* igt@i915_selftest@live_evict:
- fi-bsw-kefka: [DMESG-WARN][17] ([fdo#107709]) -> [PASS][18]
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-bsw-kefka/igt@i915_selftest@live_evict.html
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-bsw-kefka/igt@i915_selftest@live_evict.html
* igt@i915_selftest@live_hangcheck:
- fi-skl-iommu: [INCOMPLETE][19] ([fdo#108602] / [fdo#108744]) -> [PASS][20]
[19]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-skl-iommu/igt@i915_selftest@live_hangcheck.html
[20]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-skl-iommu/igt@i915_selftest@live_hangcheck.html
* igt@kms_frontbuffer_tracking@basic:
- fi-icl-u3: [FAIL][21] ([fdo#103167]) -> [PASS][22]
[21]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-icl-u3/igt@[email protected]
[22]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-icl-u3/igt@[email protected]
- fi-icl-u2: [FAIL][23] ([fdo#103167]) -> [PASS][24]
[23]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-icl-u2/igt@[email protected]
[24]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-icl-u2/igt@[email protected]
* igt@kms_pipe_crc_basic@nonblocking-crc-pipe-a-frame-sequence:
- fi-icl-u3: [DMESG-WARN][25] ([fdo#107724]) -> [PASS][26] +1 similar issue
[25]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6150/fi-icl-u3/igt@[email protected]
[26]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/fi-icl-u3/igt@[email protected]
{name}: This element is suppressed. This means it is ignored when computing
the status of the difference (SUCCESS, WARNING, or FAILURE).
[fdo#103167]: https://bugs.freedesktop.org/show_bug.cgi?id=103167
[fdo#104108]: https://bugs.freedesktop.org/show_bug.cgi?id=104108
[fdo#106387]: https://bugs.freedesktop.org/show_bug.cgi?id=106387
[fdo#107709]: https://bugs.freedesktop.org/show_bug.cgi?id=107709
[fdo#107713]: https://bugs.freedesktop.org/show_bug.cgi?id=107713
[fdo#107724]: https://bugs.freedesktop.org/show_bug.cgi?id=107724
[fdo#108602]: https://bugs.freedesktop.org/show_bug.cgi?id=108602
[fdo#108744]: https://bugs.freedesktop.org/show_bug.cgi?id=108744
[fdo#109485]: https://bugs.freedesktop.org/show_bug.cgi?id=109485
[fdo#110235]: https://bugs.freedesktop.org/show_bug.cgi?id=110235
[fdo#110512]: https://bugs.freedesktop.org/show_bug.cgi?id=110512
[fdo#110755]: https://bugs.freedesktop.org/show_bug.cgi?id=110755
Participating hosts (53 -> 47)
------------------------------
Additional (1): fi-icl-guc
Missing (7): fi-kbl-soraka fi-ilk-m540 fi-hsw-4200u fi-byt-squawks fi-bsw-cyan fi-byt-clapper fi-bdw-samus
Build changes
-------------
* Linux: CI_DRM_6150 -> Patchwork_13108
CI_DRM_6150: 7379742ac3103554d9e13c598a0c8ed12cf8a81d @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_5017: 2892adce93fb8eea3d764dc0f766a202d9dcef37 @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
Patchwork_13108: 04f803a6287b9e536e268d4e20bce1cb7d056951 @ git://anongit.freedesktop.org/gfx-ci/linux
== Linux commits ==
04f803a6287b HAX: Turn on GuC/HuC auto modebf450194e542 drm/i915/huc: Define HuC firmware version for Icelake a6b82998cdac drm/i915/guc: Define GuC firmware version for Icelake 4ce4f9b0e23d drm/i915/guc: Enable GuC CTB communication on Gen11 678e71ed9bcf drm/i915/guc: Update GuC CTB response definition 751ae68437c5 drm/i915/guc: Correctly handle GuC interrupts on Gen11 180c85104485 drm/i915/guc: Create vfuncs for the GuC interrupts control functions a79511639129 drm/i915/huc: New HuC status register for Gen11 81ce0051f918 drm/i915/guc: New GuC scratch registers for Gen11 689b1d331a8b drm/i915/guc: New GuC interrupt register for Gen11 17bba4cfd465 drm/i915/huc: Define HuC firmware version for Geminilake 26845d5489c2 drm/i915/guc: Define GuC firmware version for Geminilake 121c5772a935 drm/i915/guc: Always ask GuC to update power domain states f4c92a144f5b drm/i915/guc: Reset GuC ADS during sanitize dcff7c8cd80a drm/i915/guc: Updates for GuC 32.0.3 firmware 1f33770ed430 drm/i915/guc: Don't allow GuC submission92baa28af80f drm/i915/guc: Change platform default GuC mode
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13108/
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoting Michal Wajdeczko (2019-05-27 19:35:56)
Quoted 1 line
New GuC firmwares (for SKL, BXT, KBL, GLK, ICL) with updated ABI interface.
All reviewed/acked, and I trust the failures will be fixed in time, so pushed. Thanks.
-Chris
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 6 lines · Chris Wilson
Quoting Michal Wajdeczko (2019-05-27 19:35:56)
Quoted 1 line
New GuC firmwares (for SKL, BXT, KBL, GLK, ICL) with updated ABI interface.
All reviewed/acked, and I trust the failures will be fixed in time, so pushed. Thanks.
-Chris
But without telling Martin to file cibuglog filters for known issues?
Signature · 5 lines
Petri Latvala _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoting Petri Latvala (2019-05-28 10:40:31)
Quoted 10 lines · Chris Wilson
Quoted 6 lines
Quoting Michal Wajdeczko (2019-05-27 19:35:56)
Quoted 1 line
New GuC firmwares (for SKL, BXT, KBL, GLK, ICL) with updated ABI interface.
All reviewed/acked, and I trust the failures will be fixed in time, so pushed. Thanks.
-ChrisBut without telling Martin to file cibuglog filters for known issues?
fi-icl-guc should remain suppressed.
fi-apl-guc should be retired.
-Chris
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 10 lines · Chris Wilson
Quoting Petri Latvala (2019-05-28 10:40:31)
Quoted 9 lines · Chris Wilson
Quoted 6 lines
Quoting Michal Wajdeczko (2019-05-27 19:35:56)
Quoted 1 line
New GuC firmwares (for SKL, BXT, KBL, GLK, ICL) with updated ABI interface.
All reviewed/acked, and I trust the failures will be fixed in time, so pushed. Thanks.
-Chris
Quoted 4 lines
Quoted 1 line
But without telling Martin to file cibuglog filters for known issues?
fi-icl-guc should remain suppressed.
fi-apl-guc should be retired.
This is something to be discussed *before* merging. I suppressed all the guc platforms (apl, cfl, icl, kbl, skl).
Let's hope that it does not affect the shards...
Martin
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Hi,
Quoted 18 lines
-----Original Message-----
From: Intel-gfx [mailto:[email protected]] On Behalf Of Chris Wilson
Sent: tiistai 28. toukokuuta 2019 12.46
To: Latvala, Petri <[email protected]>
Cc: [email protected]
Subject: Re: [Intel-gfx] [PATCH v5 00/17] GuC 32.0.3Quoting Petri Latvala (2019-05-28 10:40:31)
Quoted 9 lines · Chris Wilson
Quoted 6 lines
Quoting Michal Wajdeczko (2019-05-27 19:35:56)
Quoted 1 line
New GuC firmwares (for SKL, BXT, KBL, GLK, ICL) with updated ABI interface.
All reviewed/acked, and I trust the failures will be fixed in time, so pushed. Thanks.
-Chris
Quoted 4 lines
Quoted 1 line
But without telling Martin to file cibuglog filters for known issues?
fi-icl-guc should remain suppressed.
fi-apl-guc should be retired.
Meaning to get to without guc usage ?
Quoted 5 lines
-Chris
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx