STRUCT INTEL_PXP(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ NAME ✨

okay so bestie, we’re in the Kernel API Manual and this is struct intel_pxp(9) β€” literally the pxp state struct, no cap. πŸ’–

struct intel_pxp β€” pxp state. That’s the NAME, and it ate. πŸ‘‘


🌸 SYNOPSIS 🌸

here’s the whole struct, copied exactly because code is sacred, bestie. do not touch the semicolons. πŸ’…

       struct intel_pxp {
           struct intel_gt *ctrl_gt;
           bool platform_cfg_is_bad;
           u32 kcr_base;
           struct gsccs_session_resources {
             u64 host_session_handle;
             struct intel_context *ce;
             struct i915_vma *pkt_vma;
             void *pkt_vaddr;
             struct i915_vma *bb_vma;
             void *bb_vaddr;
           } gsccs_res;
           struct i915_pxp_component *pxp_component;
           struct device_link *dev_link;
           bool pxp_component_added;
           struct intel_context *ce;
           struct mutex arb_mutex;
           bool arb_is_valid;
           u32 key_instance;
           struct mutex tee_mutex;
           struct {
             struct drm_i915_gem_object *obj;
             void *vaddr;
           } stream_cmd;
           bool hw_state_invalidated;
           bool irq_enabled;
           struct completion termination;
           struct work_struct session_work;
           u32 session_events;
         #define PXP_TERMINATION_REQUEST  BIT(0);
         #define PXP_TERMINATION_COMPLETE BIT(1);
         #define PXP_INVAL_REQUIRED       BIT(2);
         #define PXP_EVENT_TYPE_IRQ       BIT(3);
        };

πŸ’… Members πŸ’…

okay so let’s go member by member, and yes every single one is getting its moment. πŸ’…

  • ctrl_gt β€” pointer to the tile that owns the controls for PXP subsystem assets that the VDBOX, the KCR engine (and GSC CS depending on the platform).
  • platform_cfg_is_bad β€” used to track if any prior arb session creation resulted in a failure that was caused by a platform configuration issue, meaning that failure will not get resolved without a change to the platform (not kernel) such as BIOS configuration, firmware update, etc. This bool gets reflected when GET_PARAM:I915_PARAM_PXP_STATUS is called.
  • kcr_base β€” base mmio offset for the KCR engine which is different on legacy platforms vs newer platforms where the KCR is inside the media-tile.
  • gsccs_res β€” resources for request submission for platforms that have a GSC engine.
  • pxp_component β€” i915_pxp_component struct of the bound mei_pxp module. Only set and cleared inside component bind/unbind functions, which are protected by tee_mutex.
  • dev_link β€” Enforce module relationship for power management ordering.
  • pxp_component_added β€” track if the pxp component has been added. Set and cleared in tee init and fini functions respectively.
  • ce β€” kernel-owned context used for PXP operations.
  • arb_mutex β€” protects arb session start.
  • arb_is_valid β€” tracks arb session status. After a teardown, the arb session can still be in play on the HW even if the keys are gone, so we can’t rely on the HW state of the session to know if it’s valid and need to track the status in SW.
  • key_instance β€” tracks which key instance we’re on, so we can use it to determine if an object was created using the current key or a previous one.
  • tee_mutex β€” protects the tee channel binding and messaging.
  • stream_cmd β€” LMEM obj used to send stream PXP commands to the GSC.
  • hw_state_invalidated β€” if the HW perceives an attack on the integrity of the encryption it will invalidate the keys and expect SW to re-initialize the session. We keep track of this state to make sure we only re-start the arb session when required.
  • irq_enabled β€” tracks the status of the kcr irqs.
  • termination β€” tracks the status of a pending termination. Only re-initialized under gt->irq_lock and completed in session_work.
  • session_work β€” worker that manages session events.
  • session_events β€” pending session events, protected with gt->irq_lock.

πŸ¦‹ SEE ALSO πŸ¦‹

Kernel file: ./drivers/gpu/drm/i915/pxp/intel_pxp_types.h β€” go read it, bestie. πŸ¦‹


and that’s the whole page! cute little sign-off: this one came from ./drivers/gpu/drm/i915/pxp, dated October 2026. slay, go forth and understand your PXP state. πŸ’…βœ¨

πŸ“¦ where this page comes from