GSC support for XeHP SDV and DG2
v8 cover GSC support for XeHP SDV and DG2
Add GSC support for XeHP SDV and DG2 platforms.
The series includes changes for the mei driver:
- add ability to use polling instead of interrupts
- add ability to use extended timeouts
- setup extended operational memory for GSC
The series includes changes for the i915 driver:
- allocate extended operational memory for GSC
- GSC on XeHP SDV offsets and definitions
This patch set should be merged via gfx tree as
the auxiliary device belongs there.
V2: rebase over merged DG1 series and DG2 enablement patch,
fix commit messages
V3: rebase over latest tip
V4: add missed changelog in pxp dbugfs patch
V5: rebase over latest tip
fix changelog in pxp dbugfs patch
put HAX patch last to the ease of merging
reorder patches in the series
V6: change prefix from 'drm/i915/gsc:' to 'mei' in patch:
mei: add slow_fw flag to the mei auxiliary device
Address following checkpatch warnings:
CHECK:PREFER_KERNEL_TYPES: Prefer kernel type 'u32' over 'uint32_t'
FILE: drivers/misc/mei/mkhi.h:54:
+ uint32_t flags;
-:51: CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around 'cldev->bus->pxp_mode != MEI_DEV_PXP_INIT'
#51: FILE: drivers/misc/mei/bus-fixup.c:257:
+ if (!cldev->bus->fw_f_fw_ver_supported &&
+ (cldev->bus->pxp_mode != MEI_DEV_PXP_INIT)
Remove some spurious code formatting changes in:
drm/i915/gsc: allocate extended operational memory in LMEMV7: Add new patch to add kdoc for mei_aux_device structure.
Rename slow_fw to slow_firmware flag.
Use drm_dbg/err() functions instead of dev_dbg/err() in i195 codebase.
V8:
1. Update copyright dates
1. Add kdoc and comments to mei_me_polling_thread()
2. Fix pgi->d0i3 timeout in mei_me_d0i3_enter_sync()
3. <linux/types.h> is enough for mkhi header.
4. drop MCHI_GROUP_ID definition it is not used
5. Setup default PXP state
6. Add PXP mode kdoc
7. Add new patch mei: drop ready bits check after start
Alexander Usyskin (5):
drm/i915/gsc: add slow_firmware flag to the gsc device definition drm/i915/gsc: add GSC XeHP SDV platform definition
mei: gsc: wait for reset thread on stop
mei: extend timeouts on slow devices.
mei: drop ready bits check after start
Daniele Ceraolo Spurio (1):
HAX: drm/i915: force INTEL_MEI_GSC on for CI
Tomas Winkler (7):
mei: add kdoc for struct mei_aux_device
mei: add slow_firmware flag to the mei auxiliary device
mei: gsc: use polling instead of interrupts
mei: mkhi: add memory ready command
mei: gsc: setup gsc extended operational memory
mei: debugfs: add pxp mode to devstate in debugfs drm/i915/gsc: allocate extended operational memory in LMEM
Vitaly Lubart (3):
drm/i915/gsc: skip irq initialization if using polling
mei: bus: export common mkhi definitions into a separate header
mei: gsc: add transition to PXP mode in resume flow
drivers/gpu/drm/i915/Kconfig.debug | 1 + drivers/gpu/drm/i915/gt/intel_gsc.c | 118 ++++++++++++++++++++++-- drivers/gpu/drm/i915/gt/intel_gsc.h | 3 + drivers/misc/mei/bus-fixup.c | 106 ++++++++++++++------- drivers/misc/mei/client.c | 16 ++-- drivers/misc/mei/debugfs.c | 19 +++- drivers/misc/mei/gsc-me.c | 77 ++++++++++++++-- drivers/misc/mei/hbm.c | 14 +-- drivers/misc/mei/hw-me-regs.h | 9 +- drivers/misc/mei/hw-me.c | 138 ++++++++++++++++++++++++---- drivers/misc/mei/hw-me.h | 17 +++- drivers/misc/mei/hw-txe.c | 4 +- drivers/misc/mei/hw.h | 7 +- drivers/misc/mei/init.c | 35 ++++--- drivers/misc/mei/main.c | 4 +- drivers/misc/mei/mei_dev.h | 35 ++++++- drivers/misc/mei/mkhi.h | 69 ++++++++++++++ drivers/misc/mei/pci-me.c | 4 +- include/linux/mei_aux.h | 12 +++ 19 files changed, 574 insertions(+), 114 deletions(-) create mode 100644 drivers/misc/mei/mkhi.h
Signature · 1 line
2.37.2
PATCH v8 1/16 drm/i915/gsc: skip irq initialization if using polling
From: Vitaly Lubart <[email protected]>
Some platforms require the host to poll on the GSC registers instead of relaying on the interrupts. For those platforms, irq initialization should be skipped
--- drivers/gpu/drm/i915/gt/intel_gsc.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)
drivers/gpu/drm/i915/gt/intel_gsc.c +7 -3
@@ -40,6 +40,7 @@ struct gsc_def {const char *name;unsigned long bar;size_t bar_size; +bool use_polling; };/* gsc resources and definitions (HECI1 and HECI2) */
@@ -117,6 +118,10 @@ static void gsc_init_one(struct drm_i915_private *i915,return ; } +/* skip irq initialization */ +if (def->use_polling) + goto add_device; + intf->irq =irq_alloc_desc (0 );if (intf->irq <0 ) {drm_err (&i915->drm,"gsc irq error %d\n" , intf->irq);
@@ -129,6 +134,7 @@ static void gsc_init_one(struct drm_i915_private *i915, goto fail; } +add_device: adev =kzalloc (sizeof (*adev),GFP_KERNEL );if (!adev) goto fail;
@@ -182,10 +188,8 @@ static void gsc_irq_handler(struct intel_gt *gt, unsigned int intf_id)return ; } -if (gt->gsc.intf[intf_id].irq <0 ) { -drm_err_ratelimited (>->i915->drm,"GSC irq: irq not set" ); +if (gt->gsc.intf[intf_id].irq <0 )return ; - } ret =generic_handle_irq (gt->gsc.intf[intf_id].irq);if (ret)
Signature · 1 line
2.37.2
PATCH v8 2/16 mei: add kdoc for struct mei_aux_device
In reply to Tomas Winklerstruct mei_aux_device is an interface structure
requires proper documenation.
--- include/linux/mei_aux.h | 6 ++++++ 1 file changed, 6 insertions(+)
include/linux/mei_aux.h +6 -0
@@ -7,6 +7,12 @@#include <linux/auxiliary_bus.h> +/** +* struct mei_aux_device - mei auxiliary device +* @aux_dev: - auxiliary device object +* @irq: interrupt driving the mei auxiliary device +* @bar: mmio resource bar reserved to mei auxiliary device +*/ struct mei_aux_device {struct auxiliary_device aux_dev;int irq;
Signature · 1 line
2.37.2
Re: [Intel-gfx] [PATCH v8 02/16] mei: add kdoc for struct mei_aux_device
Quoted 4 lines · Tomas Winkler
struct
mei_aux_deviceis an interface structure
requires proper documenation.Signed-off-by Tomas Winkler <[email protected]>
This is unchanged from the previously reviewed rev, so this still applies:
Daniele
Quoted 21 lines
--- include/linux/mei_aux.h | 6 ++++++ 1 file changed, 6 insertions(+)include/linux/mei_aux.h +6
-0@@ -7,6 +7,12 @@#include <linux/auxiliary_bus.h> +/** +* struct mei_aux_device - mei auxiliary device +* @aux_dev: - auxiliary device object +* @irq: interrupt driving the mei auxiliary device +* @bar: mmio resource bar reserved to mei auxiliary device +*/ struct mei_aux_device {struct auxiliary_device aux_dev;int irq;
PATCH v8 3/16 mei: add slow_firmware flag to the mei auxiliary device
In reply to Tomas WinklerAdd slow_firmware flag to the mei auxiliary device info to inform the mei driver about slow underlying firmware. Such firmware will require to use larger operation timeouts.
--- include/linux/mei_aux.h | 3 +++ 1 file changed, 3 insertions(+)
include/linux/mei_aux.h +3 -0
@@ -12,11 +12,14 @@* @aux_dev: - auxiliary device object * @irq: interrupt driving the mei auxiliary device * @bar: mmio resource bar reserved to mei auxiliary device +* @slow_firmware: The device has slow underlying firmware. +* Such firmware will require to use larger operation timeouts. */ struct mei_aux_device {struct auxiliary_device aux_dev;int irq;struct resource bar; +bool slow_firmware; };#define auxiliary_dev_to_mei_aux_dev (auxiliary_dev) \
Signature · 1 line
2.37.2
PATCH v8 4/16 drm/i915/gsc: add slow_firmware flag to the gsc device definition
In reply to Tomas WinklerFrom: Alexander Usyskin <[email protected]>
Add slow_firmware flag to the gsc device definition and pass it to mei auxiliary device, this instructs the driver to use longer operation timeouts.
--- drivers/gpu/drm/i915/gt/intel_gsc.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/gpu/drm/i915/gt/intel_gsc.c +2 -0
@@ -41,6 +41,7 @@ struct gsc_def {unsigned long bar;size_t bar_size;bool use_polling; +bool slow_firmware; };/* gsc resources and definitions (HECI1 and HECI2) */
@@ -145,6 +146,7 @@ static void gsc_init_one(struct drm_i915_private *i915, adev->bar.end = adev->bar.start + def->bar_size -1 ; adev->bar.flags =IORESOURCE_MEM ; adev->bar.desc =IORES_DESC_NONE ; + adev->slow_firmware = def->slow_firmware; aux_dev = &adev->aux_dev; aux_dev->name = def->name;
Signature · 1 line
2.37.2
PATCH v8 5/16 drm/i915/gsc: add GSC XeHP SDV platform definition
In reply to Tomas WinklerFrom: Alexander Usyskin <[email protected]>
Define GSC on XeHP SDV (Intel(R) dGPU without display)
XeHP SDV uses the same hardware settings as DG1, but uses polling instead of interrupts and runs the firmware in slow pace due to hardware limitations.
--- drivers/gpu/drm/i915/gt/intel_gsc.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+)
drivers/gpu/drm/i915/gt/intel_gsc.c +15 -0
@@ -56,6 +56,19 @@ static const struct gsc_def gsc_def_dg1[] = { } }; +static const struct gsc_def gsc_def_xehpsdv[] = { + { +/* HECI1 not enabled on the device. */ + }, + { + .name ="mei-gscfi" , + .bar =DG1_GSC_HECI2_BASE , + .bar_size =GSC_BAR_LENGTH , + .use_polling = true, + .slow_firmware = true, + } +}; +static const struct gsc_def gsc_def_dg2[] = { { .name ="mei-gsc" ,
@@ -107,6 +120,8 @@ static void gsc_init_one(struct drm_i915_private *i915,if (IS_DG1 (i915)) { def = &gsc_def_dg1[intf_id]; + }else if (IS_XEHPSDV (i915)) { + def = &gsc_def_xehpsdv[intf_id]; }else if (IS_DG2 (i915)) { def = &gsc_def_dg2[intf_id]; }else {
Signature · 1 line
2.37.2
Re: [Intel-gfx] [PATCH v8 05/16] drm/i915/gsc: add GSC XeHP SDV platform definition
Quoted 11 lines · Tomas Winkler
From: Alexander Usyskin <[email protected]>
Define GSC on XeHP SDV (Intel(R) dGPU without display)
XeHP SDV uses the same hardware settings as DG1, but uses polling instead of interrupts and runs the firmware in slow pace due to hardware limitations.
Signed-off-by Vitaly Lubart <[email protected]>Signed-off-by Tomas Winkler <[email protected]>Signed-off-by Alexander Usyskin <[email protected]>
This is unchanged from the previously reviewed rev, so this still applies:
Daniele
Quoted 37 lines
--- drivers/gpu/drm/i915/gt/intel_gsc.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+)drivers/gpu/drm/i915/gt/intel_gsc.c +15
-0@@ -56,6 +56,19 @@ static const struct gsc_def gsc_def_dg1[] = { } }; +static const struct gsc_def gsc_def_xehpsdv[] = { + { +/* HECI1 not enabled on the device. */ + }, + { + .name ="mei-gscfi" , + .bar =DG1_GSC_HECI2_BASE , + .bar_size =GSC_BAR_LENGTH , + .use_polling = true, + .slow_firmware = true, + } +}; +static const struct gsc_def gsc_def_dg2[] = { { .name ="mei-gsc" ,@@ -107,6 +120,8 @@ static void gsc_init_one(struct drm_i915_private *i915,if (IS_DG1 (i915)) { def = &gsc_def_dg1[intf_id]; + }else if (IS_XEHPSDV (i915)) { + def = &gsc_def_xehpsdv[intf_id]; }else if (IS_DG2 (i915)) { def = &gsc_def_dg2[intf_id]; }else {
PATCH v8 6/16 mei: gsc: use polling instead of interrupts
In reply to Tomas WinklerA work-around for a HW issue in XEHPSDV that manifests itself when SW reads a gsc register when gsc is sending an interrupt. The work-around is to disable interrupts and to use polling instead.
--- drivers/misc/mei/gsc-me.c | 48 ++++++++++++++++++----- drivers/misc/mei/hw-me.c | 80 ++++++++++++++++++++++++++++++++++++--- drivers/misc/mei/hw-me.h | 15 +++++++- 3 files changed, 128 insertions(+), 15 deletions(-)
drivers/misc/mei/gsc-me.c +39 -9
@@ -13,6 +13,7 @@#include <linux/ktime.h> #include <linux/delay.h> #include <linux/pm_runtime.h> +#include <linux/kthread.h> #include "mei_dev.h" #include "hw-me.h"
@@ -66,13 +67,28 @@ static int mei_gsc_probe(struct auxiliary_device *aux_dev,dev_set_drvdata (device, dev); - ret =devm_request_threaded_irq (device, hw->irq, - mei_me_irq_quick_handler, - mei_me_irq_thread_handler, -IRQF_ONESHOT ,KBUILD_MODNAME , dev); -if (ret) { -dev_err (device,"irq register failed %d\n" , ret); - goto err; +/* use polling */ +if (mei_me_hw_use_polling (hw)) { +mei_disable_interrupts (dev); +mei_clear_interrupts (dev); +init_waitqueue_head (&hw->wait_active); + hw->is_active = true;/* start in active mode for initialization */ + hw->polling_thread =kthread_run (mei_me_polling_thread, dev, +"kmegscirqd/%s" ,dev_name (device)); +if (IS_ERR (hw->polling_thread)) { + ret =PTR_ERR (hw->polling_thread); +dev_err (device,"unable to create kernel thread: %d\n" , ret); + goto err; + } + }else { + ret =devm_request_threaded_irq (device, hw->irq, + mei_me_irq_quick_handler, + mei_me_irq_thread_handler, +IRQF_ONESHOT ,KBUILD_MODNAME , dev); +if (ret) { +dev_err (device,"irq register failed %d\n" , ret); + goto err; + } }pm_runtime_get_noresume (device);
@@ -98,7 +114,8 @@ static int mei_gsc_probe(struct auxiliary_device *aux_dev, register_err:mei_stop (dev); -devm_free_irq (device, hw->irq, dev); +if (!mei_me_hw_use_polling (hw)) +devm_free_irq (device, hw->irq, dev); err:dev_err (device,"probe failed: %d\n" , ret);
@@ -119,12 +136,17 @@ static void mei_gsc_remove(struct auxiliary_device *aux_dev)mei_stop (dev); + hw =to_me_hw (dev); +if (mei_me_hw_use_polling (hw)) +kthread_stop (hw->polling_thread); +mei_deregister (dev);pm_runtime_disable (&aux_dev->dev);mei_disable_interrupts (dev); -devm_free_irq (&aux_dev->dev, hw->irq, dev); +if (!mei_me_hw_use_polling (hw)) +devm_free_irq (&aux_dev->dev, hw->irq, dev); }static int __maybe_unused mei_gsc_pm_suspend (struct device *device)
@@ -185,6 +207,9 @@ static int __maybe_unused mei_gsc_pm_runtime_suspend(struct device *device)if (mei_write_is_idle (dev)) { hw =to_me_hw (dev); hw->pg_state =MEI_PG_ON ; + +if (mei_me_hw_use_polling (hw)) + hw->is_active = false; ret =0 ; }else { ret = -EAGAIN ;
@@ -209,6 +234,11 @@ static int __maybe_unused mei_gsc_pm_runtime_resume(struct device *device) hw =to_me_hw (dev); hw->pg_state =MEI_PG_OFF ; +if (mei_me_hw_use_polling (hw)) { + hw->is_active = true; +wake_up (&hw->wait_active); + } +mutex_unlock (&dev->device_lock); irq_ret =mei_me_irq_thread_handler (1 , dev);
drivers/misc/mei/hw-me.c +75 -5
122 lines not on this page · raw message
drivers/misc/mei/hw-me.h +14 -1
@@ -1,6 +1,6 @@/* SPDX-License-Identifier: GPL-2.0 */ /* -* Copyright (c) 2012-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2012-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */
@@ -51,6 +51,9 @@ struct mei_cfg {* @d0i3_supported: di03 support * @hbuf_depth: depth of hardware host/write buffer in slots * @read_fws: read FW status register handler +* @polling_thread: interrupt polling thread +* @wait_active: the polling thread activity wait queue +* @is_active: the device is active */ struct mei_me_hw {const struct mei_cfg *cfg;
@@ -60,10 +63,19 @@ struct mei_me_hw {bool d0i3_supported;u8 hbuf_depth;int (*read_fws)(const struct mei_device *dev,int where,u32 *val); +/* polling */ +struct task_struct *polling_thread; +wait_queue_head_t wait_active; +bool is_active; };#define to_me_hw (dev) (struct mei_me_hw *)((dev)->hw) +static inline bool mei_me_hw_use_polling (const struct mei_me_hw *hw) +{ +return hw->irq <0 ; +} +/** * enum mei_cfg_idx - indices to platform specific configurations. *
@@ -127,5 +139,6 @@ int mei_me_pg_exit_sync(struct mei_device *dev);irqreturn_t mei_me_irq_quick_handler (int irq,void *dev_id);irqreturn_t mei_me_irq_thread_handler (int irq,void *dev_id); +int mei_me_polling_thread (void *_dev);#endif /* _MEI_INTERFACE_H_ */
Signature · 1 line
2.37.2
Re: [Intel-gfx] [PATCH v8 06/16] mei: gsc: use polling instead of interrupts
Quoted 8 lines · Tomas Winkler
A work-around for a HW issue in XEHPSDV that manifests itself when SW reads a gsc register when gsc is sending an interrupt. The work-around is to disable interrupts and to use polling instead.
Cc James Ausmus <[email protected]>Signed-off-by Vitaly Lubart <[email protected]>Signed-off-by Tomas Winkler <[email protected]>Signed-off-by Alexander Usyskin <[email protected]>
The only changes from the previously reviewed rev are extra comments and doc. Those look good, so my r-b stands:
Daniele
Quoted 287 lines
--- drivers/misc/mei/gsc-me.c | 48 ++++++++++++++++++----- drivers/misc/mei/hw-me.c | 80 ++++++++++++++++++++++++++++++++++++--- drivers/misc/mei/hw-me.h | 15 +++++++- 3 files changed, 128 insertions(+), 15 deletions(-)drivers/misc/mei/gsc-me.c +39
-9@@ -13,6 +13,7 @@#include <linux/ktime.h> #include <linux/delay.h> #include <linux/pm_runtime.h> +#include <linux/kthread.h> #include "mei_dev.h" #include "hw-me.h" @@ -66,13 +67,28 @@ static int mei_gsc_probe(struct auxiliary_device *aux_dev,dev_set_drvdata (device, dev); - ret =devm_request_threaded_irq (device, hw->irq, - mei_me_irq_quick_handler, - mei_me_irq_thread_handler, -IRQF_ONESHOT ,KBUILD_MODNAME , dev); -if (ret) { -dev_err (device,"irq register failed %d\n" , ret); - goto err; +/* use polling */ +if (mei_me_hw_use_polling (hw)) { +mei_disable_interrupts (dev); +mei_clear_interrupts (dev); +init_waitqueue_head (&hw->wait_active); + hw->is_active = true;/* start in active mode for initialization */ + hw->polling_thread =kthread_run (mei_me_polling_thread, dev, +"kmegscirqd/%s" ,dev_name (device)); +if (IS_ERR (hw->polling_thread)) { + ret =PTR_ERR (hw->polling_thread); +dev_err (device,"unable to create kernel thread: %d\n" , ret); + goto err; + } + }else { + ret =devm_request_threaded_irq (device, hw->irq, + mei_me_irq_quick_handler, + mei_me_irq_thread_handler, +IRQF_ONESHOT ,KBUILD_MODNAME , dev); +if (ret) { +dev_err (device,"irq register failed %d\n" , ret); + goto err; + } }pm_runtime_get_noresume (device);@@ -98,7 +114,8 @@ static int mei_gsc_probe(struct auxiliary_device *aux_dev, register_err:mei_stop (dev); -devm_free_irq (device, hw->irq, dev); +if (!mei_me_hw_use_polling (hw)) +devm_free_irq (device, hw->irq, dev); err:dev_err (device,"probe failed: %d\n" , ret);@@ -119,12 +136,17 @@ static void mei_gsc_remove(struct auxiliary_device *aux_dev)mei_stop (dev); + hw =to_me_hw (dev); +if (mei_me_hw_use_polling (hw)) +kthread_stop (hw->polling_thread); +mei_deregister (dev);pm_runtime_disable (&aux_dev->dev);mei_disable_interrupts (dev); -devm_free_irq (&aux_dev->dev, hw->irq, dev); +if (!mei_me_hw_use_polling (hw)) +devm_free_irq (&aux_dev->dev, hw->irq, dev); }static int __maybe_unused mei_gsc_pm_suspend (struct device *device)@@ -185,6 +207,9 @@ static int __maybe_unused mei_gsc_pm_runtime_suspend(struct device *device)if (mei_write_is_idle (dev)) { hw =to_me_hw (dev); hw->pg_state =MEI_PG_ON ; + +if (mei_me_hw_use_polling (hw)) + hw->is_active = false; ret =0 ; }else { ret = -EAGAIN ;@@ -209,6 +234,11 @@ static int __maybe_unused mei_gsc_pm_runtime_resume(struct device *device) hw =to_me_hw (dev); hw->pg_state =MEI_PG_OFF ; +if (mei_me_hw_use_polling (hw)) { + hw->is_active = true; +wake_up (&hw->wait_active); + } +mutex_unlock (&dev->device_lock); irq_ret =mei_me_irq_thread_handler (1 , dev);drivers/misc/mei/hw-me.c +75
-5@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2003-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ @@ -10,6 +10,7 @@#include <linux/interrupt.h> #include <linux/pm_runtime.h> #include <linux/sizes.h> +#include <linux/delay.h> #include "mei_dev.h" #include "hbm.h" @@ -327,9 +328,12 @@ static void mei_me_intr_clear(struct mei_device *dev)*/ static void mei_me_intr_enable (struct mei_device *dev) { -u32 hcsr =mei_hcsr_read (dev); +u32 hcsr; + +if (mei_me_hw_use_polling (to_me_hw (dev))) +return ; - hcsr |=H_CSR_IE_MASK ; + hcsr =mei_hcsr_read (dev) |H_CSR_IE_MASK ;mei_hcsr_set (dev, hcsr); }@@ -354,6 +358,9 @@ static void mei_me_synchronize_irq(struct mei_device *dev) {struct mei_me_hw *hw =to_me_hw (dev); +if (mei_me_hw_use_polling (hw)) +return ; +synchronize_irq (hw->irq); }@@ -380,7 +387,10 @@ static void mei_me_host_set_ready(struct mei_device *dev) {u32 hcsr =mei_hcsr_read (dev); - hcsr |=H_CSR_IE_MASK |H_IG |H_RDY ; +if (!mei_me_hw_use_polling (to_me_hw (dev))) + hcsr |=H_CSR_IE_MASK ; + + hcsr |=H_IG |H_RDY ;mei_hcsr_set (dev, hcsr); }@@ -1176,7 +1186,7 @@ static int mei_me_hw_reset(struct mei_device *dev, bool intr_enable) hcsr |=H_RST |H_IG |H_CSR_IS_MASK ; -if (!intr_enable) +if (!intr_enable ||mei_me_hw_use_polling (to_me_hw (dev))) hcsr &= ~H_CSR_IE_MASK ; dev->recvd_hw_ready = false;@@ -1331,6 +1341,66 @@ irqreturn_t mei_me_irq_thread_handler(int irq, void *dev_id) }EXPORT_SYMBOL_GPL (mei_me_irq_thread_handler); +#define MEI_POLLING_TIMEOUT_ACTIVE 100 +#define MEI_POLLING_TIMEOUT_IDLE 500 + +/** +* mei_me_polling_thread - interrupt register polling thread +* +* The thread monitors the interrupt source register and calls +* mei_me_irq_thread_handler() to handle the firmware +* input. +* +* The function polls in MEI_POLLING_TIMEOUT_ACTIVE timeout +* in case there was an event, in idle case the polling +* time increases yet again by MEI_POLLING_TIMEOUT_ACTIVE +* up to MEI_POLLING_TIMEOUT_IDLE. +* +* @_dev: mei device +* +* Return: always 0 +*/ +int mei_me_polling_thread (void *_dev) +{ +struct mei_device *dev = _dev; +irqreturn_t irq_ret; +long polling_timeout =MEI_POLLING_TIMEOUT_ACTIVE ; + +dev_dbg (dev->dev,"kernel thread is running\n" ); +while (!kthread_should_stop ()) { +struct mei_me_hw *hw =to_me_hw (dev); +u32 hcsr; + +wait_event_timeout (hw->wait_active, + hw->is_active ||kthread_should_stop (), +msecs_to_jiffies (MEI_POLLING_TIMEOUT_IDLE )); + +if (kthread_should_stop ()) +break ; + + hcsr =mei_hcsr_read (dev); +if (me_intr_src (hcsr)) { + polling_timeout =MEI_POLLING_TIMEOUT_ACTIVE ; + irq_ret =mei_me_irq_thread_handler (1 , dev); +if (irq_ret !=IRQ_HANDLED ) +dev_err (dev->dev,"irq_ret %d\n" , irq_ret); + }else { +/* +* Increase timeout by MEI_POLLING_TIMEOUT_ACTIVE +* up to MEI_POLLING_TIMEOUT_IDLE +*/ + polling_timeout =clamp_val (polling_timeout +MEI_POLLING_TIMEOUT_ACTIVE , +MEI_POLLING_TIMEOUT_ACTIVE , +MEI_POLLING_TIMEOUT_IDLE ); + } + +schedule_timeout_interruptible (msecs_to_jiffies (polling_timeout)); + } + +return 0 ; +} +EXPORT_SYMBOL_GPL (mei_me_polling_thread); +static const struct mei_hw_ops mei_me_hw_ops = { .trc_status = mei_me_trc_status,drivers/misc/mei/hw-me.h +14
-1@@ -1,6 +1,6 @@/* SPDX-License-Identifier: GPL-2.0 */ /* -* Copyright (c) 2012-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2012-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ @@ -51,6 +51,9 @@ struct mei_cfg {* @d0i3_supported: di03 support * @hbuf_depth: depth of hardware host/write buffer in slots * @read_fws: read FW status register handler +* @polling_thread: interrupt polling thread +* @wait_active: the polling thread activity wait queue +* @is_active: the device is active */ struct mei_me_hw {const struct mei_cfg *cfg;@@ -60,10 +63,19 @@ struct mei_me_hw {bool d0i3_supported;u8 hbuf_depth;int (*read_fws)(const struct mei_device *dev,int where,u32 *val); +/* polling */ +struct task_struct *polling_thread; +wait_queue_head_t wait_active; +bool is_active; };#define to_me_hw (dev) (struct mei_me_hw *)((dev)->hw) +static inline bool mei_me_hw_use_polling (const struct mei_me_hw *hw) +{ +return hw->irq <0 ; +} +/** * enum mei_cfg_idx - indices to platform specific configurations. * @@ -127,5 +139,6 @@ int mei_me_pg_exit_sync(struct mei_device *dev);irqreturn_t mei_me_irq_quick_handler (int irq,void *dev_id);irqreturn_t mei_me_irq_thread_handler (int irq,void *dev_id); +int mei_me_polling_thread (void *_dev);#endif /* _MEI_INTERFACE_H_ */
PATCH v8 7/16 mei: gsc: wait for reset thread on stop
In reply to Tomas WinklerFrom: Alexander Usyskin <[email protected]>
Wait for reset work to complete before initiating
stop reset flow sequence.
--- drivers/misc/mei/init.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/misc/mei/init.c +3 -1
@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2012-2019, Intel Corporation. All rights reserved. +* Copyright (c) 2012-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */
@@ -320,6 +320,8 @@ void mei_stop(struct mei_device *dev)mei_clear_interrupts (dev);mei_synchronize_irq (dev); +/* to catch HW-initiated reset */ +mei_cancel_work (dev);mutex_lock (&dev->device_lock);
Signature · 1 line
2.37.2
Re: [Intel-gfx] [PATCH v8 07/16] mei: gsc: wait for reset thread on stop
Quoted 7 lines · Tomas Winkler
From: Alexander Usyskin <[email protected]>
Wait for reset work to complete before initiating
stop reset flow sequence.Signed-off-by Alexander Usyskin <[email protected]>Signed-off-by Tomas Winkler <[email protected]>
This is unchanged from the previously reviewed rev (apart from the fixed date in the header), so this still applies:
Daniele
Quoted 25 lines
--- drivers/misc/mei/init.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)drivers/misc/mei/init.c +3
-1@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2012-2019, Intel Corporation. All rights reserved. +* Copyright (c) 2012-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ @@ -320,6 +320,8 @@ void mei_stop(struct mei_device *dev)mei_clear_interrupts (dev);mei_synchronize_irq (dev); +/* to catch HW-initiated reset */ +mei_cancel_work (dev);mutex_lock (&dev->device_lock);
PATCH v8 8/16 mei: extend timeouts on slow devices.
In reply to Tomas WinklerFrom: Alexander Usyskin <[email protected]>
Parametrize operational timeouts in order to support slow firmware on some graphics devices.
--- drivers/misc/mei/bus-fixup.c | 5 ++--- drivers/misc/mei/client.c | 16 ++++++++-------- drivers/misc/mei/gsc-me.c | 2 +- drivers/misc/mei/hbm.c | 14 +++++++------- drivers/misc/mei/hw-me.c | 30 ++++++++++++++++-------------- drivers/misc/mei/hw-me.h | 2 +- drivers/misc/mei/hw-txe.c | 4 ++-- drivers/misc/mei/hw.h | 7 ++++++- drivers/misc/mei/init.c | 19 ++++++++++++++++++- drivers/misc/mei/main.c | 4 ++-- drivers/misc/mei/mei_dev.h | 18 +++++++++++++++++- drivers/misc/mei/pci-me.c | 4 ++-- 12 files changed, 82 insertions(+), 43 deletions(-)
drivers/misc/mei/bus-fixup.c +2 -3
@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2013-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2013-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */
@@ -164,7 +164,6 @@ static int mei_osver(struct mei_cl_device *cldev) sizeof(struct mkhi_fw_ver))#define MKHI_FWVER_LEN (__num) (sizeof(struct mkhi_msg_hdr) + \ sizeof(struct mkhi_fw_ver_block) * (__num)) -#define MKHI_RCV_TIMEOUT 500/* receive timeout in msec */ static int mei_fwver (struct mei_cl_device *cldev) {char buf[MKHI_FWVER_BUF_LEN ];
@@ -187,7 +186,7 @@ static int mei_fwver(struct mei_cl_device *cldev) ret =0 ; bytes_recv =__mei_cl_recv (cldev->cl, buf,sizeof (buf),NULL ,0 , -MKHI_RCV_TIMEOUT ); + cldev->bus->timeouts.mkhi_recv);if (bytes_recv <0 || (size_t )bytes_recv <MKHI_FWVER_LEN (1 )) {/* * Should be at least one version block,
drivers/misc/mei/client.c +8 -8
@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2003-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */
@@ -870,7 +870,7 @@ static int mei_cl_send_disconnect(struct mei_cl *cl, struct mei_cl_cb *cb) }list_move_tail (&cb->list, &dev->ctrl_rd_list); - cl->timer_count =MEI_CONNECT_TIMEOUT ; + cl->timer_count = dev->timeouts.connect;mei_schedule_stall_timer (dev);return 0 ;
@@ -945,7 +945,7 @@ static int __mei_cl_disconnect(struct mei_cl *cl)wait_event_timeout (cl->wait, cl->state ==MEI_FILE_DISCONNECT_REPLY || cl->state ==MEI_FILE_DISCONNECTED , -mei_secs_to_jiffies (MEI_CL_CONNECT_TIMEOUT )); + dev->timeouts.cl_connect);mutex_lock (&dev->device_lock); rets = cl->status;
@@ -1065,7 +1065,7 @@ static int mei_cl_send_connect(struct mei_cl *cl, struct mei_cl_cb *cb) }list_move_tail (&cb->list, &dev->ctrl_rd_list); - cl->timer_count =MEI_CONNECT_TIMEOUT ; + cl->timer_count = dev->timeouts.connect;mei_schedule_stall_timer (dev);return 0 ; }
@@ -1164,7 +1164,7 @@ int mei_cl_connect(struct mei_cl *cl, struct mei_me_client *me_cl, cl->state ==MEI_FILE_DISCONNECTED || cl->state ==MEI_FILE_DISCONNECT_REQUIRED || cl->state == MEI_FILE_DISCONNECT_REPLY), - mei_secs_to_jiffies(MEI_CL_CONNECT_TIMEOUT)); + dev->timeouts.cl_connect);mutex_lock (&dev->device_lock);if (!mei_cl_is_connected (cl)) {
@@ -1562,7 +1562,7 @@ int mei_cl_notify_request(struct mei_cl *cl, cl->notify_en == request || cl->status || !mei_cl_is_connected (cl), - mei_secs_to_jiffies(MEI_CL_CONNECT_TIMEOUT)); + dev->timeouts.cl_connect);mutex_lock (&dev->device_lock);if (cl->notify_en != request && !cl->status)
@@ -2336,7 +2336,7 @@ int mei_cl_dma_alloc_and_map(struct mei_cl *cl, const struct file *fp,mutex_unlock (&dev->device_lock);wait_event_timeout (cl->wait, cl->dma_mapped || cl->status, -mei_secs_to_jiffies (MEI_CL_CONNECT_TIMEOUT )); + dev->timeouts.cl_connect);mutex_lock (&dev->device_lock);if (!cl->dma_mapped && !cl->status)
@@ -2415,7 +2415,7 @@ int mei_cl_dma_unmap(struct mei_cl *cl, const struct file *fp)mutex_unlock (&dev->device_lock);wait_event_timeout (cl->wait, !cl->dma_mapped || cl->status, -mei_secs_to_jiffies (MEI_CL_CONNECT_TIMEOUT )); + dev->timeouts.cl_connect);mutex_lock (&dev->device_lock);if (cl->dma_mapped && !cl->status)
drivers/misc/mei/gsc-me.c +1 -1
@@ -48,7 +48,7 @@ static int mei_gsc_probe(struct auxiliary_device *aux_dev, device = &aux_dev->dev; - dev =mei_me_dev_init (device, cfg); + dev =mei_me_dev_init (device, cfg, adev->slow_firmware);if (!dev) { ret = -ENOMEM ; goto err;
drivers/misc/mei/hbm.c +7 -7
@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2003-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ #include <linux/export.h>
@@ -232,7 +232,7 @@ int mei_hbm_start_wait(struct mei_device *dev)mutex_unlock (&dev->device_lock); ret =wait_event_timeout (dev->wait_hbm_start, dev->hbm_state !=MEI_HBM_STARTING , -mei_secs_to_jiffies (MEI_HBM_TIMEOUT )); + dev->timeouts.hbm);mutex_lock (&dev->device_lock);if (ret ==0 && (dev->hbm_state <=MEI_HBM_STARTING )) {
@@ -275,7 +275,7 @@ int mei_hbm_start_req(struct mei_device *dev) } dev->hbm_state =MEI_HBM_STARTING ; - dev->init_clients_timer =MEI_CLIENTS_INIT_TIMEOUT ; + dev->init_clients_timer = dev->timeouts.client_init;mei_schedule_stall_timer (dev);return 0 ; }
@@ -316,7 +316,7 @@ static int mei_hbm_dma_setup_req(struct mei_device *dev) } dev->hbm_state =MEI_HBM_DR_SETUP ; - dev->init_clients_timer =MEI_CLIENTS_INIT_TIMEOUT ; + dev->init_clients_timer = dev->timeouts.client_init;mei_schedule_stall_timer (dev);return 0 ; }
@@ -351,7 +351,7 @@ static int mei_hbm_capabilities_req(struct mei_device *dev) } dev->hbm_state =MEI_HBM_CAP_SETUP ; - dev->init_clients_timer =MEI_CLIENTS_INIT_TIMEOUT ; + dev->init_clients_timer = dev->timeouts.client_init;mei_schedule_stall_timer (dev);return 0 ; }
@@ -385,7 +385,7 @@ static int mei_hbm_enum_clients_req(struct mei_device *dev)return ret; } dev->hbm_state =MEI_HBM_ENUM_CLIENTS ; - dev->init_clients_timer =MEI_CLIENTS_INIT_TIMEOUT ; + dev->init_clients_timer = dev->timeouts.client_init;mei_schedule_stall_timer (dev);return 0 ; }
@@ -751,7 +751,7 @@ static int mei_hbm_prop_req(struct mei_device *dev, unsigned long start_idx)return ret; } - dev->init_clients_timer =MEI_CLIENTS_INIT_TIMEOUT ; + dev->init_clients_timer = dev->timeouts.client_init;mei_schedule_stall_timer (dev);return 0 ;
drivers/misc/mei/hw-me.c +16 -14
@@ -445,7 +445,7 @@ static int mei_me_hw_ready_wait(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_hw_ready, dev->recvd_hw_ready, -mei_secs_to_jiffies (MEI_HW_READY_TIMEOUT )); + dev->timeouts.hw_ready);mutex_lock (&dev->device_lock);if (!dev->recvd_hw_ready) {dev_err (dev->dev,"wait hw ready failed\n" );
@@ -707,7 +707,6 @@ static void mei_me_pg_unset(struct mei_device *dev)static int mei_me_pg_legacy_enter_sync (struct mei_device *dev) {struct mei_me_hw *hw =to_me_hw (dev); -unsigned long timeout =mei_secs_to_jiffies (MEI_PGI_TIMEOUT );int ret; dev->pg_event =MEI_PG_EVENT_WAIT ;
@@ -718,7 +717,8 @@ static int mei_me_pg_legacy_enter_sync(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_pg, - dev->pg_event ==MEI_PG_EVENT_RECEIVED , timeout); + dev->pg_event ==MEI_PG_EVENT_RECEIVED , + dev->timeouts.pgi);mutex_lock (&dev->device_lock);if (dev->pg_event ==MEI_PG_EVENT_RECEIVED ) {
@@ -744,7 +744,6 @@ static int mei_me_pg_legacy_enter_sync(struct mei_device *dev)static int mei_me_pg_legacy_exit_sync (struct mei_device *dev) {struct mei_me_hw *hw =to_me_hw (dev); -unsigned long timeout =mei_secs_to_jiffies (MEI_PGI_TIMEOUT );int ret;if (dev->pg_event ==MEI_PG_EVENT_RECEIVED )
@@ -756,7 +755,8 @@ static int mei_me_pg_legacy_exit_sync(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_pg, - dev->pg_event ==MEI_PG_EVENT_RECEIVED , timeout); + dev->pg_event ==MEI_PG_EVENT_RECEIVED , + dev->timeouts.pgi);mutex_lock (&dev->device_lock); reply:
@@ -772,7 +772,8 @@ static int mei_me_pg_legacy_exit_sync(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_pg, - dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED , timeout); + dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED , + dev->timeouts.pgi);mutex_lock (&dev->device_lock);if (dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED )
@@ -887,8 +888,6 @@ static u32 mei_me_d0i3_unset(struct mei_device *dev)static int mei_me_d0i3_enter_sync (struct mei_device *dev) {struct mei_me_hw *hw =to_me_hw (dev); -unsigned long d0i3_timeout =mei_secs_to_jiffies (MEI_D0I3_TIMEOUT ); -unsigned long pgi_timeout =mei_secs_to_jiffies (MEI_PGI_TIMEOUT );int ret;u32 reg;
@@ -910,7 +909,8 @@ static int mei_me_d0i3_enter_sync(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_pg, - dev->pg_event ==MEI_PG_EVENT_RECEIVED , pgi_timeout); + dev->pg_event ==MEI_PG_EVENT_RECEIVED , + dev->timeouts.d0i3);mutex_lock (&dev->device_lock);if (dev->pg_event !=MEI_PG_EVENT_RECEIVED ) {
@@ -930,7 +930,8 @@ static int mei_me_d0i3_enter_sync(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_pg, - dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED , d0i3_timeout); + dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED , + dev->timeouts.d0i3);mutex_lock (&dev->device_lock);if (dev->pg_event !=MEI_PG_EVENT_INTR_RECEIVED ) {
@@ -990,7 +991,6 @@ static int mei_me_d0i3_enter(struct mei_device *dev)static int mei_me_d0i3_exit_sync (struct mei_device *dev) {struct mei_me_hw *hw =to_me_hw (dev); -unsigned long timeout =mei_secs_to_jiffies (MEI_D0I3_TIMEOUT );int ret;u32 reg;
@@ -1013,7 +1013,8 @@ static int mei_me_d0i3_exit_sync(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_pg, - dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED , timeout); + dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED , + dev->timeouts.pgi);mutex_lock (&dev->device_lock);if (dev->pg_event !=MEI_PG_EVENT_INTR_RECEIVED ) {
@@ -1706,11 +1707,12 @@ EXPORT_SYMBOL_GPL(mei_me_get_cfg);* * @parent: device associated with physical device (pci/platform) * @cfg: per device generation config +* @slow_fw: configure longer timeouts as FW is slow * * Return: The mei_device pointer on success, NULL on failure. */ struct mei_device *mei_me_dev_init (struct device *parent, -const struct mei_cfg *cfg) +const struct mei_cfg *cfg,bool slow_fw) {struct mei_device *dev;struct mei_me_hw *hw;
@@ -1725,7 +1727,7 @@ struct mei_device *mei_me_dev_init(struct device *parent,for (i =0 ; i <DMA_DSCR_NUM ; i++) dev->dr_dscr[i].size = cfg->dma_size[i]; -mei_device_init (dev, parent, &mei_me_hw_ops); +mei_device_init (dev, parent, slow_fw, &mei_me_hw_ops); hw->cfg = cfg; dev->fw_f_fw_ver_supported = cfg->fw_ver_supported;
drivers/misc/mei/hw-me.h +1 -1
@@ -132,7 +132,7 @@ enum mei_cfg_idx {const struct mei_cfg *mei_me_get_cfg (kernel_ulong_t idx);struct mei_device *mei_me_dev_init (struct device *parent, -const struct mei_cfg *cfg); +const struct mei_cfg *cfg,bool slow_fw);int mei_me_pg_enter_sync (struct mei_device *dev);int mei_me_pg_exit_sync (struct mei_device *dev);
drivers/misc/mei/hw-txe.c +2 -2
@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2013-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2013-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */
@@ -1201,7 +1201,7 @@ struct mei_device *mei_txe_dev_init(struct pci_dev *pdev)if (!dev)return NULL ; -mei_device_init (dev, &pdev->dev, &mei_txe_hw_ops); +mei_device_init (dev, &pdev->dev, false, &mei_txe_hw_ops); hw =to_txe_hw (dev);
drivers/misc/mei/hw.h +6 -1
@@ -1,6 +1,6 @@/* SPDX-License-Identifier: GPL-2.0 */ /* -* Copyright (c) 2003-2020, Intel Corporation. All rights reserved +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved * Intel Management Engine Interface (Intel MEI) Linux driver */
@@ -16,11 +16,16 @@#define MEI_CONNECT_TIMEOUT 3/* HPS: at least 2 seconds */ #define MEI_CL_CONNECT_TIMEOUT 15/* HPS: Client Connect Timeout */ +#define MEI_CL_CONNECT_TIMEOUT_SLOW 30/* HPS: Client Connect Timeout, slow FW */ #define MEI_CLIENTS_INIT_TIMEOUT 15/* HPS: Clients Enumeration Timeout */ #define MEI_PGI_TIMEOUT 1/* PG Isolation time response 1 sec */ #define MEI_D0I3_TIMEOUT 5/* D0i3 set/unset max response time */ #define MEI_HBM_TIMEOUT 1/* 1 second */ +#define MEI_HBM_TIMEOUT_SLOW 5/* 5 second, slow FW */ + +#define MKHI_RCV_TIMEOUT 500/* receive timeout in msec */ +#define MKHI_RCV_TIMEOUT_SLOW 10000/* receive timeout in msec, slow FW */ /* * FW page size for DMA allocations
drivers/misc/mei/init.c +18 -1
@@ -359,14 +359,16 @@ bool mei_write_is_idle(struct mei_device *dev)EXPORT_SYMBOL_GPL (mei_write_is_idle);/** -* mei_device_init -- initialize mei_device structure +* mei_device_init - initialize mei_device structure * * @dev: the mei device * @device: the device structure +* @slow_fw: configure longer timeouts as FW is slow * @hw_ops: hw operations */ void mei_device_init (struct mei_device *dev,struct device *device, +bool slow_fw,const struct mei_hw_ops *hw_ops) {/* setup our list array */
@@ -404,6 +406,21 @@ void mei_device_init(struct mei_device *dev, dev->pg_event =MEI_PG_EVENT_IDLE ; dev->ops = hw_ops; dev->dev = device; + + dev->timeouts.hw_ready =mei_secs_to_jiffies (MEI_HW_READY_TIMEOUT ); + dev->timeouts.connect =MEI_CONNECT_TIMEOUT ; + dev->timeouts.client_init =MEI_CLIENTS_INIT_TIMEOUT ; + dev->timeouts.pgi =mei_secs_to_jiffies (MEI_PGI_TIMEOUT ); + dev->timeouts.d0i3 =mei_secs_to_jiffies (MEI_D0I3_TIMEOUT ); +if (slow_fw) { + dev->timeouts.cl_connect =mei_secs_to_jiffies (MEI_CL_CONNECT_TIMEOUT_SLOW ); + dev->timeouts.hbm =mei_secs_to_jiffies (MEI_HBM_TIMEOUT_SLOW ); + dev->timeouts.mkhi_recv =msecs_to_jiffies (MKHI_RCV_TIMEOUT_SLOW ); + }else { + dev->timeouts.cl_connect =mei_secs_to_jiffies (MEI_CL_CONNECT_TIMEOUT ); + dev->timeouts.hbm =mei_secs_to_jiffies (MEI_HBM_TIMEOUT ); + dev->timeouts.mkhi_recv =msecs_to_jiffies (MKHI_RCV_TIMEOUT ); + } }EXPORT_SYMBOL_GPL (mei_device_init);
drivers/misc/mei/main.c +2 -2
@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2003-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */
@@ -571,7 +571,7 @@ static int mei_ioctl_connect_vtag(struct file *file, cl->state ==MEI_FILE_DISCONNECTED || cl->state ==MEI_FILE_DISCONNECT_REQUIRED || cl->state == MEI_FILE_DISCONNECT_REPLY), - mei_secs_to_jiffies(MEI_CL_CONNECT_TIMEOUT)); + dev->timeouts.cl_connect);mutex_lock (&dev->device_lock); }
drivers/misc/mei/mei_dev.h +17 -1
@@ -1,6 +1,6 @@/* SPDX-License-Identifier: GPL-2.0 */ /* -* Copyright (c) 2003-2019, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */
@@ -415,6 +415,17 @@ struct mei_fw_version {#define MEI_MAX_FW_VER_BLOCKS 3 +struct mei_dev_timeouts { +unsigned long hw_ready;/* Timeout on ready message, in jiffies */ +int connect;/* HPS: at least 2 seconds, in seconds */ +unsigned long cl_connect;/* HPS: Client Connect Timeout, in jiffies */ +int client_init;/* HPS: Clients Enumeration Timeout, in seconds */ +unsigned long pgi;/* PG Isolation time response, in jiffies */ +unsigned int d0i3;/* D0i3 set/unset max response time, in jiffies */ +unsigned long hbm;/* HBM operation timeout, in jiffies */ +unsigned long mkhi_recv;/* receive timeout, in jiffies */ +}; +/** * struct mei_device - MEI private device struct *
@@ -480,6 +491,8 @@ struct mei_fw_version {* @allow_fixed_address: allow user space to connect a fixed client * @override_fixed_address: force allow fixed address behavior * +* @timeouts: actual timeout values +* * @reset_work : work item for the device reset * @bus_rescan_work : work item for the bus rescan *
@@ -568,6 +581,8 @@ struct mei_device {bool allow_fixed_address;bool override_fixed_address; +struct mei_dev_timeouts timeouts; +struct work_struct reset_work;struct work_struct bus_rescan_work;
@@ -632,6 +647,7 @@ static inline u32 mei_slots2data(int slots)*/ void mei_device_init (struct mei_device *dev,struct device *device, +bool slow_fw,const struct mei_hw_ops *hw_ops);int mei_reset (struct mei_device *dev);int mei_start (struct mei_device *dev);
drivers/misc/mei/pci-me.c +2 -2
@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2003-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */
@@ -203,7 +203,7 @@ static int mei_me_probe(struct pci_dev *pdev, const struct pci_device_id *ent) }/* allocates and initializes the mei dev structure */ - dev =mei_me_dev_init (&pdev->dev, cfg); + dev =mei_me_dev_init (&pdev->dev, cfg, false);if (!dev) { err = -ENOMEM ; goto end;
Signature · 1 line
2.37.2
Re: [Intel-gfx] [PATCH v8 08/16] mei: extend timeouts on slow devices.
Quoted 274 lines · Tomas Winkler
From: Alexander Usyskin <[email protected]>
Parametrize operational timeouts in order to support slow firmware on some graphics devices.
Signed-off-by Alexander Usyskin <[email protected]>Signed-off-by Tomas Winkler <[email protected]>--- drivers/misc/mei/bus-fixup.c | 5 ++--- drivers/misc/mei/client.c | 16 ++++++++-------- drivers/misc/mei/gsc-me.c | 2 +- drivers/misc/mei/hbm.c | 14 +++++++------- drivers/misc/mei/hw-me.c | 30 ++++++++++++++++-------------- drivers/misc/mei/hw-me.h | 2 +- drivers/misc/mei/hw-txe.c | 4 ++-- drivers/misc/mei/hw.h | 7 ++++++- drivers/misc/mei/init.c | 19 ++++++++++++++++++- drivers/misc/mei/main.c | 4 ++-- drivers/misc/mei/mei_dev.h | 18 +++++++++++++++++- drivers/misc/mei/pci-me.c | 4 ++-- 12 files changed, 82 insertions(+), 43 deletions(-)drivers/misc/mei/bus-fixup.c +2
-3@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2013-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2013-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ @@ -164,7 +164,6 @@ static int mei_osver(struct mei_cl_device *cldev) sizeof(struct mkhi_fw_ver))#define MKHI_FWVER_LEN (__num) (sizeof(struct mkhi_msg_hdr) + \ sizeof(struct mkhi_fw_ver_block) * (__num)) -#define MKHI_RCV_TIMEOUT 500/* receive timeout in msec */ static int mei_fwver (struct mei_cl_device *cldev) {char buf[MKHI_FWVER_BUF_LEN ];@@ -187,7 +186,7 @@ static int mei_fwver(struct mei_cl_device *cldev) ret =0 ; bytes_recv =__mei_cl_recv (cldev->cl, buf,sizeof (buf),NULL ,0 , -MKHI_RCV_TIMEOUT ); + cldev->bus->timeouts.mkhi_recv);if (bytes_recv <0 || (size_t )bytes_recv <MKHI_FWVER_LEN (1 )) {/* * Should be at least one version block, drivers/misc/mei/client.c +8
-8@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2003-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ @@ -870,7 +870,7 @@ static int mei_cl_send_disconnect(struct mei_cl *cl, struct mei_cl_cb *cb) }list_move_tail (&cb->list, &dev->ctrl_rd_list); - cl->timer_count =MEI_CONNECT_TIMEOUT ; + cl->timer_count = dev->timeouts.connect;mei_schedule_stall_timer (dev);return 0 ;@@ -945,7 +945,7 @@ static int __mei_cl_disconnect(struct mei_cl *cl)wait_event_timeout (cl->wait, cl->state ==MEI_FILE_DISCONNECT_REPLY || cl->state ==MEI_FILE_DISCONNECTED , -mei_secs_to_jiffies (MEI_CL_CONNECT_TIMEOUT )); + dev->timeouts.cl_connect);mutex_lock (&dev->device_lock); rets = cl->status;@@ -1065,7 +1065,7 @@ static int mei_cl_send_connect(struct mei_cl *cl, struct mei_cl_cb *cb) }list_move_tail (&cb->list, &dev->ctrl_rd_list); - cl->timer_count =MEI_CONNECT_TIMEOUT ; + cl->timer_count = dev->timeouts.connect;mei_schedule_stall_timer (dev);return 0 ; }@@ -1164,7 +1164,7 @@ int mei_cl_connect(struct mei_cl *cl, struct mei_me_client *me_cl, cl->state ==MEI_FILE_DISCONNECTED || cl->state ==MEI_FILE_DISCONNECT_REQUIRED || cl->state == MEI_FILE_DISCONNECT_REPLY), - mei_secs_to_jiffies(MEI_CL_CONNECT_TIMEOUT)); + dev->timeouts.cl_connect);mutex_lock (&dev->device_lock);if (!mei_cl_is_connected (cl)) {@@ -1562,7 +1562,7 @@ int mei_cl_notify_request(struct mei_cl *cl, cl->notify_en == request || cl->status || !mei_cl_is_connected (cl), - mei_secs_to_jiffies(MEI_CL_CONNECT_TIMEOUT)); + dev->timeouts.cl_connect);mutex_lock (&dev->device_lock);if (cl->notify_en != request && !cl->status)@@ -2336,7 +2336,7 @@ int mei_cl_dma_alloc_and_map(struct mei_cl *cl, const struct file *fp,mutex_unlock (&dev->device_lock);wait_event_timeout (cl->wait, cl->dma_mapped || cl->status, -mei_secs_to_jiffies (MEI_CL_CONNECT_TIMEOUT )); + dev->timeouts.cl_connect);mutex_lock (&dev->device_lock);if (!cl->dma_mapped && !cl->status)@@ -2415,7 +2415,7 @@ int mei_cl_dma_unmap(struct mei_cl *cl, const struct file *fp)mutex_unlock (&dev->device_lock);wait_event_timeout (cl->wait, !cl->dma_mapped || cl->status, -mei_secs_to_jiffies (MEI_CL_CONNECT_TIMEOUT )); + dev->timeouts.cl_connect);mutex_lock (&dev->device_lock);if (cl->dma_mapped && !cl->status)drivers/misc/mei/gsc-me.c +1
-1@@ -48,7 +48,7 @@ static int mei_gsc_probe(struct auxiliary_device *aux_dev, device = &aux_dev->dev; - dev =mei_me_dev_init (device, cfg); + dev =mei_me_dev_init (device, cfg, adev->slow_firmware);if (!dev) { ret = -ENOMEM ; goto err;drivers/misc/mei/hbm.c +7
-7@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2003-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ #include <linux/export.h> @@ -232,7 +232,7 @@ int mei_hbm_start_wait(struct mei_device *dev)mutex_unlock (&dev->device_lock); ret =wait_event_timeout (dev->wait_hbm_start, dev->hbm_state !=MEI_HBM_STARTING , -mei_secs_to_jiffies (MEI_HBM_TIMEOUT )); + dev->timeouts.hbm);mutex_lock (&dev->device_lock);if (ret ==0 && (dev->hbm_state <=MEI_HBM_STARTING )) {@@ -275,7 +275,7 @@ int mei_hbm_start_req(struct mei_device *dev) } dev->hbm_state =MEI_HBM_STARTING ; - dev->init_clients_timer =MEI_CLIENTS_INIT_TIMEOUT ; + dev->init_clients_timer = dev->timeouts.client_init;mei_schedule_stall_timer (dev);return 0 ; }@@ -316,7 +316,7 @@ static int mei_hbm_dma_setup_req(struct mei_device *dev) } dev->hbm_state =MEI_HBM_DR_SETUP ; - dev->init_clients_timer =MEI_CLIENTS_INIT_TIMEOUT ; + dev->init_clients_timer = dev->timeouts.client_init;mei_schedule_stall_timer (dev);return 0 ; }@@ -351,7 +351,7 @@ static int mei_hbm_capabilities_req(struct mei_device *dev) } dev->hbm_state =MEI_HBM_CAP_SETUP ; - dev->init_clients_timer =MEI_CLIENTS_INIT_TIMEOUT ; + dev->init_clients_timer = dev->timeouts.client_init;mei_schedule_stall_timer (dev);return 0 ; }@@ -385,7 +385,7 @@ static int mei_hbm_enum_clients_req(struct mei_device *dev)return ret; } dev->hbm_state =MEI_HBM_ENUM_CLIENTS ; - dev->init_clients_timer =MEI_CLIENTS_INIT_TIMEOUT ; + dev->init_clients_timer = dev->timeouts.client_init;mei_schedule_stall_timer (dev);return 0 ; }@@ -751,7 +751,7 @@ static int mei_hbm_prop_req(struct mei_device *dev, unsigned long start_idx)return ret; } - dev->init_clients_timer =MEI_CLIENTS_INIT_TIMEOUT ; + dev->init_clients_timer = dev->timeouts.client_init;mei_schedule_stall_timer (dev);return 0 ;drivers/misc/mei/hw-me.c +7
-8@@ -445,7 +445,7 @@ static int mei_me_hw_ready_wait(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_hw_ready, dev->recvd_hw_ready, -mei_secs_to_jiffies (MEI_HW_READY_TIMEOUT )); + dev->timeouts.hw_ready);mutex_lock (&dev->device_lock);if (!dev->recvd_hw_ready) {dev_err (dev->dev,"wait hw ready failed\n" );@@ -707,7 +707,6 @@ static void mei_me_pg_unset(struct mei_device *dev)static int mei_me_pg_legacy_enter_sync (struct mei_device *dev) {struct mei_me_hw *hw =to_me_hw (dev); -unsigned long timeout =mei_secs_to_jiffies (MEI_PGI_TIMEOUT );int ret; dev->pg_event =MEI_PG_EVENT_WAIT ;@@ -718,7 +717,8 @@ static int mei_me_pg_legacy_enter_sync(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_pg, - dev->pg_event ==MEI_PG_EVENT_RECEIVED , timeout); + dev->pg_event ==MEI_PG_EVENT_RECEIVED , + dev->timeouts.pgi);mutex_lock (&dev->device_lock);if (dev->pg_event ==MEI_PG_EVENT_RECEIVED ) {@@ -744,7 +744,6 @@ static int mei_me_pg_legacy_enter_sync(struct mei_device *dev)static int mei_me_pg_legacy_exit_sync (struct mei_device *dev) {struct mei_me_hw *hw =to_me_hw (dev); -unsigned long timeout =mei_secs_to_jiffies (MEI_PGI_TIMEOUT );int ret;if (dev->pg_event ==MEI_PG_EVENT_RECEIVED )@@ -756,7 +755,8 @@ static int mei_me_pg_legacy_exit_sync(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_pg, - dev->pg_event ==MEI_PG_EVENT_RECEIVED , timeout); + dev->pg_event ==MEI_PG_EVENT_RECEIVED , + dev->timeouts.pgi);mutex_lock (&dev->device_lock); reply:@@ -772,7 +772,8 @@ static int mei_me_pg_legacy_exit_sync(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_pg, - dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED , timeout); + dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED , + dev->timeouts.pgi);mutex_lock (&dev->device_lock);if (dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED )@@ -887,8 +888,6 @@ static u32 mei_me_d0i3_unset(struct mei_device *dev)static int mei_me_d0i3_enter_sync (struct mei_device *dev) {struct mei_me_hw *hw =to_me_hw (dev); -unsigned long d0i3_timeout =mei_secs_to_jiffies (MEI_D0I3_TIMEOUT ); -unsigned long pgi_timeout =mei_secs_to_jiffies (MEI_PGI_TIMEOUT );int ret;u32 reg;
drivers/misc/mei/hw-me.c static int mei_me_d0i3_enter_sync(struct mei_device *dev) · line 913
Quoted 6 lines
drivers/misc/mei/hw-me.c +2
-1@@ -910,7 +909,8 @@ static int mei_me_d0i3_enter_sync(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_pg, - dev->pg_event ==MEI_PG_EVENT_RECEIVED , pgi_timeout); + dev->pg_event ==MEI_PG_EVENT_RECEIVED , + dev->timeouts.d0i3);
This is now changed from MEI_PGI_TIMEOUT to MEI_D0I3_TIMEOUT
Quoted 22 lines
drivers/misc/mei/hw-me.c +2
-2mutex_lock (&dev->device_lock);if (dev->pg_event !=MEI_PG_EVENT_RECEIVED ) {@@ -930,7 +930,8 @@ static int mei_me_d0i3_enter_sync(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_pg, - dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED , d0i3_timeout); + dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED , + dev->timeouts.d0i3);mutex_lock (&dev->device_lock);if (dev->pg_event !=MEI_PG_EVENT_INTR_RECEIVED ) {@@ -990,7 +991,6 @@ static int mei_me_d0i3_enter(struct mei_device *dev)static int mei_me_d0i3_exit_sync (struct mei_device *dev) {struct mei_me_hw *hw =to_me_hw (dev); -unsigned long timeout =mei_secs_to_jiffies (MEI_D0I3_TIMEOUT );int ret;u32 reg;
drivers/misc/mei/hw-me.c static int mei_me_d0i3_exit_sync(struct mei_device *dev) · line 1017
Quoted 6 lines
drivers/misc/mei/hw-me.c +2
-1@@ -1013,7 +1013,8 @@ static int mei_me_d0i3_exit_sync(struct mei_device *dev)mutex_unlock (&dev->device_lock);wait_event_timeout (dev->wait_pg, - dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED , timeout); + dev->pg_event ==MEI_PG_EVENT_INTR_RECEIVED , + dev->timeouts.pgi);
while this is still changed from MEI_D0I3_TIMEOUT to MEI_PGI_TIMEOUT.
Did you switch the wrong one from pgi to d0i3 compared to the previous rev? or is this intentional?
Daniele
Quoted 231 lines
drivers/misc/mei/hw-me.c +3
-2mutex_lock (&dev->device_lock);if (dev->pg_event !=MEI_PG_EVENT_INTR_RECEIVED ) {@@ -1706,11 +1707,12 @@ EXPORT_SYMBOL_GPL(mei_me_get_cfg);* * @parent: device associated with physical device (pci/platform) * @cfg: per device generation config +* @slow_fw: configure longer timeouts as FW is slow * * Return: The mei_device pointer on success, NULL on failure. */ struct mei_device *mei_me_dev_init (struct device *parent, -const struct mei_cfg *cfg) +const struct mei_cfg *cfg,bool slow_fw) {struct mei_device *dev;struct mei_me_hw *hw;@@ -1725,7 +1727,7 @@ struct mei_device *mei_me_dev_init(struct device *parent,for (i =0 ; i <DMA_DSCR_NUM ; i++) dev->dr_dscr[i].size = cfg->dma_size[i]; -mei_device_init (dev, parent, &mei_me_hw_ops); +mei_device_init (dev, parent, slow_fw, &mei_me_hw_ops); hw->cfg = cfg; dev->fw_f_fw_ver_supported = cfg->fw_ver_supported;drivers/misc/mei/hw-me.h +1
-1@@ -132,7 +132,7 @@ enum mei_cfg_idx {const struct mei_cfg *mei_me_get_cfg (kernel_ulong_t idx);struct mei_device *mei_me_dev_init (struct device *parent, -const struct mei_cfg *cfg); +const struct mei_cfg *cfg,bool slow_fw);int mei_me_pg_enter_sync (struct mei_device *dev);int mei_me_pg_exit_sync (struct mei_device *dev);drivers/misc/mei/hw-txe.c +2
-2@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2013-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2013-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ @@ -1201,7 +1201,7 @@ struct mei_device *mei_txe_dev_init(struct pci_dev *pdev)if (!dev)return NULL ; -mei_device_init (dev, &pdev->dev, &mei_txe_hw_ops); +mei_device_init (dev, &pdev->dev, false, &mei_txe_hw_ops); hw =to_txe_hw (dev);drivers/misc/mei/hw.h +6
-1@@ -1,6 +1,6 @@/* SPDX-License-Identifier: GPL-2.0 */ /* -* Copyright (c) 2003-2020, Intel Corporation. All rights reserved +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved * Intel Management Engine Interface (Intel MEI) Linux driver */ @@ -16,11 +16,16 @@#define MEI_CONNECT_TIMEOUT 3/* HPS: at least 2 seconds */ #define MEI_CL_CONNECT_TIMEOUT 15/* HPS: Client Connect Timeout */ +#define MEI_CL_CONNECT_TIMEOUT_SLOW 30/* HPS: Client Connect Timeout, slow FW */ #define MEI_CLIENTS_INIT_TIMEOUT 15/* HPS: Clients Enumeration Timeout */ #define MEI_PGI_TIMEOUT 1/* PG Isolation time response 1 sec */ #define MEI_D0I3_TIMEOUT 5/* D0i3 set/unset max response time */ #define MEI_HBM_TIMEOUT 1/* 1 second */ +#define MEI_HBM_TIMEOUT_SLOW 5/* 5 second, slow FW */ + +#define MKHI_RCV_TIMEOUT 500/* receive timeout in msec */ +#define MKHI_RCV_TIMEOUT_SLOW 10000/* receive timeout in msec, slow FW */ /* * FW page size for DMA allocations drivers/misc/mei/init.c +18
-1@@ -359,14 +359,16 @@ bool mei_write_is_idle(struct mei_device *dev)EXPORT_SYMBOL_GPL (mei_write_is_idle);/** -* mei_device_init -- initialize mei_device structure +* mei_device_init - initialize mei_device structure * * @dev: the mei device * @device: the device structure +* @slow_fw: configure longer timeouts as FW is slow * @hw_ops: hw operations */ void mei_device_init (struct mei_device *dev,struct device *device, +bool slow_fw,const struct mei_hw_ops *hw_ops) {/* setup our list array */ @@ -404,6 +406,21 @@ void mei_device_init(struct mei_device *dev, dev->pg_event =MEI_PG_EVENT_IDLE ; dev->ops = hw_ops; dev->dev = device; + + dev->timeouts.hw_ready =mei_secs_to_jiffies (MEI_HW_READY_TIMEOUT ); + dev->timeouts.connect =MEI_CONNECT_TIMEOUT ; + dev->timeouts.client_init =MEI_CLIENTS_INIT_TIMEOUT ; + dev->timeouts.pgi =mei_secs_to_jiffies (MEI_PGI_TIMEOUT ); + dev->timeouts.d0i3 =mei_secs_to_jiffies (MEI_D0I3_TIMEOUT ); +if (slow_fw) { + dev->timeouts.cl_connect =mei_secs_to_jiffies (MEI_CL_CONNECT_TIMEOUT_SLOW ); + dev->timeouts.hbm =mei_secs_to_jiffies (MEI_HBM_TIMEOUT_SLOW ); + dev->timeouts.mkhi_recv =msecs_to_jiffies (MKHI_RCV_TIMEOUT_SLOW ); + }else { + dev->timeouts.cl_connect =mei_secs_to_jiffies (MEI_CL_CONNECT_TIMEOUT ); + dev->timeouts.hbm =mei_secs_to_jiffies (MEI_HBM_TIMEOUT ); + dev->timeouts.mkhi_recv =msecs_to_jiffies (MKHI_RCV_TIMEOUT ); + } }EXPORT_SYMBOL_GPL (mei_device_init);drivers/misc/mei/main.c +2
-2@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2003-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ @@ -571,7 +571,7 @@ static int mei_ioctl_connect_vtag(struct file *file, cl->state ==MEI_FILE_DISCONNECTED || cl->state ==MEI_FILE_DISCONNECT_REQUIRED || cl->state == MEI_FILE_DISCONNECT_REPLY), - mei_secs_to_jiffies(MEI_CL_CONNECT_TIMEOUT)); + dev->timeouts.cl_connect);mutex_lock (&dev->device_lock); }drivers/misc/mei/mei_dev.h +17
-1@@ -1,6 +1,6 @@/* SPDX-License-Identifier: GPL-2.0 */ /* -* Copyright (c) 2003-2019, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ @@ -415,6 +415,17 @@ struct mei_fw_version {#define MEI_MAX_FW_VER_BLOCKS 3 +struct mei_dev_timeouts { +unsigned long hw_ready;/* Timeout on ready message, in jiffies */ +int connect;/* HPS: at least 2 seconds, in seconds */ +unsigned long cl_connect;/* HPS: Client Connect Timeout, in jiffies */ +int client_init;/* HPS: Clients Enumeration Timeout, in seconds */ +unsigned long pgi;/* PG Isolation time response, in jiffies */ +unsigned int d0i3;/* D0i3 set/unset max response time, in jiffies */ +unsigned long hbm;/* HBM operation timeout, in jiffies */ +unsigned long mkhi_recv;/* receive timeout, in jiffies */ +}; +/** * struct mei_device - MEI private device struct * @@ -480,6 +491,8 @@ struct mei_fw_version {* @allow_fixed_address: allow user space to connect a fixed client * @override_fixed_address: force allow fixed address behavior * +* @timeouts: actual timeout values +* * @reset_work : work item for the device reset * @bus_rescan_work : work item for the bus rescan * @@ -568,6 +581,8 @@ struct mei_device {bool allow_fixed_address;bool override_fixed_address; +struct mei_dev_timeouts timeouts; +struct work_struct reset_work;struct work_struct bus_rescan_work;@@ -632,6 +647,7 @@ static inline u32 mei_slots2data(int slots)*/ void mei_device_init (struct mei_device *dev,struct device *device, +bool slow_fw,const struct mei_hw_ops *hw_ops);int mei_reset (struct mei_device *dev);int mei_start (struct mei_device *dev);drivers/misc/mei/pci-me.c +2
-2@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2003-2020, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ @@ -203,7 +203,7 @@ static int mei_me_probe(struct pci_dev *pdev, const struct pci_device_id *ent) }/* allocates and initializes the mei dev structure */ - dev =mei_me_dev_init (&pdev->dev, cfg); + dev =mei_me_dev_init (&pdev->dev, cfg, false);if (!dev) { err = -ENOMEM ; goto end;
PATCH v8 9/16 mei: bus: export common mkhi definitions into a separate header
In reply to Tomas WinklerFrom: Vitaly Lubart <[email protected]>
Exported common mkhi definitions from bus-fixup.c into a separate header file mkhi.h for other driver usage.
--- drivers/misc/mei/bus-fixup.c | 31 +------------------- drivers/misc/mei/mkhi.h | 57 ++++++++++++++++++++++++++++++++++++ 2 files changed, 58 insertions(+), 30 deletions(-) create mode 100644 drivers/misc/mei/mkhi.h
drivers/misc/mei/bus-fixup.c +1 -30
@@ -15,6 +15,7 @@#include "mei_dev.h" #include "client.h" +#include "mkhi.h" #define MEI_UUID_NFC_INFO UUID_LE(0xd2de1625, 0x382d, 0x417d, \ 0x48, 0xa4, 0xef, 0xab, 0xba, 0x8a, 0x12, 0x06)
@@ -89,20 +90,6 @@ struct mei_os_ver {u8 reserved2; } __packed; -#define MKHI_FEATURE_PTT 0x10 - -struct mkhi_rule_id { -__le16 rule_type; -u8 feature_id; -u8 reserved; -} __packed; - -struct mkhi_fwcaps { -struct mkhi_rule_id id; -u8 len; -u8 data[]; -} __packed; -struct mkhi_fw_ver_block {u16 minor;u8 major;
@@ -115,22 +102,6 @@ struct mkhi_fw_ver {struct mkhi_fw_ver_block ver[MEI_MAX_FW_VER_BLOCKS ]; } __packed; -#define MKHI_FWCAPS_GROUP_ID 0x3 -#define MKHI_FWCAPS_SET_OS_VER_APP_RULE_CMD 6 -#define MKHI_GEN_GROUP_ID 0xFF -#define MKHI_GEN_GET_FW_VERSION_CMD 0x2 -struct mkhi_msg_hdr { -u8 group_id; -u8 command; -u8 reserved; -u8 result; -} __packed; - -struct mkhi_msg { -struct mkhi_msg_hdr hdr; -u8 data[]; -} __packed; -#define MKHI_OSVER_BUF_LEN (sizeof(struct mkhi_msg_hdr) + \ sizeof(struct mkhi_fwcaps) + \ sizeof(struct mei_os_ver))
drivers/misc/mei/mkhi.h new file +57 -0
57 lines not on this page · raw message
Signature · 1 line
2.37.2
Re: [Intel-gfx] [PATCH v8 09/16] mei: bus: export common mkhi definitions into a separate header
Quoted 97 lines · Tomas Winkler
From: Vitaly Lubart <[email protected]>
Exported common mkhi definitions from
bus-fixup.cinto a separate header filemkhi.hfor other driver usage.Signed-off-by Vitaly Lubart <[email protected]>Signed-off-by Tomas Winkler <[email protected]>Signed-off-by Alexander Usyskin <[email protected]>--- drivers/misc/mei/bus-fixup.c | 31 +------------------- drivers/misc/mei/mkhi.h | 57 ++++++++++++++++++++++++++++++++++++ 2 files changed, 58 insertions(+), 30 deletions(-)create mode 100644
drivers/misc/mei/mkhi.hdrivers/misc/mei/bus-fixup.c +1
-30@@ -15,6 +15,7 @@#include "mei_dev.h" #include "client.h" +#include "mkhi.h" #define MEI_UUID_NFC_INFO UUID_LE(0xd2de1625, 0x382d, 0x417d, \ 0x48, 0xa4, 0xef, 0xab, 0xba, 0x8a, 0x12, 0x06)@@ -89,20 +90,6 @@ struct mei_os_ver {u8 reserved2; } __packed; -#define MKHI_FEATURE_PTT 0x10 - -struct mkhi_rule_id { -__le16 rule_type; -u8 feature_id; -u8 reserved; -} __packed; - -struct mkhi_fwcaps { -struct mkhi_rule_id id; -u8 len; -u8 data[]; -} __packed; -struct mkhi_fw_ver_block {u16 minor;u8 major;@@ -115,22 +102,6 @@ struct mkhi_fw_ver {struct mkhi_fw_ver_block ver[MEI_MAX_FW_VER_BLOCKS ]; } __packed; -#define MKHI_FWCAPS_GROUP_ID 0x3 -#define MKHI_FWCAPS_SET_OS_VER_APP_RULE_CMD 6 -#define MKHI_GEN_GROUP_ID 0xFF -#define MKHI_GEN_GET_FW_VERSION_CMD 0x2 -struct mkhi_msg_hdr { -u8 group_id; -u8 command; -u8 reserved; -u8 result; -} __packed; - -struct mkhi_msg { -struct mkhi_msg_hdr hdr; -u8 data[]; -} __packed; -#define MKHI_OSVER_BUF_LEN (sizeof(struct mkhi_msg_hdr) + \ sizeof(struct mkhi_fwcaps) + \ sizeof(struct mei_os_ver))drivers/misc/mei/mkhi.h new file +21
-0@@ -0,0 +1,57 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. +* Intel Management Engine Interface (Intel MEI) Linux driver +*/ + +#ifndef _MEI_MKHI_H_ +#define _MEI_MKHI_H_ + +#include <linux/types.h> + +#define MKHI_FEATURE_PTT 0x10 + +#define MKHI_FWCAPS_GROUP_ID 0x3 +#define MKHI_FWCAPS_SET_OS_VER_APP_RULE_CMD 6 +#define MKHI_GEN_GROUP_ID 0xFF +#define MKHI_GEN_GET_FW_VERSION_CMD 0x2 + +#define MKHI_GROUP_ID_GFX 0x30 +#define MKHI_GFX_RESET_WARN_CMD_REQ 0x0 +#define MKHI_GFX_MEMORY_READY_CMD_REQ 0x1
drivers/misc/mei/mkhi.h line 31
Quoted 10 lines
drivers/misc/mei/mkhi.h new file +10
-0+ +/* Allow transition to PXP mode without approval */ +#define MKHI_GFX_MEM_READY_PXP_ALLOWED 0x1 + +#define MKHI_GROUP_ID_GFX 0x30 +#define MKHI_GFX_RESET_WARN_CMD_REQ 0x0 +#define MKHI_GFX_MEMORY_READY_CMD_REQ 0x1 + +/* Allow transition to PXP mode without approval */ +#define MKHI_GFX_MEM_READY_PXP_ALLOWED 0x1
Something weird is happening here. Those defs were added by the next patch in the previous rev, while now they're added here twice and then still added once more in the next patch, so they're defined 3 times. IMO leaving it to the next patch is better, so they should just be dropped from this one.
Daniele
Quoted 26 lines
drivers/misc/mei/mkhi.h new file +26
-0+ +struct mkhi_rule_id { +__le16 rule_type; +u8 feature_id; +u8 reserved; +} __packed; + +struct mkhi_fwcaps { +struct mkhi_rule_id id; +u8 len; +u8 data[]; +} __packed; + +struct mkhi_msg_hdr { +u8 group_id; +u8 command; +u8 reserved; +u8 result; +} __packed; + +struct mkhi_msg { +struct mkhi_msg_hdr hdr; +u8 data[]; +} __packed; + +#endif /* _MEI_MKHI_H_ */
RE: [Intel-gfx] [PATCH v8 09/16] mei: bus: export common mkhi definitions into a separate header
Quoted 108 lines · Tomas Winkler
Quoted 11 lines
From: Vitaly Lubart <[email protected]>
Exported common mkhi definitions from
bus-fixup.cinto a separate header filemkhi.hfor other driver usage.Signed-off-by Vitaly Lubart <[email protected]>Signed-off-by Tomas Winkler <[email protected]>Signed-off-by Alexander Usyskin <[email protected]>--- drivers/misc/mei/bus-fixup.c | 31 +------------------- drivers/misc/mei/mkhi.h | 57++++++++++++++++++++++++++++++++++++
Quoted 8 lines
2 files changed, 58 insertions(+), 30 deletions(-)create mode 100644
drivers/misc/mei/mkhi.h(quoted diff) +0
-0
b/drivers/misc/mei/bus-fixup.cindex344598fcf8e9..c4e527803299100644drivers/misc/mei/bus-fixup.c line 21
Quoted 7 lines
drivers/misc/mei/bus-fixup.c +1
-0@@ -15,6 +15,7 @@#include "mei_dev.h" #include "client.h" +#include "mkhi.h" #define MEI_UUID_NFC_INFO UUID_LE(0xd2de1625, 0x382d, 0x417d, \ 0x48, 0xa4, 0xef, 0xab, 0xba, 0x8a, 0x12, 0x06) @@ -89,20 +90,6
Quoted 27 lines
@@ struct
mei_os_ver{
u8 reserved2;
}__packed;drivers/misc/mei/bus-fixup.c +0
-16-#define MKHI_FEATURE_PTT 0x10 - -struct mkhi_rule_id { -__le16 rule_type; -u8 feature_id; -u8 reserved; -} __packed; - -struct mkhi_fwcaps { -struct mkhi_rule_id id; -u8 len; -u8 data[]; -} __packed; -struct mkhi_fw_ver_block {u16 minor;u8 major;@@ -115,22 +102,6 @@ struct mkhi_fw_ver {struct mkhi_fw_ver_block ver[MEI_MAX_FW_VER_BLOCKS ]; } __packed; -#define MKHI_FWCAPS_GROUP_ID 0x3 -#define MKHI_FWCAPS_SET_OS_VER_APP_RULE_CMD 6 -#defineQuoted 1 line
MKHI_GEN_GROUP_ID0xFF-#define
MKHI_GEN_GET_FW_VERSION_CMD0x2Quoted 25 lines
drivers/misc/mei/bus-fixup.c +0
-12-struct mkhi_msg_hdr { -u8 group_id; -u8 command; -u8 reserved; -u8 result; -} __packed; - -struct mkhi_msg { -struct mkhi_msg_hdr hdr; -u8 data[]; -} __packed; -#define MKHI_OSVER_BUF_LEN (sizeof(struct mkhi_msg_hdr) + \ sizeof(struct mkhi_fwcaps) + \ sizeof(struct mei_os_ver))drivers/misc/mei/mkhi.h new renamed from drivers/misc/mei/mkhi.h +0
-0file mode 100644 index 000000000000..43cadfb1b990
drivers/misc/mei/mkhi.h new file +5
-0@@ -0,0 +1,57 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. +* Intel Management Engine Interface (Intel MEI) Linux driver */ +drivers/misc/mei/mkhi.h line 15
Quoted 10 lines
drivers/misc/mei/mkhi.h new file +10
-0+#ifndef _MEI_MKHI_H_ +#define _MEI_MKHI_H_ + +#include <linux/types.h> + +#define MKHI_FEATURE_PTT 0x10 + +#define MKHI_FWCAPS_GROUP_ID 0x3 +#define MKHI_FWCAPS_SET_OS_VER_APP_RULE_CMD 6 #define +MKHI_GEN_GROUP_ID 0xFF #define
MKHI_GEN_GET_FW_VERSION_CMD0x2Quoted 11 lines
drivers/misc/mei/mkhi.h new file +11
-0+ +#define MKHI_GROUP_ID_GFX 0x30 +#define MKHI_GFX_RESET_WARN_CMD_REQ 0x0 +#define MKHI_GFX_MEMORY_READY_CMD_REQ 0x1 + +/* Allow transition to PXP mode without approval */ #define +MKHI_GFX_MEM_READY_PXP_ALLOWED 0x1 + +#define MKHI_GROUP_ID_GFX 0x30 +#define MKHI_GFX_RESET_WARN_CMD_REQ 0x0 +#define MKHI_GFX_MEMORY_READY_CMD_REQ 0x1
Quoted 8 lines
drivers/misc/mei/mkhi.h line 29
Quoted 3 lines
drivers/misc/mei/mkhi.h new file +3
-0+ +/* Allow transition to PXP mode without approval */ #define +MKHI_GFX_MEM_READY_PXP_ALLOWED 0x1Something weird is happening here. Those defs were added by the next patch in the previous rev, while now they're added here twice and then still added once more in the next patch, so they're defined 3 times. IMO leaving it to the next patch is better, so they should just be dropped from this one.
You are right, bad --amend :(
Quoted 29 lines
Daniele
Quoted 26 lines
drivers/misc/mei/mkhi.h new file +26
-0+ +struct mkhi_rule_id { +__le16 rule_type; +u8 feature_id; +u8 reserved; +} __packed; + +struct mkhi_fwcaps { +struct mkhi_rule_id id; +u8 len; +u8 data[]; +} __packed; + +struct mkhi_msg_hdr { +u8 group_id; +u8 command; +u8 reserved; +u8 result; +} __packed; + +struct mkhi_msg { +struct mkhi_msg_hdr hdr; +u8 data[]; +} __packed; + +#endif /* _MEI_MKHI_H_ */
PATCH v8 10/16 mei: mkhi: add memory ready command
In reply to Tomas WinklerAdd GSC memory ready command.
The command indicates to the firmware that extend operation memory was setup and the firmware may enter PXP mode.
--- drivers/misc/mei/mkhi.h | 12 ++++++++++++ 1 file changed, 12 insertions(+)
drivers/misc/mei/mkhi.h +12 -0
@@ -30,6 +30,13 @@/* Allow transition to PXP mode without approval */ #define MKHI_GFX_MEM_READY_PXP_ALLOWED 0x1 +#define MKHI_GROUP_ID_GFX 0x30 +#define MKHI_GFX_RESET_WARN_CMD_REQ 0x0 +#define MKHI_GFX_MEMORY_READY_CMD_REQ 0x1 + +/* Allow transition to PXP mode without approval */ +#define MKHI_GFX_MEM_READY_PXP_ALLOWED 0x1 +struct mkhi_rule_id {__le16 rule_type;u8 feature_id;
@@ -54,4 +61,9 @@ struct mkhi_msg { u8 data[]; } __packed; +struct mkhi_gfx_mem_ready { +struct mkhi_msg_hdr hdr; +u32 flags; +} __packed; +#endif /* _MEI_MKHI_H_ */
Signature · 1 line
2.37.2
PATCH v8 11/16 mei: gsc: setup gsc extended operational memory
In reply to Tomas Winkler1. Retrieve extended operational memory physical pointers from the auxiliary device info.
2. Setup memory registers.
3. Notify firmware that the memory is ready by sending the memory ready command.
4. Disable PXP device if GSC is not in PXP mode.
--- drivers/misc/mei/bus-fixup.c | 70 ++++++++++++++++++++++++++++++++++- drivers/misc/mei/gsc-me.c | 16 ++++++++ drivers/misc/mei/hw-me-regs.h | 9 ++++- drivers/misc/mei/hw-me.c | 28 +++++++++++++- drivers/misc/mei/init.c | 2 + drivers/misc/mei/mei_dev.h | 17 +++++++++ include/linux/mei_aux.h | 3 ++ 7 files changed, 141 insertions(+), 4 deletions(-)
drivers/misc/mei/bus-fixup.c +68 -2
@@ -188,6 +188,19 @@ static int mei_fwver(struct mei_cl_device *cldev)return ret; } +static int mei_gfx_memory_ready (struct mei_cl_device *cldev) +{ +struct mkhi_gfx_mem_ready req = {0 }; +unsigned int mode =MEI_CL_IO_TX_INTERNAL ; + + req.hdr.group_id =MKHI_GROUP_ID_GFX ; + req.hdr.command =MKHI_GFX_MEMORY_READY_CMD_REQ ; + req.flags =MKHI_GFX_MEM_READY_PXP_ALLOWED ; + +dev_dbg (&cldev->dev,"Sending memory ready command\n" ); +return __mei_cl_send (cldev->cl, (u8 *)&req,sizeof (req),0 , mode); +} +static void mei_mkhi_fix (struct mei_cl_device *cldev) {int ret;
@@ -234,6 +247,39 @@ static void mei_gsc_mkhi_ver(struct mei_cl_device *cldev)dev_err (&cldev->dev,"FW version command failed %d\n" , ret);mei_cldev_disable (cldev); } + +static void mei_gsc_mkhi_fix_ver (struct mei_cl_device *cldev) +{ +int ret; + +/* No need to enable the client if nothing is needed from it */ +if (!cldev->bus->fw_f_fw_ver_supported && + cldev->bus->pxp_mode !=MEI_DEV_PXP_INIT ) +return ; + + ret =mei_cldev_enable (cldev); +if (ret) +return ; + +if (cldev->bus->pxp_mode ==MEI_DEV_PXP_INIT ) { + ret =mei_gfx_memory_ready (cldev); +if (ret <0 ) +dev_err (&cldev->dev,"memory ready command failed %d\n" , ret); +else +dev_dbg (&cldev->dev,"memory ready command sent\n" ); +/* we go to reset after that */ + cldev->bus->pxp_mode =MEI_DEV_PXP_SETUP ; + goto out; + } + + ret =mei_fwver (cldev); +if (ret <0 ) +dev_err (&cldev->dev,"FW version command failed %d\n" , + ret); +out: +mei_cldev_disable (cldev); +} +/** * mei_wd - wd client on the bus, change protocol version * as the API has changed.
@@ -473,6 +519,26 @@ static void vt_support(struct mei_cl_device *cldev) cldev->do_match =1 ; } +/** +* pxp_is_ready - enable bus client if pxp is ready +* +* @cldev: me clients device +*/ +static void pxp_is_ready (struct mei_cl_device *cldev) +{ +struct mei_device *bus = cldev->bus; + +switch (bus->pxp_mode) { +case MEI_DEV_PXP_READY : +case MEI_DEV_PXP_DEFAULT : + cldev->do_match =1 ; +break ; +default : + cldev->do_match =0 ; +break ; + } +} +#define MEI_FIXUP (_uuid, _hook) { _uuid, _hook } static struct mei_fixup {
@@ -486,10 +552,10 @@ static struct mei_fixup {MEI_FIXUP (MEI_UUID_WD , mei_wd),MEI_FIXUP (MEI_UUID_MKHIF_FIX , mei_mkhi_fix),MEI_FIXUP (MEI_UUID_IGSC_MKHI , mei_gsc_mkhi_ver), -MEI_FIXUP (MEI_UUID_IGSC_MKHI_FIX , mei_gsc_mkhi_ver), +MEI_FIXUP (MEI_UUID_IGSC_MKHI_FIX , mei_gsc_mkhi_fix_ver),MEI_FIXUP (MEI_UUID_HDCP , whitelist),MEI_FIXUP (MEI_UUID_ANY , vt_support), - MEI_FIXUP(MEI_UUID_PAVP, whitelist), + MEI_FIXUP(MEI_UUID_PAVP, pxp_is_ready), };/**
drivers/misc/mei/gsc-me.c +16 -0
@@ -32,6 +32,17 @@ static int mei_gsc_read_hfs(const struct mei_device *dev, int where, u32 *val)return 0 ; } +static void mei_gsc_set_ext_op_mem (const struct mei_me_hw *hw,struct resource *mem) +{ +u32 low =lower_32_bits (mem->start); +u32 hi =upper_32_bits (mem->start); +u32 limit = (resource_size (mem) /SZ_4K ) |GSC_EXT_OP_MEM_VALID ; + +iowrite32 (low, hw->mem_addr +H_GSC_EXT_OP_MEM_BASE_ADDR_LO_REG ); +iowrite32 (hi, hw->mem_addr +H_GSC_EXT_OP_MEM_BASE_ADDR_HI_REG ); +iowrite32 (limit, hw->mem_addr +H_GSC_EXT_OP_MEM_LIMIT_REG ); +} +static int mei_gsc_probe (struct auxiliary_device *aux_dev,const struct auxiliary_device_id *aux_dev_id) {
@@ -67,6 +78,11 @@ static int mei_gsc_probe(struct auxiliary_device *aux_dev,dev_set_drvdata (device, dev); +if (adev->ext_op_mem.start) { +mei_gsc_set_ext_op_mem (hw, &adev->ext_op_mem); + dev->pxp_mode =MEI_DEV_PXP_INIT ; + } +/* use polling */ if (mei_me_hw_use_polling (hw)) {mei_disable_interrupts (dev);
drivers/misc/mei/hw-me-regs.h +8 -1
@@ -1,6 +1,6 @@/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */ /* -* Copyright (c) 2003-2019, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ #ifndef _MEI_HW_MEI_REGS_H_
@@ -127,6 +127,8 @@# define PCI_CFG_HFS_3_FW_SKU_SPS 0x00000060#define PCI_CFG_HFS_4 0x64#define PCI_CFG_HFS_5 0x68 +# define GSC_CFG_HFS_5_BOOT_TYPE_MSK 0x00000003 +# define GSC_CFG_HFS_5_BOOT_TYPE_PXP 3#define PCI_CFG_HFS_6 0x6C/* MEI registers */
@@ -143,6 +145,11 @@/* H_D0I3C - D0I3 Control */ #define H_D0I3C 0x800 +#define H_GSC_EXT_OP_MEM_BASE_ADDR_LO_REG 0x100 +#define H_GSC_EXT_OP_MEM_BASE_ADDR_HI_REG 0x104 +#define H_GSC_EXT_OP_MEM_LIMIT_REG 0x108 +#define GSC_EXT_OP_MEM_VALID BIT(31) +/* register bits of H_CSR (Host Control Status register) */ /* Host Circular Buffer Depth - maximum number of 32-bit entries in CB */ #define H_CBD 0xFF000000
drivers/misc/mei/hw-me.c +27 -1
@@ -433,6 +433,29 @@ static bool mei_me_hw_is_resetting(struct mei_device *dev)return (mecsr &ME_RST_HRA ) ==ME_RST_HRA ; } +/** +* mei_gsc_pxp_check - check for gsc firmware entering pxp mode +* +* @dev: the device structure +*/ +static void mei_gsc_pxp_check (struct mei_device *dev) +{ +struct mei_me_hw *hw =to_me_hw (dev); +u32 fwsts5 =0 ; + +if (dev->pxp_mode ==MEI_DEV_PXP_DEFAULT ) +return ; + + hw->read_fws (dev,PCI_CFG_HFS_5 , &fwsts5); +trace_mei_pci_cfg_read (dev->dev,"PCI_CFG_HFS_5" ,PCI_CFG_HFS_5 , fwsts5); +if ((fwsts5 &GSC_CFG_HFS_5_BOOT_TYPE_MSK ) ==GSC_CFG_HFS_5_BOOT_TYPE_PXP ) { +dev_dbg (dev->dev,"pxp mode is ready 0x%08x\n" , fwsts5); + dev->pxp_mode =MEI_DEV_PXP_READY ; + }else { +dev_dbg (dev->dev,"pxp mode is not ready 0x%08x\n" , fwsts5); + } +} +/** * mei_me_hw_ready_wait - wait until the me(hw) has turned ready * or timeout is reached
@@ -452,6 +475,8 @@ static int mei_me_hw_ready_wait(struct mei_device *dev)return -ETIME ; } +mei_gsc_pxp_check (dev); +mei_me_hw_reset_release (dev); dev->recvd_hw_ready = false;return 0 ;
@@ -1270,7 +1295,8 @@ irqreturn_t mei_me_irq_thread_handler(int irq, void *dev_id)/* check if ME wants a reset */ if (!mei_hw_is_ready (dev) && dev->dev_state !=MEI_DEV_RESETTING ) { -dev_warn (dev->dev,"FW not ready: resetting.\n" ); +dev_warn (dev->dev,"FW not ready: resetting: dev_state = %d pxp = %d\n" , + dev->dev_state, dev->pxp_mode);if (dev->dev_state ==MEI_DEV_POWERING_DOWN || dev->dev_state ==MEI_DEV_POWER_DOWN )mei_cl_all_disconnect (dev);
drivers/misc/mei/init.c +2 -0
@@ -397,6 +397,8 @@ void mei_device_init(struct mei_device *dev,bitmap_zero (dev->host_clients_map,MEI_CLIENTS_MAX ); dev->open_handle_count =0 ; + dev->pxp_mode =MEI_DEV_PXP_DEFAULT ; +/* * Reserving the first client ID * 0: Reserved for MEI Bus Message communications
drivers/misc/mei/mei_dev.h +17 -0
@@ -62,6 +62,21 @@ enum mei_dev_state {MEI_DEV_POWER_UP }; +/** +* enum mei_dev_pxp_mode - MEI PXP mode state +* +* @MEI_DEV_PXP_DEFAULT: PCH based device, no initailization required +* @MEI_DEV_PXP_INIT: device requires initialization, send setup message to firmware +* @MEI_DEV_PXP_SETUP: device is in setup stage, waiting for firmware repsonse +* @MEI_DEV_PXP_READY: device initialized +*/ +enum mei_dev_pxp_mode { +MEI_DEV_PXP_DEFAULT =0 , +MEI_DEV_PXP_INIT =1 , +MEI_DEV_PXP_SETUP =2 , +MEI_DEV_PXP_READY =3 , +}; +const char *mei_dev_state_str (int state);enum mei_file_transaction_states {
@@ -454,6 +469,7 @@ struct mei_dev_timeouts {* @reset_count : number of consecutive resets * @dev_state : device state * @hbm_state : state of host bus message protocol +* @pxp_mode : PXP device mode * @init_clients_timer : HBM init handshake timeout * * @pg_event : power gating event
@@ -537,6 +553,7 @@ struct mei_device {unsigned long reset_count;enum mei_dev_state dev_state;enum mei_hbm_state hbm_state; +enum mei_dev_pxp_mode pxp_mode;u16 init_clients_timer;/*
include/linux/mei_aux.h +3 -0
@@ -12,6 +12,8 @@* @aux_dev: - auxiliary device object * @irq: interrupt driving the mei auxiliary device * @bar: mmio resource bar reserved to mei auxiliary device +* @ext_op_mem: resource for extend operational memory +* used in graphics PXP mode. * @slow_firmware: The device has slow underlying firmware. * Such firmware will require to use larger operation timeouts. */
@@ -19,6 +21,7 @@ struct mei_aux_device {struct auxiliary_device aux_dev;int irq;struct resource bar; +struct resource ext_op_mem;bool slow_firmware; };
Signature · 1 line
2.37.2
Re: [PATCH v8 11/16] mei: gsc: setup gsc extended operational memory
Quoted 10 lines · Tomas Winkler
1. Retrieve extended operational memory physical pointers from the auxiliary device info.
2. Setup memory registers.
3. Notify firmware that the memory is ready by sending the memory ready command.
4. Disable PXP device if GSC is not in PXP mode.CC Daniele Ceraolo Spurio <[email protected]>Signed-off-by Tomas Winkler <[email protected]>Signed-off-by Alexander Usyskin <[email protected]>
only minor changes from the previously reviewed rev and they LGTM, so my r-b stands:
Daniele
Quoted 310 lines
--- drivers/misc/mei/bus-fixup.c | 70 ++++++++++++++++++++++++++++++++++- drivers/misc/mei/gsc-me.c | 16 ++++++++ drivers/misc/mei/hw-me-regs.h | 9 ++++- drivers/misc/mei/hw-me.c | 28 +++++++++++++- drivers/misc/mei/init.c | 2 + drivers/misc/mei/mei_dev.h | 17 +++++++++ include/linux/mei_aux.h | 3 ++ 7 files changed, 141 insertions(+), 4 deletions(-)drivers/misc/mei/bus-fixup.c +68
-2@@ -188,6 +188,19 @@ static int mei_fwver(struct mei_cl_device *cldev)return ret; } +static int mei_gfx_memory_ready (struct mei_cl_device *cldev) +{ +struct mkhi_gfx_mem_ready req = {0 }; +unsigned int mode =MEI_CL_IO_TX_INTERNAL ; + + req.hdr.group_id =MKHI_GROUP_ID_GFX ; + req.hdr.command =MKHI_GFX_MEMORY_READY_CMD_REQ ; + req.flags =MKHI_GFX_MEM_READY_PXP_ALLOWED ; + +dev_dbg (&cldev->dev,"Sending memory ready command\n" ); +return __mei_cl_send (cldev->cl, (u8 *)&req,sizeof (req),0 , mode); +} +static void mei_mkhi_fix (struct mei_cl_device *cldev) {int ret;@@ -234,6 +247,39 @@ static void mei_gsc_mkhi_ver(struct mei_cl_device *cldev)dev_err (&cldev->dev,"FW version command failed %d\n" , ret);mei_cldev_disable (cldev); } + +static void mei_gsc_mkhi_fix_ver (struct mei_cl_device *cldev) +{ +int ret; + +/* No need to enable the client if nothing is needed from it */ +if (!cldev->bus->fw_f_fw_ver_supported && + cldev->bus->pxp_mode !=MEI_DEV_PXP_INIT ) +return ; + + ret =mei_cldev_enable (cldev); +if (ret) +return ; + +if (cldev->bus->pxp_mode ==MEI_DEV_PXP_INIT ) { + ret =mei_gfx_memory_ready (cldev); +if (ret <0 ) +dev_err (&cldev->dev,"memory ready command failed %d\n" , ret); +else +dev_dbg (&cldev->dev,"memory ready command sent\n" ); +/* we go to reset after that */ + cldev->bus->pxp_mode =MEI_DEV_PXP_SETUP ; + goto out; + } + + ret =mei_fwver (cldev); +if (ret <0 ) +dev_err (&cldev->dev,"FW version command failed %d\n" , + ret); +out: +mei_cldev_disable (cldev); +} +/** * mei_wd - wd client on the bus, change protocol version * as the API has changed. @@ -473,6 +519,26 @@ static void vt_support(struct mei_cl_device *cldev) cldev->do_match =1 ; } +/** +* pxp_is_ready - enable bus client if pxp is ready +* +* @cldev: me clients device +*/ +static void pxp_is_ready (struct mei_cl_device *cldev) +{ +struct mei_device *bus = cldev->bus; + +switch (bus->pxp_mode) { +case MEI_DEV_PXP_READY : +case MEI_DEV_PXP_DEFAULT : + cldev->do_match =1 ; +break ; +default : + cldev->do_match =0 ; +break ; + } +} +#define MEI_FIXUP (_uuid, _hook) { _uuid, _hook } static struct mei_fixup {@@ -486,10 +552,10 @@ static struct mei_fixup {MEI_FIXUP (MEI_UUID_WD , mei_wd),MEI_FIXUP (MEI_UUID_MKHIF_FIX , mei_mkhi_fix),MEI_FIXUP (MEI_UUID_IGSC_MKHI , mei_gsc_mkhi_ver), -MEI_FIXUP (MEI_UUID_IGSC_MKHI_FIX , mei_gsc_mkhi_ver), +MEI_FIXUP (MEI_UUID_IGSC_MKHI_FIX , mei_gsc_mkhi_fix_ver),MEI_FIXUP (MEI_UUID_HDCP , whitelist),MEI_FIXUP (MEI_UUID_ANY , vt_support), - MEI_FIXUP(MEI_UUID_PAVP, whitelist), + MEI_FIXUP(MEI_UUID_PAVP, pxp_is_ready), };/** drivers/misc/mei/gsc-me.c +16
-0@@ -32,6 +32,17 @@ static int mei_gsc_read_hfs(const struct mei_device *dev, int where, u32 *val)return 0 ; } +static void mei_gsc_set_ext_op_mem (const struct mei_me_hw *hw,struct resource *mem) +{ +u32 low =lower_32_bits (mem->start); +u32 hi =upper_32_bits (mem->start); +u32 limit = (resource_size (mem) /SZ_4K ) |GSC_EXT_OP_MEM_VALID ; + +iowrite32 (low, hw->mem_addr +H_GSC_EXT_OP_MEM_BASE_ADDR_LO_REG ); +iowrite32 (hi, hw->mem_addr +H_GSC_EXT_OP_MEM_BASE_ADDR_HI_REG ); +iowrite32 (limit, hw->mem_addr +H_GSC_EXT_OP_MEM_LIMIT_REG ); +} +static int mei_gsc_probe (struct auxiliary_device *aux_dev,const struct auxiliary_device_id *aux_dev_id) {@@ -67,6 +78,11 @@ static int mei_gsc_probe(struct auxiliary_device *aux_dev,dev_set_drvdata (device, dev); +if (adev->ext_op_mem.start) { +mei_gsc_set_ext_op_mem (hw, &adev->ext_op_mem); + dev->pxp_mode =MEI_DEV_PXP_INIT ; + } +/* use polling */ if (mei_me_hw_use_polling (hw)) {mei_disable_interrupts (dev);drivers/misc/mei/hw-me-regs.h +8
-1@@ -1,6 +1,6 @@/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */ /* -* Copyright (c) 2003-2019, Intel Corporation. All rights reserved. +* Copyright (c) 2003-2022, Intel Corporation. All rights reserved. * Intel Management Engine Interface (Intel MEI) Linux driver */ #ifndef _MEI_HW_MEI_REGS_H_@@ -127,6 +127,8 @@# define PCI_CFG_HFS_3_FW_SKU_SPS 0x00000060#define PCI_CFG_HFS_4 0x64#define PCI_CFG_HFS_5 0x68 +# define GSC_CFG_HFS_5_BOOT_TYPE_MSK 0x00000003 +# define GSC_CFG_HFS_5_BOOT_TYPE_PXP 3#define PCI_CFG_HFS_6 0x6C/* MEI registers */ @@ -143,6 +145,11 @@/* H_D0I3C - D0I3 Control */ #define H_D0I3C 0x800 +#define H_GSC_EXT_OP_MEM_BASE_ADDR_LO_REG 0x100 +#define H_GSC_EXT_OP_MEM_BASE_ADDR_HI_REG 0x104 +#define H_GSC_EXT_OP_MEM_LIMIT_REG 0x108 +#define GSC_EXT_OP_MEM_VALID BIT(31) +/* register bits of H_CSR (Host Control Status register) */ /* Host Circular Buffer Depth - maximum number of 32-bit entries in CB */ #define H_CBD 0xFF000000drivers/misc/mei/hw-me.c +27
-1@@ -433,6 +433,29 @@ static bool mei_me_hw_is_resetting(struct mei_device *dev)return (mecsr &ME_RST_HRA ) ==ME_RST_HRA ; } +/** +* mei_gsc_pxp_check - check for gsc firmware entering pxp mode +* +* @dev: the device structure +*/ +static void mei_gsc_pxp_check (struct mei_device *dev) +{ +struct mei_me_hw *hw =to_me_hw (dev); +u32 fwsts5 =0 ; + +if (dev->pxp_mode ==MEI_DEV_PXP_DEFAULT ) +return ; + + hw->read_fws (dev,PCI_CFG_HFS_5 , &fwsts5); +trace_mei_pci_cfg_read (dev->dev,"PCI_CFG_HFS_5" ,PCI_CFG_HFS_5 , fwsts5); +if ((fwsts5 &GSC_CFG_HFS_5_BOOT_TYPE_MSK ) ==GSC_CFG_HFS_5_BOOT_TYPE_PXP ) { +dev_dbg (dev->dev,"pxp mode is ready 0x%08x\n" , fwsts5); + dev->pxp_mode =MEI_DEV_PXP_READY ; + }else { +dev_dbg (dev->dev,"pxp mode is not ready 0x%08x\n" , fwsts5); + } +} +/** * mei_me_hw_ready_wait - wait until the me(hw) has turned ready * or timeout is reached @@ -452,6 +475,8 @@ static int mei_me_hw_ready_wait(struct mei_device *dev)return -ETIME ; } +mei_gsc_pxp_check (dev); +mei_me_hw_reset_release (dev); dev->recvd_hw_ready = false;return 0 ;@@ -1270,7 +1295,8 @@ irqreturn_t mei_me_irq_thread_handler(int irq, void *dev_id)/* check if ME wants a reset */ if (!mei_hw_is_ready (dev) && dev->dev_state !=MEI_DEV_RESETTING ) { -dev_warn (dev->dev,"FW not ready: resetting.\n" ); +dev_warn (dev->dev,"FW not ready: resetting: dev_state = %d pxp = %d\n" , + dev->dev_state, dev->pxp_mode);if (dev->dev_state ==MEI_DEV_POWERING_DOWN || dev->dev_state ==MEI_DEV_POWER_DOWN )mei_cl_all_disconnect (dev);drivers/misc/mei/init.c +2
-0@@ -397,6 +397,8 @@ void mei_device_init(struct mei_device *dev,bitmap_zero (dev->host_clients_map,MEI_CLIENTS_MAX ); dev->open_handle_count =0 ; + dev->pxp_mode =MEI_DEV_PXP_DEFAULT ; +/* * Reserving the first client ID * 0: Reserved for MEI Bus Message communications drivers/misc/mei/mei_dev.h +17
-0@@ -62,6 +62,21 @@ enum mei_dev_state {MEI_DEV_POWER_UP }; +/** +* enum mei_dev_pxp_mode - MEI PXP mode state +* +* @MEI_DEV_PXP_DEFAULT: PCH based device, no initailization required +* @MEI_DEV_PXP_INIT: device requires initialization, send setup message to firmware +* @MEI_DEV_PXP_SETUP: device is in setup stage, waiting for firmware repsonse +* @MEI_DEV_PXP_READY: device initialized +*/ +enum mei_dev_pxp_mode { +MEI_DEV_PXP_DEFAULT =0 , +MEI_DEV_PXP_INIT =1 , +MEI_DEV_PXP_SETUP =2 , +MEI_DEV_PXP_READY =3 , +}; +const char *mei_dev_state_str (int state);enum mei_file_transaction_states {@@ -454,6 +469,7 @@ struct mei_dev_timeouts {* @reset_count : number of consecutive resets * @dev_state : device state * @hbm_state : state of host bus message protocol +* @pxp_mode : PXP device mode * @init_clients_timer : HBM init handshake timeout * * @pg_event : power gating event @@ -537,6 +553,7 @@ struct mei_device {unsigned long reset_count;enum mei_dev_state dev_state;enum mei_hbm_state hbm_state; +enum mei_dev_pxp_mode pxp_mode;u16 init_clients_timer;/* include/linux/mei_aux.h +3
-0@@ -12,6 +12,8 @@* @aux_dev: - auxiliary device object * @irq: interrupt driving the mei auxiliary device * @bar: mmio resource bar reserved to mei auxiliary device +* @ext_op_mem: resource for extend operational memory +* used in graphics PXP mode. * @slow_firmware: The device has slow underlying firmware. * Such firmware will require to use larger operation timeouts. */ @@ -19,6 +21,7 @@ struct mei_aux_device {struct auxiliary_device aux_dev;int irq;struct resource bar; +struct resource ext_op_mem;bool slow_firmware; };
PATCH v8 12/16 mei: gsc: add transition to PXP mode in resume flow
In reply to Tomas WinklerFrom: Vitaly Lubart <[email protected]>
Added transition to PXP mode in resume flow.
--- drivers/misc/mei/gsc-me.c | 11 +++++++++++ 1 file changed, 11 insertions(+)
drivers/misc/mei/gsc-me.c +11 -0
@@ -182,11 +182,22 @@ static int __maybe_unused mei_gsc_pm_suspend(struct device *device)static int __maybe_unused mei_gsc_pm_resume (struct device *device) {struct mei_device *dev =dev_get_drvdata (device); +struct auxiliary_device *aux_dev; +struct mei_aux_device *adev;int err; +struct mei_me_hw *hw;if (!dev)return -ENODEV ; + hw =to_me_hw (dev); + aux_dev =to_auxiliary_dev (device); + adev =auxiliary_dev_to_mei_aux_dev (aux_dev); +if (adev->ext_op_mem.start) { +mei_gsc_set_ext_op_mem (hw, &adev->ext_op_mem); + dev->pxp_mode =MEI_DEV_PXP_INIT ; + } + err =mei_restart (dev);if (err)return err;
Signature · 1 line
2.37.2
Re: [PATCH v8 12/16] mei: gsc: add transition to PXP mode in resume flow
Quoted 8 lines · Tomas Winkler
From: Vitaly Lubart <[email protected]>
Added transition to PXP mode in resume flow.
CC Daniele Ceraolo Spurio <[email protected]>Signed-off-by Vitaly Lubart <[email protected]>Signed-off-by Tomas Winkler <[email protected]>Signed-off-by Alexander Usyskin <[email protected]>
This is unchanged from the previously reviewed rev, so this still applies:
Daniele
Quoted 31 lines
--- drivers/misc/mei/gsc-me.c | 11 +++++++++++ 1 file changed, 11 insertions(+)drivers/misc/mei/gsc-me.c +11
-0@@ -182,11 +182,22 @@ static int __maybe_unused mei_gsc_pm_suspend(struct device *device)static int __maybe_unused mei_gsc_pm_resume (struct device *device) {struct mei_device *dev =dev_get_drvdata (device); +struct auxiliary_device *aux_dev; +struct mei_aux_device *adev;int err; +struct mei_me_hw *hw;if (!dev)return -ENODEV ; + hw =to_me_hw (dev); + aux_dev =to_auxiliary_dev (device); + adev =auxiliary_dev_to_mei_aux_dev (aux_dev); +if (adev->ext_op_mem.start) { +mei_gsc_set_ext_op_mem (hw, &adev->ext_op_mem); + dev->pxp_mode =MEI_DEV_PXP_INIT ; + } + err =mei_restart (dev);if (err)return err;
PATCH v8 13/16 mei: drop ready bits check after start
In reply to Tomas WinklerFrom: Alexander Usyskin <[email protected]>
The check that hardware and host ready bits are set after start is redundant and may fail and disable driver if there is back-to-back link reset issued right after start. This happens during pxp mode transitions when firmware undergo reset. Remove these checks to eliminate such failures.
--- drivers/misc/mei/init.c | 10 ---------- 1 file changed, 10 deletions(-)
drivers/misc/mei/init.c +0 -10
@@ -218,16 +218,6 @@ int mei_start(struct mei_device *dev) goto err; } -if (!mei_host_is_ready (dev)) { -dev_err (dev->dev,"host is not ready.\n" ); - goto err; - } - -if (!mei_hw_is_ready (dev)) { -dev_err (dev->dev,"ME is not ready.\n" ); - goto err; - } -if (!mei_hbm_version_is_supported (dev)) {dev_dbg (dev->dev,"MEI start failed.\n" ); goto err;
Signature · 1 line
2.37.2
Re: [Intel-gfx] [PATCH v8 13/16] mei: drop ready bits check after start
Quoted 10 lines · Tomas Winkler
From: Alexander Usyskin <[email protected]>
The check that hardware and host ready bits are set after start is redundant and may fail and disable driver if there is back-to-back link reset issued right after start. This happens during pxp mode transitions when firmware undergo reset. Remove these checks to eliminate such failures.
Signed-off-by Alexander Usyskin <[email protected]>Signed-off-by Tomas Winkler <[email protected]>
Daniele
Quoted 25 lines
--- drivers/misc/mei/init.c | 10 ---------- 1 file changed, 10 deletions(-)drivers/misc/mei/init.c +0
-10@@ -218,16 +218,6 @@ int mei_start(struct mei_device *dev) goto err; } -if (!mei_host_is_ready (dev)) { -dev_err (dev->dev,"host is not ready.\n" ); - goto err; - } - -if (!mei_hw_is_ready (dev)) { -dev_err (dev->dev,"ME is not ready.\n" ); - goto err; - } -if (!mei_hbm_version_is_supported (dev)) {dev_dbg (dev->dev,"MEI start failed.\n" ); goto err;
PATCH v8 14/16 mei: debugfs: add pxp mode to devstate in debugfs
In reply to Tomas WinklerAdd pxp mode devstate to debugfs to monitor pxp state machine progress. This is useful to debug issues in scenarios in which the pxp state needs to be re-initialized, like during power transitions such as suspend/resume. With this debugfs the state could be monitored to ensure that pxp is in the ready state.
--- drivers/misc/mei/debugfs.c | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-)
drivers/misc/mei/debugfs.c +18 -1
@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2012-2016, Intel Corporation. All rights reserved +* Copyright (c) 2012-2022, Intel Corporation. All rights reserved * Intel Management Engine Interface (Intel MEI) Linux driver */
@@ -86,6 +86,20 @@ static int mei_dbgfs_active_show(struct seq_file *m, void *unused) }DEFINE_SHOW_ATTRIBUTE (mei_dbgfs_active); +static const char *mei_dev_pxp_mode_str (enum mei_dev_pxp_mode state) +{ +#define MEI_PXP_MODE (state) case MEI_DEV_PXP_##state: return #state +switch (state) { +MEI_PXP_MODE (DEFAULT ); +MEI_PXP_MODE (INIT ); +MEI_PXP_MODE (SETUP ); +MEI_PXP_MODE (READY ); +default : +return "unknown" ; + } +#undef MEI_PXP_MODE +} +static int mei_dbgfs_devstate_show (struct seq_file *m,void *unused) {struct mei_device *dev = m->private;
@@ -112,6 +126,9 @@ static int mei_dbgfs_devstate_show(struct seq_file *m, void *unused)seq_printf (m,"pg: %s, %s\n" ,mei_pg_is_enabled (dev) ?"ENABLED" :"DISABLED" ,mei_pg_state_str (mei_pg_state (dev))); + +seq_printf (m,"pxp: %s\n" ,mei_dev_pxp_mode_str (dev->pxp_mode)); +return 0 ; }DEFINE_SHOW_ATTRIBUTE (mei_dbgfs_devstate);
Signature · 1 line
2.37.2
Re: [Intel-gfx] [PATCH v8 14/16] mei: debugfs: add pxp mode to devstate in debugfs
Quoted 9 lines · Tomas Winkler
Add pxp mode devstate to debugfs to monitor pxp state machine progress. This is useful to debug issues in scenarios in which the pxp state needs to be re-initialized, like during power transitions such as suspend/resume. With this debugfs the state could be monitored to ensure that pxp is in the ready state.
CC Vitaly Lubart <[email protected]>Signed-off-by Tomas Winkler <[email protected]>Signed-off-by Alexander Usyskin <[email protected]>
This is unchanged from the previously reviewed rev (apart from the header update), so this still applies:
Daniele
Quoted 47 lines
--- drivers/misc/mei/debugfs.c | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-)drivers/misc/mei/debugfs.c +18
-1@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 /* -* Copyright (c) 2012-2016, Intel Corporation. All rights reserved +* Copyright (c) 2012-2022, Intel Corporation. All rights reserved * Intel Management Engine Interface (Intel MEI) Linux driver */ @@ -86,6 +86,20 @@ static int mei_dbgfs_active_show(struct seq_file *m, void *unused) }DEFINE_SHOW_ATTRIBUTE (mei_dbgfs_active); +static const char *mei_dev_pxp_mode_str (enum mei_dev_pxp_mode state) +{ +#define MEI_PXP_MODE (state) case MEI_DEV_PXP_##state: return #state +switch (state) { +MEI_PXP_MODE (DEFAULT ); +MEI_PXP_MODE (INIT ); +MEI_PXP_MODE (SETUP ); +MEI_PXP_MODE (READY ); +default : +return "unknown" ; + } +#undef MEI_PXP_MODE +} +static int mei_dbgfs_devstate_show (struct seq_file *m,void *unused) {struct mei_device *dev = m->private;@@ -112,6 +126,9 @@ static int mei_dbgfs_devstate_show(struct seq_file *m, void *unused)seq_printf (m,"pg: %s, %s\n" ,mei_pg_is_enabled (dev) ?"ENABLED" :"DISABLED" ,mei_pg_state_str (mei_pg_state (dev))); + +seq_printf (m,"pxp: %s\n" ,mei_dev_pxp_mode_str (dev->pxp_mode)); +return 0 ; }DEFINE_SHOW_ATTRIBUTE (mei_dbgfs_devstate);
PATCH v8 15/16 drm/i915/gsc: allocate extended operational memory in LMEM
In reply to Tomas WinklerGSC requires more operational memory than available on chip. Reserve 4M of LMEM for GSC operation. The memory is provided to the GSC as struct resource to the auxiliary data of the child device.
--- drivers/gpu/drm/i915/gt/intel_gsc.c | 91 ++++++++++++++++++++++++++--- drivers/gpu/drm/i915/gt/intel_gsc.h | 3 + 2 files changed, 87 insertions(+), 7 deletions(-)
drivers/gpu/drm/i915/gt/intel_gsc.c +84 -7
@@ -7,6 +7,7 @@#include <linux/mei_aux.h> #include "i915_drv.h" #include "i915_reg.h" +#include "gem/i915_gem_region.h" #include "gt/intel_gsc.h" #include "gt/intel_gt.h"
@@ -36,12 +37,68 @@ static int gsc_irq_init(int irq)return irq_set_chip_data (irq,NULL ); } +static int +gsc_ext_om_alloc (struct intel_gsc *gsc,struct intel_gsc_intf *intf,size_t size) +{ +struct intel_gt *gt =gsc_to_gt (gsc); +struct drm_i915_gem_object *obj; +void *vaddr; +int err; + + obj =i915_gem_object_create_lmem (gt->i915, size,I915_BO_ALLOC_CONTIGUOUS ); +if (IS_ERR (obj)) { +drm_err (>->i915->drm,"Failed to allocate gsc memory\n" ); +return PTR_ERR (obj); + } + + err =i915_gem_object_pin_pages_unlocked (obj); +if (err) { +drm_err (>->i915->drm,"Failed to pin pages for gsc memory\n" ); + goto out_put; + } + + vaddr =i915_gem_object_pin_map_unlocked (obj,i915_coherent_map_type (gt->i915, obj, true)); +if (IS_ERR (vaddr)) { + err =PTR_ERR (vaddr); +drm_err (>->i915->drm,"Failed to map gsc memory\n" ); + goto out_unpin; + } + +memset (vaddr,0 , obj->base.size); + +i915_gem_object_unpin_map (obj); + + intf->gem_obj = obj; + +return 0 ; + +out_unpin: +i915_gem_object_unpin_pages (obj); +out_put: +i915_gem_object_put (obj); +return err; +} + +static void gsc_ext_om_destroy (struct intel_gsc_intf *intf) +{ +struct drm_i915_gem_object *obj =fetch_and_zero (&intf->gem_obj); + +if (!obj) +return ; + +if (i915_gem_object_has_pinned_pages (obj)) +i915_gem_object_unpin_pages (obj); + +i915_gem_object_put (obj); +} +struct gsc_def {const char *name;unsigned long bar;size_t bar_size;bool use_polling;bool slow_firmware; +size_t lmem_size; };/* gsc resources and definitions (HECI1 and HECI2) */
@@ -74,6 +131,7 @@ static const struct gsc_def gsc_def_dg2[] = { .name = "mei-gsc", .bar = DG2_GSC_HECI1_BASE, .bar_size = GSC_BAR_LENGTH, + .lmem_size = SZ_4M, }, { .name = "mei-gscfi",
@@ -90,26 +148,32 @@ static void gsc_release_dev(struct device *dev)kfree (adev); } -static void gsc_destroy_one (struct intel_gsc_intf *intf) +static void gsc_destroy_one (struct drm_i915_private *i915, +struct intel_gsc *gsc,unsigned int intf_id) { +struct intel_gsc_intf *intf = &gsc->intf[intf_id]; +if (intf->adev) {auxiliary_device_delete (&intf->adev->aux_dev);auxiliary_device_uninit (&intf->adev->aux_dev); intf->adev =NULL ; } +if (intf->irq >=0 )irq_free_desc (intf->irq); intf->irq =-1 ; + +gsc_ext_om_destroy (intf); } -static void gsc_init_one (struct drm_i915_private *i915, -struct intel_gsc_intf *intf, +static void gsc_init_one (struct drm_i915_private *i915,struct intel_gsc *gsc,unsigned int intf_id) {struct pci_dev *pdev =to_pci_dev (i915->drm.dev);struct mei_aux_device *adev;struct auxiliary_device *aux_dev;const struct gsc_def *def; +struct intel_gsc_intf *intf = &gsc->intf[intf_id];int ret; intf->irq =-1 ;
@@ -141,7 +205,7 @@ static void gsc_init_one(struct drm_i915_private *i915, intf->irq =irq_alloc_desc (0 );if (intf->irq <0 ) {drm_err (&i915->drm,"gsc irq error %d\n" , intf->irq); -return ; + goto fail; } ret =gsc_irq_init (intf->irq);
@@ -155,6 +219,19 @@ static void gsc_init_one(struct drm_i915_private *i915,if (!adev) goto fail; +if (def->lmem_size) { +drm_dbg (&i915->drm,"setting up GSC lmem\n" ); + +if (gsc_ext_om_alloc (gsc, intf, def->lmem_size)) { +drm_err (&i915->drm,"setting up gsc extended operational memory failed\n" ); +kfree (adev); + goto fail; + } + + adev->ext_op_mem.start =i915_gem_object_get_dma_address (intf->gem_obj,0 ); + adev->ext_op_mem.end = adev->ext_op_mem.start + def->lmem_size; + } + adev->irq = intf->irq; adev->bar.parent = &pdev->resource[0 ]; adev->bar.start = def->bar + pdev->resource[0 ].start;
@@ -188,7 +265,7 @@ static void gsc_init_one(struct drm_i915_private *i915,return ; fail: -gsc_destroy_one (intf); +gsc_destroy_one (i915, gsc, intf->id); }static void gsc_irq_handler (struct intel_gt *gt,unsigned int intf_id)
@@ -229,7 +306,7 @@ void intel_gsc_init(struct intel_gsc *gsc, struct drm_i915_private *i915)return ;for (i =0 ; i <INTEL_GSC_NUM_INTERFACES ; i++) -gsc_init_one (i915, &gsc->intf[i], i); +gsc_init_one (i915, gsc, i); }void intel_gsc_fini (struct intel_gsc *gsc)
@@ -241,5 +318,5 @@ void intel_gsc_fini(struct intel_gsc *gsc)return ;for (i =0 ; i <INTEL_GSC_NUM_INTERFACES ; i++) -gsc_destroy_one (&gsc->intf[i]); +gsc_destroy_one (gt->i915, gsc, i); }
drivers/gpu/drm/i915/gt/intel_gsc.h +3 -0
@@ -20,11 +20,14 @@ struct mei_aux_device;/** * struct intel_gsc - graphics security controller +* +* @gem_obj: scratch memory GSC operations * @intf : gsc interface */ struct intel_gsc {struct intel_gsc_intf {struct mei_aux_device *adev; +struct drm_i915_gem_object *gem_obj;int irq;unsigned int id; } intf[INTEL_GSC_NUM_INTERFACES ];
Signature · 1 line
2.37.2
PATCH 1/1 drm/i915/gsc: allocate extended operational memory in LMEM
From: Tomas Winkler <[email protected]>
GSC requires more operational memory than available on chip. Reserve 4M of LMEM for GSC operation. The memory is provided to the GSC as struct resource to the auxiliary data of the child device.
v2: use I915_BO_ALLOC_CPU_CLEAR to clear the allocated memory instead of doing a manual memset (Matt)
--- drivers/gpu/drm/i915/gt/intel_gsc.c | 79 ++++++++++++++++++++++++++--- drivers/gpu/drm/i915/gt/intel_gsc.h | 3 ++ 2 files changed, 75 insertions(+), 7 deletions(-)
drivers/gpu/drm/i915/gt/intel_gsc.c +72 -7
@@ -7,6 +7,7 @@#include <linux/mei_aux.h> #include "i915_drv.h" #include "i915_reg.h" +#include "gem/i915_gem_region.h" #include "gt/intel_gsc.h" #include "gt/intel_gt.h"
@@ -36,12 +37,56 @@ static int gsc_irq_init(int irq)return irq_set_chip_data (irq,NULL ); } +static int +gsc_ext_om_alloc (struct intel_gsc *gsc,struct intel_gsc_intf *intf,size_t size) +{ +struct intel_gt *gt =gsc_to_gt (gsc); +struct drm_i915_gem_object *obj; +int err; + + obj =i915_gem_object_create_lmem (gt->i915, size, +I915_BO_ALLOC_CONTIGUOUS | +I915_BO_ALLOC_CPU_CLEAR ); +if (IS_ERR (obj)) { +drm_err (>->i915->drm,"Failed to allocate gsc memory\n" ); +return PTR_ERR (obj); + } + + err =i915_gem_object_pin_pages_unlocked (obj); +if (err) { +drm_err (>->i915->drm,"Failed to pin pages for gsc memory\n" ); + goto out_put; + } + + intf->gem_obj = obj; + +return 0 ; + +out_put: +i915_gem_object_put (obj); +return err; +} + +static void gsc_ext_om_destroy (struct intel_gsc_intf *intf) +{ +struct drm_i915_gem_object *obj =fetch_and_zero (&intf->gem_obj); + +if (!obj) +return ; + +if (i915_gem_object_has_pinned_pages (obj)) +i915_gem_object_unpin_pages (obj); + +i915_gem_object_put (obj); +} +struct gsc_def {const char *name;unsigned long bar;size_t bar_size;bool use_polling;bool slow_firmware; +size_t lmem_size; };/* gsc resources and definitions (HECI1 and HECI2) */
@@ -74,6 +119,7 @@ static const struct gsc_def gsc_def_dg2[] = { .name = "mei-gsc", .bar = DG2_GSC_HECI1_BASE, .bar_size = GSC_BAR_LENGTH, + .lmem_size = SZ_4M, }, { .name = "mei-gscfi",
@@ -90,26 +136,32 @@ static void gsc_release_dev(struct device *dev)kfree (adev); } -static void gsc_destroy_one (struct intel_gsc_intf *intf) +static void gsc_destroy_one (struct drm_i915_private *i915, +struct intel_gsc *gsc,unsigned int intf_id) { +struct intel_gsc_intf *intf = &gsc->intf[intf_id]; +if (intf->adev) {auxiliary_device_delete (&intf->adev->aux_dev);auxiliary_device_uninit (&intf->adev->aux_dev); intf->adev =NULL ; } +if (intf->irq >=0 )irq_free_desc (intf->irq); intf->irq =-1 ; + +gsc_ext_om_destroy (intf); } -static void gsc_init_one (struct drm_i915_private *i915, -struct intel_gsc_intf *intf, +static void gsc_init_one (struct drm_i915_private *i915,struct intel_gsc *gsc,unsigned int intf_id) {struct pci_dev *pdev =to_pci_dev (i915->drm.dev);struct mei_aux_device *adev;struct auxiliary_device *aux_dev;const struct gsc_def *def; +struct intel_gsc_intf *intf = &gsc->intf[intf_id];int ret; intf->irq =-1 ;
@@ -141,7 +193,7 @@ static void gsc_init_one(struct drm_i915_private *i915, intf->irq =irq_alloc_desc (0 );if (intf->irq <0 ) {drm_err (&i915->drm,"gsc irq error %d\n" , intf->irq); -return ; + goto fail; } ret =gsc_irq_init (intf->irq);
@@ -155,6 +207,19 @@ static void gsc_init_one(struct drm_i915_private *i915,if (!adev) goto fail; +if (def->lmem_size) { +drm_dbg (&i915->drm,"setting up GSC lmem\n" ); + +if (gsc_ext_om_alloc (gsc, intf, def->lmem_size)) { +drm_err (&i915->drm,"setting up gsc extended operational memory failed\n" ); +kfree (adev); + goto fail; + } + + adev->ext_op_mem.start =i915_gem_object_get_dma_address (intf->gem_obj,0 ); + adev->ext_op_mem.end = adev->ext_op_mem.start + def->lmem_size; + } + adev->irq = intf->irq; adev->bar.parent = &pdev->resource[0 ]; adev->bar.start = def->bar + pdev->resource[0 ].start;
@@ -188,7 +253,7 @@ static void gsc_init_one(struct drm_i915_private *i915,return ; fail: -gsc_destroy_one (intf); +gsc_destroy_one (i915, gsc, intf->id); }static void gsc_irq_handler (struct intel_gt *gt,unsigned int intf_id)
@@ -229,7 +294,7 @@ void intel_gsc_init(struct intel_gsc *gsc, struct drm_i915_private *i915)return ;for (i =0 ; i <INTEL_GSC_NUM_INTERFACES ; i++) -gsc_init_one (i915, &gsc->intf[i], i); +gsc_init_one (i915, gsc, i); }void intel_gsc_fini (struct intel_gsc *gsc)
@@ -241,5 +306,5 @@ void intel_gsc_fini(struct intel_gsc *gsc)return ;for (i =0 ; i <INTEL_GSC_NUM_INTERFACES ; i++) -gsc_destroy_one (&gsc->intf[i]); +gsc_destroy_one (gt->i915, gsc, i); }
drivers/gpu/drm/i915/gt/intel_gsc.h +3 -0
@@ -20,11 +20,14 @@ struct mei_aux_device;/** * struct intel_gsc - graphics security controller +* +* @gem_obj: scratch memory GSC operations * @intf : gsc interface */ struct intel_gsc {struct intel_gsc_intf {struct mei_aux_device *adev; +struct drm_i915_gem_object *gem_obj;int irq;unsigned int id; } intf[INTEL_GSC_NUM_INTERFACES ];
Signature · 1 line
2.37.2
PATCH v8 16/16 HAX: drm/i915: force INTEL_MEI_GSC on for CI
In reply to Tomas WinklerFrom: Daniele Ceraolo Spurio <[email protected]>
After the new config option is merged we'll enable it by default in the CI config, but for now just force it on via the i915 Kconfig so we can get pre-merge CI results for it.
--- drivers/gpu/drm/i915/Kconfig.debug | 1 + 1 file changed, 1 insertion(+)
drivers/gpu/drm/i915/Kconfig.debug +1 -0
@@ -48,6 +48,7 @@ config DRM_I915_DEBUG select DRM_I915_DEBUG_RUNTIME_PM select DRM_I915_SW_FENCE_DEBUG_OBJECTS select DRM_I915_SELFTEST + select INTEL_MEI_GSC select BROKEN # for prototype uAPI default n help
Signature · 1 line
2.37.2
Patchwork
CI[Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for GSC support for XeHP SDV and DG2 (rev3)
In reply to Tomas Winkler== Series Details ==
== Series Details ==
Series: GSC support for XeHP SDV and DG2 (rev3)
URL : https://patchwork.freedesktop.org/series/106638/
State : warning
== Summary ==
Error: dim checkpatch failed2cec6e0ccdb3 drm/i915/gsc: skip irq initialization if using polling462345d7d500 mei: add kdoc for struct mei_aux_device180677d87c5f mei: add slow_firmware flag to the mei auxiliary devicef76e236a7b82 drm/i915/gsc: add slow_firmware flag to the gsc device definition bed8fb3fe056 drm/i915/gsc: add GSC XeHP SDV platform definitione038240b0aed mei: gsc: use polling instead of interruptsd0475dfb439d mei: gsc: wait for reset thread on stopb75c6b7dc112 mei: extend timeouts on slow devices.3b62a7648045 mei: bus: export common mkhi definitions into a separate header Traceback (most recent call last):
File "scripts/spdxcheck.py", line 11, in <module>
import git
ModuleNotFoundError: No module named 'git'
-:71: WARNING:FILE_PATH_CHANGES: added, moved or deleted file(s), does MAINTAINERS need updating? #71:
new file mode 100644
total: 0 errors, 1 warnings, 0 checks, 106 lines checked97d845c769dd mei: mkhi: add memory ready command0cc5b86bdf17 mei: gsc: setup gsc extended operational memory500ee81e39ca mei: gsc: add transition to PXP mode in resume flow 0f0b4cb9a375 mei: drop ready bits check after start84a43d5ba8d1 mei: debugfs: add pxp mode to devstate in debugfs
-:34: ERROR:COMPLEX_MACRO: Macros with complex values should be enclosed in parentheses #34: FILE: drivers/misc/mei/debugfs.c:91:
+#define MEI_PXP_MODE(state) case MEI_DEV_PXP_##state: return #state
total: 1 errors, 0 warnings, 0 checks, 36 lines checked d97bbeb30447 drm/i915/gsc: allocate extended operational memory in LMEM 105d8cee5eaf HAX: drm/i915: force INTEL_MEI_GSC on for CI
Patchwork
CI[Intel-gfx] ✗ Fi.CI.SPARSE: warning for GSC support for XeHP SDV and DG2 (rev3)
In reply to Tomas Winkler== Series Details ==
== Series Details ==
Series: GSC support for XeHP SDV and DG2 (rev3)
URL : https://patchwork.freedesktop.org/series/106638/
State : warning
== Summary ==
Error: dim sparse failed
Sparse version: v0.6.2
Fast mode used, each commit won't be checked separately.
Patchwork
CI[Intel-gfx] ✓ Fi.CI.BAT: success for GSC support for XeHP SDV and DG2 (rev3)
In reply to Tomas Winkler== Series Details ==
== Series Details ==
Series: GSC support for XeHP SDV and DG2 (rev3)
URL : https://patchwork.freedesktop.org/series/106638/
State : success
== Summary ==
CI Bug Log - changes from CI_DRM_12088 -> Patchwork_106638v3
====================================================
Summary
-------
**SUCCESS**
No regressions found.
External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/index.html
Participating hosts (43 -> 42)
------------------------------
Additional (2): fi-rkl-11600 bat-jsl-3
Missing (3): fi-icl-u2 fi-bdw-samus fi-snb-2600
Possible new issues
-------------------
Here are the unknown changes that may have been introduced in Patchwork_106638v3:
### IGT changes ###
#### Suppressed ####
The following results come from untrusted machines, tests, or statuses. They do not affect the overall result.
* igt@i915_selftest@live@gt_mocs:
- {bat-rpls-1}: [PASS][1] -> [DMESG-FAIL][2]
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12088/bat-rpls-1/igt@i915_selftest@live@gt_mocs.html
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/bat-rpls-1/igt@i915_selftest@live@gt_mocs.html
Known issues
------------
Here are the changes found in Patchwork_106638v3 that come from known issues:
### IGT changes ###
#### Issues hit ####
* igt@gem_huc_copy@huc-copy:
- fi-rkl-11600: NOTRUN -> [SKIP][3] ([i915#2190])
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-11600/igt@[email protected]
* igt@gem_lmem_swapping@parallel-random-engines:
- fi-rkl-11600: NOTRUN -> [SKIP][4] ([i915#4613]) +3 similar issues
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-11600/igt@[email protected]
* igt@gem_tiled_pread_basic:
- fi-rkl-11600: NOTRUN -> [SKIP][5] ([i915#3282])
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-11600/igt@gem_tiled_pread_basic.html
* igt@i915_pm_backlight@basic-brightness:
- fi-rkl-11600: NOTRUN -> [SKIP][6] ([i915#3012])
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-11600/igt@[email protected]
* igt@i915_selftest@live@ring_submission:
- fi-cfl-8109u: [PASS][7] -> [DMESG-WARN][8] ([i915#5904]) +35 similar issues
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12088/fi-cfl-8109u/igt@i915_selftest@live@ring_submission.html
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-cfl-8109u/igt@i915_selftest@live@ring_submission.html
* igt@i915_suspend@basic-s3-without-i915:
- fi-rkl-11600: NOTRUN -> [INCOMPLETE][9] ([i915#5982])
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-11600/igt@[email protected]
- fi-bdw-5557u: [PASS][10] -> [INCOMPLETE][11] ([i915#146] / [i915#6598] / [i915#6712])
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12088/fi-bdw-5557u/igt@[email protected]
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-bdw-5557u/igt@[email protected]
* igt@kms_addfb_basic@invalid-set-prop:
- fi-cfl-8109u: [PASS][12] -> [DMESG-WARN][13] ([i915#5904] / [i915#62]) +84 similar issues
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12088/fi-cfl-8109u/igt@[email protected]
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-cfl-8109u/igt@[email protected]
* igt@kms_chamelium@common-hpd-after-suspend:
- fi-hsw-4770: NOTRUN -> [SKIP][14] ([fdo#109271] / [fdo#111827])
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-hsw-4770/igt@[email protected]
- fi-rkl-guc: NOTRUN -> [SKIP][15] ([fdo#111827])
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-guc/igt@[email protected]
* igt@kms_chamelium@hdmi-hpd-fast:
- fi-rkl-11600: NOTRUN -> [SKIP][16] ([fdo#111827]) +7 similar issues
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-11600/igt@[email protected]
* igt@kms_cursor_legacy@basic-busy-flip-before-cursor:
- fi-rkl-11600: NOTRUN -> [SKIP][17] ([i915#4103])
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-11600/igt@[email protected]
* igt@kms_force_connector_basic@force-load-detect:
- fi-rkl-11600: NOTRUN -> [SKIP][18] ([fdo#109285] / [i915#4098])
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-11600/igt@[email protected]
* igt@kms_psr@sprite_plane_onoff:
- fi-rkl-11600: NOTRUN -> [SKIP][19] ([i915#1072]) +3 similar issues
[19]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-11600/igt@kms_psr@sprite_plane_onoff.html
* igt@kms_setmode@basic-clone-single-crtc:
- fi-rkl-11600: NOTRUN -> [SKIP][20] ([i915#3555] / [i915#4098])
[20]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-11600/igt@[email protected]
* igt@prime_vgem@basic-read:
- fi-rkl-11600: NOTRUN -> [SKIP][21] ([fdo#109295] / [i915#3291] / [i915#3708]) +2 similar issues
[21]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-11600/igt@[email protected]
* igt@prime_vgem@basic-userptr:
- fi-rkl-11600: NOTRUN -> [SKIP][22] ([fdo#109295] / [i915#3301] / [i915#3708])
[22]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-11600/igt@[email protected]
#### Possible fixes ####
* igt@gem_exec_suspend@basic-s0@smem:
- {bat-rplp-1}: [DMESG-WARN][23] ([i915#2867]) -> [PASS][24]
[23]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12088/bat-rplp-1/igt@gem_exec_suspend@[email protected]
[24]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/bat-rplp-1/igt@gem_exec_suspend@[email protected]
* igt@i915_selftest@live@hangcheck:
- fi-hsw-4770: [INCOMPLETE][25] ([i915#4785]) -> [PASS][26]
[25]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12088/fi-hsw-4770/igt@i915_selftest@[email protected]
[26]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-hsw-4770/igt@i915_selftest@[email protected]
* igt@i915_selftest@live@requests:
- {bat-rpls-1}: [INCOMPLETE][27] ([i915#4983] / [i915#6257] / [i915#6380]) -> [PASS][28]
[27]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12088/bat-rpls-1/igt@i915_selftest@[email protected]
[28]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/bat-rpls-1/igt@i915_selftest@[email protected]
* igt@i915_selftest@live@workarounds:
- fi-rkl-guc: [INCOMPLETE][29] ([i915#4983]) -> [PASS][30]
[29]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12088/fi-rkl-guc/igt@i915_selftest@[email protected]
[30]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/fi-rkl-guc/igt@i915_selftest@[email protected]
{name}: This element is suppressed. This means it is ignored when computing
the status of the difference (SUCCESS, WARNING, or FAILURE).
[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[fdo#109285]: https://bugs.freedesktop.org/show_bug.cgi?id=109285
[fdo#109295]: https://bugs.freedesktop.org/show_bug.cgi?id=109295
[fdo#111827]: https://bugs.freedesktop.org/show_bug.cgi?id=111827
[i915#1072]: https://gitlab.freedesktop.org/drm/intel/issues/1072
[i915#146]: https://gitlab.freedesktop.org/drm/intel/issues/146
[i915#2190]: https://gitlab.freedesktop.org/drm/intel/issues/2190
[i915#2867]: https://gitlab.freedesktop.org/drm/intel/issues/2867
[i915#3003]: https://gitlab.freedesktop.org/drm/intel/issues/3003
[i915#3012]: https://gitlab.freedesktop.org/drm/intel/issues/3012
[i915#3282]: https://gitlab.freedesktop.org/drm/intel/issues/3282
[i915#3291]: https://gitlab.freedesktop.org/drm/intel/issues/3291
[i915#3301]: https://gitlab.freedesktop.org/drm/intel/issues/3301
[i915#3555]: https://gitlab.freedesktop.org/drm/intel/issues/3555
[i915#3708]: https://gitlab.freedesktop.org/drm/intel/issues/3708
[i915#4098]: https://gitlab.freedesktop.org/drm/intel/issues/4098
[i915#4103]: https://gitlab.freedesktop.org/drm/intel/issues/4103
[i915#4613]: https://gitlab.freedesktop.org/drm/intel/issues/4613
[i915#4785]: https://gitlab.freedesktop.org/drm/intel/issues/4785
[i915#4983]: https://gitlab.freedesktop.org/drm/intel/issues/4983
[i915#5904]: https://gitlab.freedesktop.org/drm/intel/issues/5904
[i915#5982]: https://gitlab.freedesktop.org/drm/intel/issues/5982
[i915#62]: https://gitlab.freedesktop.org/drm/intel/issues/62
[i915#6257]: https://gitlab.freedesktop.org/drm/intel/issues/6257
[i915#6367]: https://gitlab.freedesktop.org/drm/intel/issues/6367
[i915#6380]: https://gitlab.freedesktop.org/drm/intel/issues/6380
[i915#6598]: https://gitlab.freedesktop.org/drm/intel/issues/6598
[i915#6712]: https://gitlab.freedesktop.org/drm/intel/issues/6712
Build changes
-------------
* Linux: CI_DRM_12088 -> Patchwork_106638v3
CI-20190529: 20190529
CI_DRM_12088: 3a1b2f4abc391edf8a58ff90fa9908ce0abac22c @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_6648: 3c9079c0b97445fbfc903b9c5a1d69707b80af80 @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git
Patchwork_106638v3: 3a1b2f4abc391edf8a58ff90fa9908ce0abac22c @ git://anongit.freedesktop.org/gfx-ci/linux
### Linux commits
aa0743cabe61 HAX: drm/i915: force INTEL_MEI_GSC on for CI 11c2356c0f29 drm/i915/gsc: allocate extended operational memory in LMEM 68979fc10fb9 mei: debugfs: add pxp mode to devstate in debugfs facefc96c3e3 mei: drop ready bits check after startd4abf414543d mei: gsc: add transition to PXP mode in resume flow ffde34390eb7 mei: gsc: setup gsc extended operational memory 72ac4cc4b40d mei: mkhi: add memory ready commandf018d1159577 mei: bus: export common mkhi definitions into a separate header 4fbf1a05bc4a mei: extend timeouts on slow devices.5b675d7917f0 mei: gsc: wait for reset thread on stop118ef44a3726 mei: gsc: use polling instead of interrupts 1fc2ece9f1e5 drm/i915/gsc: add GSC XeHP SDV platform definition 5c6d0883d373 drm/i915/gsc: add slow_firmware flag to the gsc device definition c54ba88aeeeb mei: add slow_firmware flag to the mei auxiliary device 9e5569330bf0 mei: add kdoc for struct mei_aux_device9b83ae6e58bd drm/i915/gsc: skip irq initialization if using polling
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v3/index.html
Patchwork
CI[Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for GSC support for XeHP SDV and DG2 (rev4)
In reply to Tomas Winkler== Series Details ==
== Series Details ==
Series: GSC support for XeHP SDV and DG2 (rev4)
URL : https://patchwork.freedesktop.org/series/106638/
State : warning
== Summary ==
Error: dim checkpatch faileda6d157c243b5 drm/i915/gsc: skip irq initialization if using pollingf33aa591ecde mei: add kdoc for struct mei_aux_device8dec02344065 mei: add slow_firmware flag to the mei auxiliary device55dd4dfeed6b drm/i915/gsc: add slow_firmware flag to the gsc device definition 604fed434ce9 drm/i915/gsc: add GSC XeHP SDV platform definitiond3e659f047ae mei: gsc: use polling instead of interrupts032acd9005c3 mei: gsc: wait for reset thread on stop1438bdcfd1cb mei: extend timeouts on slow devices.4a69d0b86e86 mei: bus: export common mkhi definitions into a separate header Traceback (most recent call last):
File "scripts/spdxcheck.py", line 11, in <module>
import git
ModuleNotFoundError: No module named 'git'
-:71: WARNING:FILE_PATH_CHANGES: added, moved or deleted file(s), does MAINTAINERS need updating? #71:
new file mode 100644
total: 0 errors, 1 warnings, 0 checks, 106 lines checkedf5fbdd916a5e mei: mkhi: add memory ready command25250fb00f7a mei: gsc: setup gsc extended operational memorye9c85b31d6bf mei: gsc: add transition to PXP mode in resume flow af40f92c8c90 mei: drop ready bits check after start8393a31429b0 mei: debugfs: add pxp mode to devstate in debugfs
-:34: ERROR:COMPLEX_MACRO: Macros with complex values should be enclosed in parentheses #34: FILE: drivers/misc/mei/debugfs.c:91:
+#define MEI_PXP_MODE(state) case MEI_DEV_PXP_##state: return #state
total: 1 errors, 0 warnings, 0 checks, 36 lines checked db50a0d373af drm/i915/gsc: allocate extended operational memory in LMEM 4e58910c7f4e HAX: drm/i915: force INTEL_MEI_GSC on for CI
Patchwork
CI[Intel-gfx] ✗ Fi.CI.SPARSE: warning for GSC support for XeHP SDV and DG2 (rev4)
In reply to Tomas Winkler== Series Details ==
== Series Details ==
Series: GSC support for XeHP SDV and DG2 (rev4)
URL : https://patchwork.freedesktop.org/series/106638/
State : warning
== Summary ==
Error: dim sparse failed
Sparse version: v0.6.2
Fast mode used, each commit won't be checked separately.
Patchwork
CI[Intel-gfx] ✓ Fi.CI.BAT: success for GSC support for XeHP SDV and DG2 (rev4)
In reply to Tomas Winkler== Series Details ==
== Series Details ==
Series: GSC support for XeHP SDV and DG2 (rev4)
URL : https://patchwork.freedesktop.org/series/106638/
State : success
== Summary ==
CI Bug Log - changes from CI_DRM_12089 -> Patchwork_106638v4
====================================================
Summary
-------
**SUCCESS**
No regressions found.
External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/index.html
Participating hosts (31 -> 43)
------------------------------
Additional (13): fi-rkl-11600 bat-dg1-5 bat-dg2-8 bat-adlm-1 bat-dg2-9 bat-adlp-6 bat-adlp-4 bat-adln-1 fi-pnv-d510 bat-rplp-1 bat-rpls-1 bat-rpls-2 bat-dg2-11
Missing (1): fi-bdw-samus
Known issues
------------
Here are the changes found in Patchwork_106638v4 that come from known issues:
### IGT changes ###
#### Issues hit ####
* igt@fbdev@nullptr:
- bat-dg1-5: NOTRUN -> [SKIP][1] ([i915#2582]) +4 similar issues
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-dg1-5/igt@[email protected]
* igt@fbdev@read:
- bat-adlp-4: NOTRUN -> [SKIP][2] ([i915#2582]) +4 similar issues
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@[email protected]
* igt@gem_exec_basic@basic@rcs0-lmem0:
- bat-dg1-5: NOTRUN -> [DMESG-WARN][3] ([i915#6744])
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-dg1-5/igt@gem_exec_basic@[email protected]
* igt@gem_huc_copy@huc-copy:
- fi-rkl-11600: NOTRUN -> [SKIP][4] ([i915#2190])
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-rkl-11600/igt@[email protected]
* igt@gem_lmem_swapping@basic:
- fi-rkl-11600: NOTRUN -> [SKIP][5] ([i915#4613]) +3 similar issues
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-rkl-11600/igt@[email protected]
* igt@gem_lmem_swapping@parallel-random-engines:
- bat-adlp-4: NOTRUN -> [SKIP][6] ([i915#4613]) +3 similar issues
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@[email protected]
* igt@gem_tiled_pread_basic:
- fi-rkl-11600: NOTRUN -> [SKIP][7] ([i915#3282])
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-rkl-11600/igt@gem_tiled_pread_basic.html
- bat-adlp-4: NOTRUN -> [SKIP][8] ([i915#3282])
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@gem_tiled_pread_basic.html
* igt@i915_pm_backlight@basic-brightness:
- bat-adlp-4: NOTRUN -> [SKIP][9] ([i915#1155])
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@[email protected]
- fi-rkl-11600: NOTRUN -> [SKIP][10] ([i915#3012])
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-rkl-11600/igt@[email protected]
* igt@i915_pm_rps@basic-api:
- bat-adlp-4: NOTRUN -> [SKIP][11] ([i915#6621])
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@[email protected]
* igt@i915_selftest@live@hangcheck:
- fi-hsw-4770: [PASS][12] -> [INCOMPLETE][13] ([i915#4785])
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12089/fi-hsw-4770/igt@i915_selftest@[email protected]
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-hsw-4770/igt@i915_selftest@[email protected]
- fi-hsw-g3258: [PASS][14] -> [INCOMPLETE][15] ([i915#3303] / [i915#4785])
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12089/fi-hsw-g3258/igt@i915_selftest@[email protected]
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-hsw-g3258/igt@i915_selftest@[email protected]
* igt@i915_suspend@basic-s3-without-i915:
- fi-rkl-11600: NOTRUN -> [INCOMPLETE][16] ([i915#5982])
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-rkl-11600/igt@[email protected]
* igt@kms_chamelium@dp-crc-fast:
- bat-adlp-4: NOTRUN -> [SKIP][17] ([fdo#111827]) +8 similar issues
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@[email protected]
* igt@kms_chamelium@hdmi-edid-read:
- fi-rkl-11600: NOTRUN -> [SKIP][18] ([fdo#111827]) +7 similar issues
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-rkl-11600/igt@[email protected]
* igt@kms_cursor_legacy@basic-busy-flip-before-cursor:
- fi-rkl-11600: NOTRUN -> [SKIP][19] ([i915#4103])
[19]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-rkl-11600/igt@[email protected]
* igt@kms_flip@basic-flip-vs-wf_vblank:
- bat-adlp-4: NOTRUN -> [SKIP][20] ([i915#3637]) +3 similar issues
[20]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@kms_flip@basic-flip-vs-wf_vblank.html
* igt@kms_force_connector_basic@force-load-detect:
- bat-adlp-4: NOTRUN -> [SKIP][21] ([i915#4093]) +3 similar issues
[21]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@[email protected]
- fi-rkl-11600: NOTRUN -> [SKIP][22] ([fdo#109285] / [i915#4098])
[22]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-rkl-11600/igt@[email protected]
* igt@kms_frontbuffer_tracking@basic:
- bat-adlp-4: NOTRUN -> [SKIP][23] ([i915#4342])
[23]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@[email protected]
* igt@kms_pipe_crc_basic@read-crc-frame-sequence:
- bat-adlp-4: NOTRUN -> [SKIP][24] ([i915#3546]) +10 similar issues
[24]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@[email protected]
* igt@kms_psr@primary_page_flip:
- fi-pnv-d510: NOTRUN -> [SKIP][25] ([fdo#109271]) +43 similar issues
[25]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-pnv-d510/igt@kms_psr@primary_page_flip.html
- fi-rkl-11600: NOTRUN -> [SKIP][26] ([i915#1072]) +3 similar issues
[26]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-rkl-11600/igt@kms_psr@primary_page_flip.html
* igt@kms_psr@sprite_plane_onoff:
- bat-adlp-4: NOTRUN -> [SKIP][27] ([i915#1072]) +3 similar issues
[27]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@kms_psr@sprite_plane_onoff.html
* igt@kms_setmode@basic-clone-single-crtc:
- fi-rkl-11600: NOTRUN -> [SKIP][28] ([i915#3555] / [i915#4098])
[28]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-rkl-11600/igt@[email protected]
- bat-adlp-4: NOTRUN -> [SKIP][29] ([i915#3555] / [i915#4579])
[29]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@[email protected]
* igt@prime_vgem@basic-fence-flip:
- bat-adlp-4: NOTRUN -> [SKIP][30] ([fdo#109295] / [i915#3546] / [i915#3708])
[30]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@[email protected]
* igt@prime_vgem@basic-read:
- fi-rkl-11600: NOTRUN -> [SKIP][31] ([fdo#109295] / [i915#3291] / [i915#3708]) +2 similar issues
[31]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-rkl-11600/igt@[email protected]
* igt@prime_vgem@basic-userptr:
- bat-adlp-4: NOTRUN -> [SKIP][32] ([fdo#109295] / [i915#3301] / [i915#3708])
[32]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@[email protected]
- fi-rkl-11600: NOTRUN -> [SKIP][33] ([fdo#109295] / [i915#3301] / [i915#3708])
[33]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-rkl-11600/igt@[email protected]
* igt@prime_vgem@basic-write:
- bat-adlp-4: NOTRUN -> [SKIP][34] ([fdo#109295] / [i915#3291] / [i915#3708]) +2 similar issues
[34]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-adlp-4/igt@[email protected]
* igt@runner@aborted:
- fi-hsw-4770: NOTRUN -> [FAIL][35] ([fdo#109271] / [i915#4312] / [i915#5594] / [i915#6246])
[35]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-hsw-4770/igt@[email protected]
- bat-dg1-5: NOTRUN -> [FAIL][36] ([i915#4312] / [i915#5257])
[36]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/bat-dg1-5/igt@[email protected]
- fi-hsw-g3258: NOTRUN -> [FAIL][37] ([fdo#109271] / [i915#4312] / [i915#6246])
[37]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-hsw-g3258/igt@[email protected]
#### Possible fixes ####
* igt@kms_chamelium@common-hpd-after-suspend:
- fi-skl-6700k2: [INCOMPLETE][38] ([i915#6598]) -> [PASS][39]
[38]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12089/fi-skl-6700k2/igt@[email protected]
[39]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/fi-skl-6700k2/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#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[fdo#109285]: https://bugs.freedesktop.org/show_bug.cgi?id=109285
[fdo#109295]: https://bugs.freedesktop.org/show_bug.cgi?id=109295
[fdo#111827]: https://bugs.freedesktop.org/show_bug.cgi?id=111827
[i915#1072]: https://gitlab.freedesktop.org/drm/intel/issues/1072
[i915#1155]: https://gitlab.freedesktop.org/drm/intel/issues/1155
[i915#1845]: https://gitlab.freedesktop.org/drm/intel/issues/1845
[i915#1849]: https://gitlab.freedesktop.org/drm/intel/issues/1849
[i915#2190]: https://gitlab.freedesktop.org/drm/intel/issues/2190
[i915#2582]: https://gitlab.freedesktop.org/drm/intel/issues/2582
[i915#2867]: https://gitlab.freedesktop.org/drm/intel/issues/2867
[i915#3012]: https://gitlab.freedesktop.org/drm/intel/issues/3012
[i915#3282]: https://gitlab.freedesktop.org/drm/intel/issues/3282
[i915#3291]: https://gitlab.freedesktop.org/drm/intel/issues/3291
[i915#3301]: https://gitlab.freedesktop.org/drm/intel/issues/3301
[i915#3303]: https://gitlab.freedesktop.org/drm/intel/issues/3303
[i915#3546]: https://gitlab.freedesktop.org/drm/intel/issues/3546
[i915#3555]: https://gitlab.freedesktop.org/drm/intel/issues/3555
[i915#3637]: https://gitlab.freedesktop.org/drm/intel/issues/3637
[i915#3708]: https://gitlab.freedesktop.org/drm/intel/issues/3708
[i915#4093]: https://gitlab.freedesktop.org/drm/intel/issues/4093
[i915#4098]: https://gitlab.freedesktop.org/drm/intel/issues/4098
[i915#4103]: https://gitlab.freedesktop.org/drm/intel/issues/4103
[i915#4213]: https://gitlab.freedesktop.org/drm/intel/issues/4213
[i915#4312]: https://gitlab.freedesktop.org/drm/intel/issues/4312
[i915#4342]: https://gitlab.freedesktop.org/drm/intel/issues/4342
[i915#4579]: https://gitlab.freedesktop.org/drm/intel/issues/4579
[i915#4613]: https://gitlab.freedesktop.org/drm/intel/issues/4613
[i915#4785]: https://gitlab.freedesktop.org/drm/intel/issues/4785
[i915#5257]: https://gitlab.freedesktop.org/drm/intel/issues/5257
[i915#5594]: https://gitlab.freedesktop.org/drm/intel/issues/5594
[i915#5982]: https://gitlab.freedesktop.org/drm/intel/issues/5982
[i915#6246]: https://gitlab.freedesktop.org/drm/intel/issues/6246
[i915#6367]: https://gitlab.freedesktop.org/drm/intel/issues/6367
[i915#6598]: https://gitlab.freedesktop.org/drm/intel/issues/6598
[i915#6621]: https://gitlab.freedesktop.org/drm/intel/issues/6621
[i915#6641]: https://gitlab.freedesktop.org/drm/intel/issues/6641
[i915#6730]: https://gitlab.freedesktop.org/drm/intel/issues/6730
[i915#6744]: https://gitlab.freedesktop.org/drm/intel/issues/6744
Build changes
-------------
* Linux: CI_DRM_12089 -> Patchwork_106638v4
CI-20190529: 20190529
CI_DRM_12089: 15f061f3fed969a615209a8dd343debd8410c691 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_6648: 3c9079c0b97445fbfc903b9c5a1d69707b80af80 @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git
Patchwork_106638v4: 15f061f3fed969a615209a8dd343debd8410c691 @ git://anongit.freedesktop.org/gfx-ci/linux
### Linux commits
e9c2cfdac2e5 HAX: drm/i915: force INTEL_MEI_GSC on for CI 482f64d37548 drm/i915/gsc: allocate extended operational memory in LMEM 9b99377b895f mei: debugfs: add pxp mode to devstate in debugfs 1043deea8388 mei: drop ready bits check after start29e48e43932f mei: gsc: add transition to PXP mode in resume flow d5feec09c5ae mei: gsc: setup gsc extended operational memory 1fe0c81adca6 mei: mkhi: add memory ready command7745aa37f238 mei: bus: export common mkhi definitions into a separate header 50376f0aa949 mei: extend timeouts on slow devices.456433e5a362 mei: gsc: wait for reset thread on stopd4190da1c996 mei: gsc: use polling instead of interrupts ec9d8ef68b68 drm/i915/gsc: add GSC XeHP SDV platform definition 5a641fa32bc6 drm/i915/gsc: add slow_firmware flag to the gsc device definition c28f5401ee7f mei: add slow_firmware flag to the mei auxiliary device fd036f5a8db3 mei: add kdoc for struct mei_aux_device3c95c11b468f drm/i915/gsc: skip irq initialization if using polling
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_106638v4/index.html