public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
* [Intel-gfx] [PATCH v7 0/6] drm/i915/pxp: Add missing cleanup steps for PXP global-teardown
@ 2023-01-25  8:26 Alan Previn
  2023-01-25  8:26 ` [Intel-gfx] [PATCH v7 1/6] mei: mei-me: resume device in prepare Alan Previn
                   ` (7 more replies)
  0 siblings, 8 replies; 17+ messages in thread
From: Alan Previn @ 2023-01-25  8:26 UTC (permalink / raw)
  To: intel-gfx
  Cc: Alan Previn, Vivi, Greg Kroah-Hartman, Rodrigo, Alexander Usyskin,
	dri-devel, Tomas Winkler

A customer issue was recently discovered and in the process a
gap in i915's PXP interaction with HW+FW architecure was also
realized. This series adds those missing pieces.

This fix includes changes where i915 calls into the mei
component interface in order to submit requests to the security
firmware during the i915's suspend_prepare flow. This change did
expose a blocking issue in the mei component side that was
discovered while testing in rev1. The issue being the mei-pxp
component driver not being able to runtime-resume while being
within the suspend_prepare callstack.


Thus, we have now included the mei patches (from Alexander) that
fixes that issue by adding a device-link based on the interface
type to ensure mei side runtime resume during the i915's
suspend_prepare call.

That said, as per request from Alexander, we seek Greg's and Tomas'
review for the mei patches (Patch 1, 2 and 3). Patch 2, although is
a change in the i915 code, is the mei component device link change.

The individual patches explain more details. Patch 7 can be ignored
as it won't be merged and is only meant to ensure the CI run's
the PXP subtests with PXP support enabled in KConfig.

Changes from prior revs:
   v1: - Dont need to teardown non-arbitration sessions (Juston).
       - Fix builds when PXP is enabled in config (Alan/CI-build).
       - Fix the broken pm-suspend-resume symmetry when we do this
         pxp-session-teardown during i915s pm_suspend_prepare by
         ensuring the init is done during i915s pm_resume_complete.
   v2: - Rebase on latest drm-tip after PXP subsytem was promoted
         to global.
       - Remove "INTEL_PXP_MAX_HWDRM_SESSIONS" unneeded (Juston Li).
       - Added mei patches that are dependencies for this series
         to successfully pass testing when PXP config is enabled.
   v3: - Added fix for mei patch when CONFIG_PM_SLEEP is off (reported
         by kernel test robot <lkp@intel.com>).
   v4: - Added "DRM_SWITCH_POWER_OFF" check and removed bail-out if
         '!i915' that wont happen in i915_pm_complete (Daniele).
       - move i915_pm_complete to appear in i915_pm_resume.
       - One more fix for mei patch when CONFIG_PM_SLEEP is off
         (reported by kernel test robot <lkp@intel.com>).
   v5: - Reworked Patch #2 on device link establishment. Don't hide
         triggering device-link behind drm_WARN, return -ENODEV if
         it fails and stash the returned device_link struct (Rodrigo).
   v6: - Cosmetic improvements on variable name and comments for
         the stashed dev_link and fixed to use device_link_del
         instead of device_link_remove (Rodrigo).

Alan Previn (3):
  drm/i915/pxp: Invalidate all PXP fw sessions during teardown
  drm/i915/pxp: Trigger the global teardown for before suspending
  drm/i915/pxp: Pxp hw init should be in resume_complete

Alexander Usyskin (3):
  mei: mei-me: resume device in prepare
  drm/i915/pxp: add device link between i915 and mei_pxp
  mei: clean pending read with vtag on bus

 drivers/gpu/drm/i915/i915_driver.c            | 20 +++++-
 drivers/gpu/drm/i915/pxp/intel_pxp.c          | 65 ++++++++++++++++---
 drivers/gpu/drm/i915/pxp/intel_pxp.h          |  2 +
 .../drm/i915/pxp/intel_pxp_cmd_interface_42.h | 15 +++++
 .../i915/pxp/intel_pxp_cmd_interface_cmn.h    |  3 +
 drivers/gpu/drm/i915/pxp/intel_pxp_pm.c       |  4 +-
 drivers/gpu/drm/i915/pxp/intel_pxp_pm.h       |  6 +-
 drivers/gpu/drm/i915/pxp/intel_pxp_session.c  |  8 ++-
 drivers/gpu/drm/i915/pxp/intel_pxp_session.h  |  5 ++
 drivers/gpu/drm/i915/pxp/intel_pxp_tee.c      | 46 +++++++++++++
 drivers/gpu/drm/i915/pxp/intel_pxp_types.h    |  3 +
 drivers/misc/mei/client.c                     |  4 +-
 drivers/misc/mei/pci-me.c                     | 20 +++++-
 13 files changed, 180 insertions(+), 21 deletions(-)


base-commit: 6bcfacd291ed6ff1ff50a295f970c98d54eabe05
-- 
2.39.0


^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2023-01-27 20:26 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-01-25  8:26 [Intel-gfx] [PATCH v7 0/6] drm/i915/pxp: Add missing cleanup steps for PXP global-teardown Alan Previn
2023-01-25  8:26 ` [Intel-gfx] [PATCH v7 1/6] mei: mei-me: resume device in prepare Alan Previn
2023-01-27  9:08   ` Greg Kroah-Hartman
2023-01-25  8:26 ` [Intel-gfx] [PATCH v7 2/6] drm/i915/pxp: add device link between i915 and mei_pxp Alan Previn
2023-01-25 15:53   ` Rodrigo Vivi
2023-01-25  8:26 ` [Intel-gfx] [PATCH v7 3/6] mei: clean pending read with vtag on bus Alan Previn
2023-01-25 17:28   ` Rodrigo Vivi
2023-01-25 18:01     ` Greg Kroah-Hartman
2023-01-27  9:09     ` Greg Kroah-Hartman
2023-01-27 19:07       ` Teres Alexis, Alan Previn
2023-01-27 20:26       ` Rodrigo Vivi
2023-01-27  9:08   ` Greg Kroah-Hartman
2023-01-25  8:26 ` [Intel-gfx] [PATCH v7 4/6] drm/i915/pxp: Invalidate all PXP fw sessions during teardown Alan Previn
2023-01-25  8:26 ` [Intel-gfx] [PATCH v7 5/6] drm/i915/pxp: Trigger the global teardown for before suspending Alan Previn
2023-01-25  8:26 ` [Intel-gfx] [PATCH v7 6/6] drm/i915/pxp: Pxp hw init should be in resume_complete Alan Previn
2023-01-25  9:40 ` [Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915/pxp: Add missing cleanup steps for PXP global-teardown Patchwork
2023-01-25 15:11 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox