Re: [Intel-gfx] [PATCH 15/27] drm/i915/pxp: Destroy all type0 sessions upon teardown

2020-11-13 Thread kernel test robot
Hi Sean, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on next-20201113] [also build test WARNING on v5.10-rc3] [cannot apply to drm-intel/for-linux-next char-misc/char-misc-testing v5.10-rc3 v5.10-rc2 v5.10-rc1] [If your patch is applied to the wrong git tree

Re: [Intel-gfx] [PATCH 15/27] drm/i915/pxp: Destroy all type0 sessions upon teardown

2020-11-13 Thread kernel test robot
Hi Sean, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on next-20201113] [also build test WARNING on v5.10-rc3] [cannot apply to drm-intel/for-linux-next char-misc/char-misc-testing v5.10-rc3 v5.10-rc2 v5.10-rc1] [If your patch is applied to the wrong git tree

[Intel-gfx] [RFC PATCH] drm/i915/pxp: intel_pxp_sm_destroy_all_sw_sessions() can be static

2020-11-13 Thread kernel test robot
Reported-by: kernel test robot Signed-off-by: kernel test robot --- intel_pxp_sm.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_sm.c b/drivers/gpu/drm/i915/pxp/intel_pxp_sm.c index 37fe2e5af88dcb..79dd930f1c0d8b 100644 --- a/drivers

Re: [Intel-gfx] [PATCH 08/27] drm/i915/pxp: Read register to check hardware session state

2020-11-13 Thread kernel test robot
Hi Sean, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on next-20201113] [also build test WARNING on v5.10-rc3] [cannot apply to drm-intel/for-linux-next char-misc/char-misc-testing v5.10-rc3 v5.10-rc2 v5.10-rc1] [If your patch is applied to the wrong git tree

[Intel-gfx] [RFC PATCH] drm/i915/pxp: pxp_sm_reg_read() can be static

2020-11-13 Thread kernel test robot
Reported-by: kernel test robot Signed-off-by: kernel test robot --- intel_pxp_sm.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_sm.c b/drivers/gpu/drm/i915/pxp/intel_pxp_sm.c index 3dd5a9e3926ba4..7f5c47ee452d61 100644 --- a/drivers

Re: [Intel-gfx] [PATCH 08/27] drm/i915/pxp: Read register to check hardware session state

2020-11-13 Thread kernel test robot
Hi Sean, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on next-20201113] [also build test WARNING on v5.10-rc3] [cannot apply to drm-intel/for-linux-next char-misc/char-misc-testing v5.10-rc3 v5.10-rc2 v5.10-rc1] [If your patch is applied to the wrong git tree

Re: [Intel-gfx] [PATCH 05/27] drm/i915/pxp: Enable ioctl action to set the ring3 context

2020-11-13 Thread kernel test robot
Hi Sean, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on next-20201113] [also build test WARNING on v5.10-rc3] [cannot apply to drm-intel/for-linux-next char-misc/char-misc-testing v5.10-rc3 v5.10-rc2 v5.10-rc1] [If your patch is applied to the wrong git tree

[Intel-gfx] ✓ Fi.CI.IGT: success for drm/i915: Big bigjoiner series

2020-11-13 Thread Patchwork
== Series Details == Series: drm/i915: Big bigjoiner series URL : https://patchwork.freedesktop.org/series/83837/ State : success == Summary == CI Bug Log - changes from CI_DRM_9326_full -> Patchwork_18904_full Summary --- **WARNING*

[Intel-gfx] ✓ Fi.CI.IGT: success for drm/i915/selftests: Small tweak to put the termination conditions together

2020-11-13 Thread Patchwork
== Series Details == Series: drm/i915/selftests: Small tweak to put the termination conditions together URL : https://patchwork.freedesktop.org/series/83823/ State : success == Summary == CI Bug Log - changes from CI_DRM_9326_full -> Patchwork_18902_full ==

[Intel-gfx] ✗ Fi.CI.IGT: failure for series starting with [CI,v11,1/3] drm/i915: Pass intel_atomic_state instead of drm_atomic_state

2020-11-13 Thread Patchwork
== Series Details == Series: series starting with [CI,v11,1/3] drm/i915: Pass intel_atomic_state instead of drm_atomic_state URL : https://patchwork.freedesktop.org/series/83816/ State : failure == Summary == CI Bug Log - changes from CI_DRM_9326_full -> Patchwork_18901_full =

Re: [Intel-gfx] [PXP CLEAN PATCH v06 08/27] drm/i915/pxp: Read register to check hardware session state

2020-11-13 Thread kernel test robot
Hi Sean, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on next-20201113] [also build test WARNING on v5.10-rc3] [cannot apply to drm-intel/for-linux-next char-misc/char-misc-testing v5.10-rc3 v5.10-rc2 v5.10-rc1] [If your patch is applied to the wrong git tree

[Intel-gfx] ✓ Fi.CI.IGT: success for drm/i915: Eliminate intel_atomic_crtc_state_for_each_plane_state() from skl+ wm code (rev2)

2020-11-13 Thread Patchwork
== Series Details == Series: drm/i915: Eliminate intel_atomic_crtc_state_for_each_plane_state() from skl+ wm code (rev2) URL : https://patchwork.freedesktop.org/series/83589/ State : success == Summary == CI Bug Log - changes from CI_DRM_9326_full -> Patchwork_18900_full =

[Intel-gfx] ✗ Fi.CI.BUILD: failure for series starting with [01/27] drm/i915/pxp: Introduce Intel PXP component

2020-11-13 Thread Patchwork
== Series Details == Series: series starting with [01/27] drm/i915/pxp: Introduce Intel PXP component URL : https://patchwork.freedesktop.org/series/83845/ State : failure == Summary == CALLscripts/checksyscalls.sh CALLscripts/atomic/check-atomics.sh DESCEND objtool CHK incl

[Intel-gfx] [PATCH 14/27] drm/i915/pxp: Enable ioctl action to query PXP tag

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Enable the PXP ioctl action to allow ring3 PXP to query the PXP tag, which is a 32-bit bitwise value indicating the current session info, including protection type, session id, and whether the session is enabled. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/pxp/i

[Intel-gfx] [PATCH 18/27] drm/i915/pxp: Implement funcs to create the TEE channel

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Currently ring3 driver sends the TEE commands directly to TEE, but later, as our design, we would like to make ring3 sending the TEE commands via the ring0 PXP ioctl action instead of TEE ioctl, so we can centralize those protection operations at ring0 PXP. Co-developed-by:

[Intel-gfx] [PATCH 03/27] drm/i915/pxp: Add PXP context for logical hardware states.

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Add PXP context which represents combined view of driver and logical HW states. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/Makefile| 3 +- drivers/gpu/drm/i915/pxp/intel_pxp.c | 32 ++-- drivers/gpu/drm/i915/pxp/intel_pxp.h

[Intel-gfx] [PATCH 10/27] drm/i915/pxp: Enable ioctl action to reserve session slot

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" With this ioctl action, ring3 driver can reserve a specific session slot/id assigned by ring0 PXP, as the first step of PXP session establishment flow. Ring3 PXP stores the session info in the session list structure. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/p

[Intel-gfx] [PATCH 27/27] drm/i915/pxp: Add plane decryption support

2020-11-13 Thread Sean Z Huang
From: Anshuman Gupta Add support to enable/disable PLANE_SURF Decryption Request bit. It requires only to enable plane decryption support when following condition met. 1. PAVP session is enabled. 2. Buffer object is protected. v2: - Rebased to libva_cp-drm-tip_tgl_cp tree. - Used gen fb obj user

[Intel-gfx] [PATCH 01/27] drm/i915/pxp: Introduce Intel PXP component

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" PXP (Protected Xe Path) is an i915 componment, that helps ring3 to establish the hardware protected session and manage the status of each alive software session, as well as the life cycle of each session. By design PXP will expose ioctl so allow ring3 to create, set, and de

[Intel-gfx] [PATCH 08/27] drm/i915/pxp: Read register to check hardware session state

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Implement the functions to check the hardware protected session state via reading the hardware register session in play. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/pxp/intel_pxp.h| 3 + drivers/gpu/drm/i915/pxp/intel_pxp_sm.c | 189 +++

[Intel-gfx] [PATCH 09/27] drm/i915/pxp: Implement funcs to get/set PXP tag

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Implement the functions to get/set the PXP tag, which is 32-bit bitwise value containing the hardware session info, such as its session id, protection mode or whether it's enabled. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/pxp/intel_pxp_sm.c | 105

[Intel-gfx] [PATCH 13/27] drm/i915/pxp: Enable ioctl action to terminate the session

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Enable the PXP ioctl action to allow ring3 PXP to terminate the hardware session and cleanup its software session state. Ring0 PXP sends the session termination command to GPU once receves this ioctl action. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/pxp/intel_

[Intel-gfx] [PATCH 06/27] drm/i915: Rename the whitelist to allowlist

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Rename the whitelist to allowlist as suggested Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/intel_uncore.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c in

[Intel-gfx] [PATCH 26/27] drm/i915/pavp: User interface for Protected buffer

2020-11-13 Thread Sean Z Huang
From: Bommu Krishnaiah This api allow user mode to create Protected buffer and context creation. Signed-off-by: Bommu Krishnaiah Cc: Telukuntla Sreedhar Cc: Kondapally Kalyan Cc: Gupta Anshuman Cc: Huang Sean Z --- drivers/gpu/drm/i915/gem/i915_gem_context.c | 15 ++-- drivers/gp

[Intel-gfx] [PATCH 15/27] drm/i915/pxp: Destroy all type0 sessions upon teardown

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Teardown is triggered when the display topology changes and no long meets the secure playback requirement, and hardware trashes all the encryption keys for display. So as a result, ring0 PXP should handle such case and terminate all the type0 sessions. Signed-off-by: Huang,

[Intel-gfx] [PATCH 19/27] drm/i915/pxp: Enable ioctl action to send TEE commands

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Enable the ioctl action to allow ring3 driver sends TEE commands via ring0 PXP ioctl, instead of TEE iotcl. So we can centralize those protection operations at ring0 PXP. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/pxp/intel_pxp.c | 15 ++ drivers/gpu/dr

[Intel-gfx] [PATCH 23/27] mei: bus: enable pavp device.

2020-11-13 Thread Sean Z Huang
From: Tomas Winkler Enable protected audio video path client on mei client bus. Signed-off-by: Tomas Winkler --- drivers/misc/mei/bus-fixup.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/misc/mei/bus-fixup.c b/drivers/misc/mei/bus-fixup.c index 4e30fa98fe7d..042399b397c9 100

[Intel-gfx] [PATCH 04/27] drm/i915/pxp: set KCR reg init during the boot time

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Set the KCR init during the boot time, which is required by hardware, to allow us doing further protection operation such as sending commands to GPU or TEE Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/Makefile | 1 + drivers/gpu/drm/i915/pxp/intel_pxp.

[Intel-gfx] [PATCH 22/27] drm/i915/pxp: Expose session state for display protection flip

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Implement the intel_pxp_gem_object_status() to allow ring0 i915 display querying the current PXP session state. In the design, ring0 display should not perform protection flip on the protected buffers if there is no PXP session alive. Signed-off-by: Huang, Sean Z --- driv

[Intel-gfx] [PATCH 11/27] drm/i915/pxp: Enable ioctl action to set session in play

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" With this ioctl action, ring3 driver can set the session in state "session in play", after ring3 reserved the session slot/id from ring3 PXP, and sent the TEE commands to activate the corresponding hardware session. Session state "session in play" means this session is ready

[Intel-gfx] [PATCH 16/27] drm/i915/pxp: Termiante the session upon app crash

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Ring0 PXP should terminate the hardware session and cleanup the software state gracefully when the application has established the protection session, but doesn't close the session correctly due to some cases like application crash. Signed-off-by: Huang, Sean Z --- driver

[Intel-gfx] [PATCH 25/27] drm/i915/uapi: introduce drm_i915_gem_create_ext for TGL

2020-11-13 Thread Sean Z Huang
From: Bommu Krishnaiah Same old gem_create but with now with extensions support. This is needed to support various upcoming usecases. For now we use the extensions mechanism to support PAVP. Signed-off-by: Bommu Krishnaiah Cc: Joonas Lahtinen joonas.lahti...@linux.intel.com Cc: Matthew Auld mat

[Intel-gfx] [PATCH 05/27] drm/i915/pxp: Enable ioctl action to set the ring3 context

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Enable one ioctl action to allow ring3 driver to set its ring3 context, so ring0 PXP can track the context id through this ring3 context list. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/i915_drv.c | 1 + drivers/gpu/drm/i915/pxp/intel_pxp.c

[Intel-gfx] [PATCH 17/27] drm/i915/pxp: Enable PXP power management

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" During the power event S3+ sleep/resume, hardware will lose all the encryption keys for every hardware session, even though the software session state was marked as alive after resume. So to handle such case, ring0 PXP should terminate all the hardware sessions and cleanup a

[Intel-gfx] [PATCH 12/27] drm/i915/pxp: Func to send hardware session termination

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Implement the functions to allow ring0 PXP to send a GPU command in order to terminate the hardware session, so hardware can recycle this session slot for the next usage. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/pxp/intel_pxp_sm.c | 309 ++

[Intel-gfx] [PATCH 07/27] drm/i915/pxp: Add PXP-related registers into allowlist

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Add several PXP-related reg into allowlist to allow ring3 driver to read the those register values. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/i915_reg.h | 8 drivers/gpu/drm/i915/intel_uncore.c | 57 + 2 files changed, 50

[Intel-gfx] [PATCH 24/27] mei: pxp: export pavp client to me client bus

2020-11-13 Thread Sean Z Huang
From: Vitaly Lubart Export PAVP client to work with i915_cp driver, for binding it uses kernel component framework. Signed-off-by: Vitaly Lubart Signed-off-by: Tomas Winkler --- drivers/misc/mei/Kconfig | 2 + drivers/misc/mei/Makefile | 1 + drivers/misc/mei/pxp/Kconfig | 1

[Intel-gfx] [PATCH 21/27] drm/i915/pxp: Add i915 trace logs for PXP operations

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Add several i915 trace logs for PXP calls for debugging or performance measurement, including: (1) PXP ioctl (2) PXP teardown callbacks To trun on this feature, we need to set "CONFIG_DRM_I915_LOW_LEVEL_TRACEPOINTS=y" in .config for compiling the Linux kernel. Signed-off-b

[Intel-gfx] [PATCH 02/27] drm/i915/pxp: Enable PXP irq worker and callback stub

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Create the irq worker that serves as callback handler, those callback stubs should be called while the hardware key teardown occurs. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/gt/intel_gt_irq.c | 4 ++ drivers/gpu/drm/i915/i915_reg.h| 1 + drivers/gpu

[Intel-gfx] [PATCH 20/27] drm/i915/pxp: Create the arbitrary session after boot

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Create the arbitrary session, with the fixed session id 0xf, after system boot, for the case that application allocates the protected buffer without establishing any protection session. Because the hardware requires at least one alive session for protected buffer creation.

[Intel-gfx] ✗ Fi.CI.IGT: failure for drm/i915: Avoid memory leak with more than 16 workarounds on a list

2020-11-13 Thread Patchwork
== Series Details == Series: drm/i915: Avoid memory leak with more than 16 workarounds on a list URL : https://patchwork.freedesktop.org/series/83806/ State : failure == Summary == CI Bug Log - changes from CI_DRM_9326_full -> Patchwork_18898_full ==

[Intel-gfx] ✗ Fi.CI.BUILD: failure for series starting with [PXP,CLEAN,v06,01/27] drm/i915/pxp: Introduce Intel PXP component

2020-11-13 Thread Patchwork
== Series Details == Series: series starting with [PXP,CLEAN,v06,01/27] drm/i915/pxp: Introduce Intel PXP component URL : https://patchwork.freedesktop.org/series/83843/ State : failure == Summary == CALLscripts/checksyscalls.sh CALLscripts/atomic/check-atomics.sh DESCEND objtool

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: Big bigjoiner series

2020-11-13 Thread Patchwork
== Series Details == Series: drm/i915: Big bigjoiner series URL : https://patchwork.freedesktop.org/series/83837/ State : success == Summary == CI Bug Log - changes from CI_DRM_9326 -> Patchwork_18904 Summary --- **SUCCESS** No re

[Intel-gfx] [PXP CLEAN PATCH v06 18/27] drm/i915/pxp: Implement funcs to create the TEE channel

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Currently ring3 driver sends the TEE commands directly to TEE, but later, as our design, we would like to make ring3 sending the TEE commands via the ring0 PXP ioctl action instead of TEE ioctl, so we can centralize those protection operations at ring0 PXP. Co-developed-by:

[Intel-gfx] [PXP CLEAN PATCH v06 22/27] drm/i915/pxp: Expose session state for display protection flip

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Implement the intel_pxp_gem_object_status() to allow ring0 i915 display querying the current PXP session state. In the design, ring0 display should not perform protection flip on the protected buffers if there is no PXP session alive. Signed-off-by: Huang, Sean Z --- driv

[Intel-gfx] [PXP CLEAN PATCH v06 11/27] drm/i915/pxp: Enable ioctl action to set session in play

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" With this ioctl action, ring3 driver can set the session in state "session in play", after ring3 reserved the session slot/id from ring3 PXP, and sent the TEE commands to activate the corresponding hardware session. Session state "session in play" means this session is ready

[Intel-gfx] [PXP CLEAN PATCH v06 23/27] mei: bus: enable pavp device.

2020-11-13 Thread Sean Z Huang
From: Tomas Winkler Enable protected audio video path client on mei client bus. Signed-off-by: Tomas Winkler --- drivers/misc/mei/bus-fixup.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/misc/mei/bus-fixup.c b/drivers/misc/mei/bus-fixup.c index 4e30fa98fe7d..042399b397c9 100

[Intel-gfx] [PXP CLEAN PATCH v06 25/27] drm/i915/uapi: introduce drm_i915_gem_create_ext for TGL

2020-11-13 Thread Sean Z Huang
From: Bommu Krishnaiah Same old gem_create but with now with extensions support. This is needed to support various upcoming usecases. For now we use the extensions mechanism to support PAVP. Signed-off-by: Bommu Krishnaiah Cc: Joonas Lahtinen joonas.lahti...@linux.intel.com Cc: Matthew Auld mat

[Intel-gfx] [PXP CLEAN PATCH v06 16/27] drm/i915/pxp: Termiante the session upon app crash

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Ring0 PXP should terminate the hardware session and cleanup the software state gracefully when the application has established the protection session, but doesn't close the session correctly due to some cases like application crash. Signed-off-by: Huang, Sean Z --- driver

[Intel-gfx] [PXP CLEAN PATCH v06 24/27] mei: pxp: export pavp client to me client bus

2020-11-13 Thread Sean Z Huang
From: Vitaly Lubart Export PAVP client to work with i915_cp driver, for binding it uses kernel component framework. Signed-off-by: Vitaly Lubart Signed-off-by: Tomas Winkler --- drivers/misc/mei/Kconfig | 2 + drivers/misc/mei/Makefile | 1 + drivers/misc/mei/pxp/Kconfig | 1

[Intel-gfx] [PXP CLEAN PATCH v06 27/27] drm/i915/pxp: Add plane decryption support

2020-11-13 Thread Sean Z Huang
From: Anshuman Gupta Add support to enable/disable PLANE_SURF Decryption Request bit. It requires only to enable plane decryption support when following condition met. 1. PAVP session is enabled. 2. Buffer object is protected. v2: - Rebased to libva_cp-drm-tip_tgl_cp tree. - Used gen fb obj user

[Intel-gfx] [PXP CLEAN PATCH v06 17/27] drm/i915/pxp: Enable PXP power management

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" During the power event S3+ sleep/resume, hardware will lose all the encryption keys for every hardware session, even though the software session state was marked as alive after resume. So to handle such case, ring0 PXP should terminate all the hardware sessions and cleanup a

[Intel-gfx] [PXP CLEAN PATCH v06 12/27] drm/i915/pxp: Func to send hardware session termination

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Implement the functions to allow ring0 PXP to send a GPU command in order to terminate the hardware session, so hardware can recycle this session slot for the next usage. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/pxp/intel_pxp_sm.c | 309 ++

[Intel-gfx] [PXP CLEAN PATCH v06 01/27] drm/i915/pxp: Introduce Intel PXP component

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" PXP (Protected Xe Path) is an i915 componment, that helps ring3 to establish the hardware protected session and manage the status of each alive software session, as well as the life cycle of each session. By design PXP will expose ioctl so allow ring3 to create, set, and de

[Intel-gfx] [PXP CLEAN PATCH v06 19/27] drm/i915/pxp: Enable ioctl action to send TEE commands

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Enable the ioctl action to allow ring3 driver sends TEE commands via ring0 PXP ioctl, instead of TEE iotcl. So we can centralize those protection operations at ring0 PXP. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/pxp/intel_pxp.c | 15 ++ drivers/gpu/dr

[Intel-gfx] [PXP CLEAN PATCH v06 06/27] drm/i915: Rename the whitelist to allowlist

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Rename the whitelist to allowlist as suggested Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/intel_uncore.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c in

[Intel-gfx] [PXP CLEAN PATCH v06 09/27] drm/i915/pxp: Implement funcs to get/set PXP tag

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Implement the functions to get/set the PXP tag, which is 32-bit bitwise value containing the hardware session info, such as its session id, protection mode or whether it's enabled. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/pxp/intel_pxp_sm.c | 105

[Intel-gfx] [PXP CLEAN PATCH v06 04/27] drm/i915/pxp: set KCR reg init during the boot time

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Set the KCR init during the boot time, which is required by hardware, to allow us doing further protection operation such as sending commands to GPU or TEE Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/Makefile | 1 + drivers/gpu/drm/i915/pxp/intel_pxp.

[Intel-gfx] [PXP CLEAN PATCH v06 26/27] drm/i915/pavp: User interface for Protected buffer

2020-11-13 Thread Sean Z Huang
From: Bommu Krishnaiah This api allow user mode to create Protected buffer and context creation. Signed-off-by: Bommu Krishnaiah Cc: Telukuntla Sreedhar Cc: Kondapally Kalyan Cc: Gupta Anshuman Cc: Huang Sean Z --- drivers/gpu/drm/i915/gem/i915_gem_context.c | 15 ++-- drivers/gp

[Intel-gfx] [PXP CLEAN PATCH v06 02/27] drm/i915/pxp: Enable PXP irq worker and callback stub

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Create the irq worker that serves as callback handler, those callback stubs should be called while the hardware key teardown occurs. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/gt/intel_gt_irq.c | 4 ++ drivers/gpu/drm/i915/i915_reg.h| 1 + drivers/gpu

[Intel-gfx] [PXP CLEAN PATCH v06 10/27] drm/i915/pxp: Enable ioctl action to reserve session slot

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" With this ioctl action, ring3 driver can reserve a specific session slot/id assigned by ring0 PXP, as the first step of PXP session establishment flow. Ring3 PXP stores the session info in the session list structure. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/p

[Intel-gfx] [PXP CLEAN PATCH v06 20/27] drm/i915/pxp: Create the arbitrary session after boot

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Create the arbitrary session, with the fixed session id 0xf, after system boot, for the case that application allocates the protected buffer without establishing any protection session. Because the hardware requires at least one alive session for protected buffer creation.

[Intel-gfx] [PXP CLEAN PATCH v06 03/27] drm/i915/pxp: Add PXP context for logical hardware states.

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Add PXP context which represents combined view of driver and logical HW states. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/Makefile| 3 +- drivers/gpu/drm/i915/pxp/intel_pxp.c | 32 ++-- drivers/gpu/drm/i915/pxp/intel_pxp.h

[Intel-gfx] [PXP CLEAN PATCH v06 05/27] drm/i915/pxp: Enable ioctl action to set the ring3 context

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Enable one ioctl action to allow ring3 driver to set its ring3 context, so ring0 PXP can track the context id through this ring3 context list. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/i915_drv.c | 1 + drivers/gpu/drm/i915/pxp/intel_pxp.c

[Intel-gfx] [PXP CLEAN PATCH v06 07/27] drm/i915/pxp: Add PXP-related registers into allowlist

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Add several PXP-related reg into allowlist to allow ring3 driver to read the those register values. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/i915_reg.h | 8 drivers/gpu/drm/i915/intel_uncore.c | 57 + 2 files changed, 50

[Intel-gfx] [PXP CLEAN PATCH v06 13/27] drm/i915/pxp: Enable ioctl action to terminate the session

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Enable the PXP ioctl action to allow ring3 PXP to terminate the hardware session and cleanup its software session state. Ring0 PXP sends the session termination command to GPU once receves this ioctl action. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/pxp/intel_

[Intel-gfx] [PXP CLEAN PATCH v06 08/27] drm/i915/pxp: Read register to check hardware session state

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Implement the functions to check the hardware protected session state via reading the hardware register session in play. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/pxp/intel_pxp.h| 3 + drivers/gpu/drm/i915/pxp/intel_pxp_sm.c | 189 +++

[Intel-gfx] [PXP CLEAN PATCH v06 14/27] drm/i915/pxp: Enable ioctl action to query PXP tag

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Enable the PXP ioctl action to allow ring3 PXP to query the PXP tag, which is a 32-bit bitwise value indicating the current session info, including protection type, session id, and whether the session is enabled. Signed-off-by: Huang, Sean Z --- drivers/gpu/drm/i915/pxp/i

[Intel-gfx] [PXP CLEAN PATCH v06 21/27] drm/i915/pxp: Add i915 trace logs for PXP operations

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Add several i915 trace logs for PXP calls for debugging or performance measurement, including: (1) PXP ioctl (2) PXP teardown callbacks To trun on this feature, we need to set "CONFIG_DRM_I915_LOW_LEVEL_TRACEPOINTS=y" in .config for compiling the Linux kernel. Signed-off-b

[Intel-gfx] [PXP CLEAN PATCH v06 15/27] drm/i915/pxp: Destroy all type0 sessions upon teardown

2020-11-13 Thread Sean Z Huang
From: "Huang, Sean Z" Teardown is triggered when the display topology changes and no long meets the secure playback requirement, and hardware trashes all the encryption keys for display. So as a result, ring0 PXP should handle such case and terminate all the type0 sessions. Signed-off-by: Huang,

[Intel-gfx] ✗ Fi.CI.SPARSE: warning for drm/i915: Big bigjoiner series

2020-11-13 Thread Patchwork
== Series Details == Series: drm/i915: Big bigjoiner series URL : https://patchwork.freedesktop.org/series/83837/ State : warning == Summary == $ dim sparse --fast origin/drm-tip Sparse version: v0.6.2 Fast mode used, each commit won't be checked separately. - +drivers/gpu/drm/i915/gt/intel_re

[Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for drm/i915: Big bigjoiner series

2020-11-13 Thread Patchwork
== Series Details == Series: drm/i915: Big bigjoiner series URL : https://patchwork.freedesktop.org/series/83837/ State : warning == Summary == $ dim checkpatch origin/drm-tip 787f109da8f7 drm/i915: Copy the plane hw state directly for Y planes 200e8d85a273 drm/i915: Pass intel_atomic_state ar

[Intel-gfx] ✗ Fi.CI.SPARSE: warning for Allow privileged user to map the OA buffer

2020-11-13 Thread Patchwork
== Series Details == Series: Allow privileged user to map the OA buffer URL : https://patchwork.freedesktop.org/series/83831/ State : warning == Summary == $ dim sparse --fast origin/drm-tip Sparse version: v0.6.2 Fast mode used, each commit won't be checked separately. +drivers/gpu/drm/i915/g

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915/selftests: Small tweak to put the termination conditions together

2020-11-13 Thread Patchwork
== Series Details == Series: drm/i915/selftests: Small tweak to put the termination conditions together URL : https://patchwork.freedesktop.org/series/83823/ State : success == Summary == CI Bug Log - changes from CI_DRM_9326 -> Patchwork_18902

[Intel-gfx] ✓ Fi.CI.BAT: success for series starting with [CI,v11,1/3] drm/i915: Pass intel_atomic_state instead of drm_atomic_state

2020-11-13 Thread Patchwork
== Series Details == Series: series starting with [CI,v11,1/3] drm/i915: Pass intel_atomic_state instead of drm_atomic_state URL : https://patchwork.freedesktop.org/series/83816/ State : success == Summary == CI Bug Log - changes from CI_DRM_9326 -> Patchwork_18901 ===

Re: [Intel-gfx] [PATCH 4/7] drm/i915/perf: Whitelist OA report trigger registers

2020-11-13 Thread Dixit, Ashutosh
On Fri, 13 Nov 2020 14:12:09 -0800, Umesh Nerlige Ramappa wrote: > > > + if (wal->engine) > > + spin_lock_irqsave(&wal->engine->uncore->lock, flags); > > + > > + kfree(wal->list); > > if (wal->list) > kfree(wal->list); void kfree(const void *objp) { ... if (unl

[Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for series starting with [CI,v11,1/3] drm/i915: Pass intel_atomic_state instead of drm_atomic_state

2020-11-13 Thread Patchwork
== Series Details == Series: series starting with [CI,v11,1/3] drm/i915: Pass intel_atomic_state instead of drm_atomic_state URL : https://patchwork.freedesktop.org/series/83816/ State : warning == Summary == $ dim checkpatch origin/drm-tip fe509581680b drm/i915: Pass intel_atomic_state inste

Re: [Intel-gfx] [PATCH 4/7] drm/i915/perf: Whitelist OA report trigger registers

2020-11-13 Thread Umesh Nerlige Ramappa
On Fri, Nov 13, 2020 at 10:03:56AM -0800, Umesh Nerlige Ramappa wrote: OA reports can be triggered into the OA buffer by writing into the OAREPORTTRIG registers. Whitelist the registers to allow non-privileged user to trigger reports. Whitelist registers only if perf_stream_paranoid is set to 0.

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: Eliminate intel_atomic_crtc_state_for_each_plane_state() from skl+ wm code (rev2)

2020-11-13 Thread Patchwork
== Series Details == Series: drm/i915: Eliminate intel_atomic_crtc_state_for_each_plane_state() from skl+ wm code (rev2) URL : https://patchwork.freedesktop.org/series/83589/ State : success == Summary == CI Bug Log - changes from CI_DRM_9326 -> Patchwork_18900 ===

[Intel-gfx] [PATCH 22/23] drm/i915: Add bigjoiner state dump

2020-11-13 Thread Ville Syrjala
From: Ville Syrjälä Add a big of bigjoiner information to the state dump. Signed-off-by: Ville Syrjälä --- drivers/gpu/drm/i915/display/intel_display.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_dis

[Intel-gfx] [PATCH 20/23] drm/i915: Disable legacy cursor fastpath for bigjoiner

2020-11-13 Thread Ville Syrjala
From: Ville Syrjälä The legacy cursor fastpath code doesn't deal with bigjoiner. Disable the fastpath for now. Signed-off-by: Ville Syrjälä --- drivers/gpu/drm/i915/display/intel_display.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/display/intel

[Intel-gfx] [PATCH 19/23] drm/i915: Add debugfs dumping for bigjoiner, v3.

2020-11-13 Thread Ville Syrjala
From: Maarten Lankhorst Dump debugfs and planar links as well, this will make it easier to debug when things go wrong. v4: * Rebase Changes since v1: - Report planar slaves as such, now that we have the plane_state switch. Changes since v2: - Rebase on top of the new plane format dumping Signed

[Intel-gfx] [PATCH 23/23] drm/i915: Enable bigjoiner

2020-11-13 Thread Ville Syrjala
From: Ville Syrjälä Enough plumbing should be in place to throw the bigjoiner switch. Signed-off-by: Ville Syrjälä --- drivers/gpu/drm/i915/display/intel_dp.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/drivers/gpu/drm/i915/display/intel_dp.

[Intel-gfx] [PATCH 21/23] drm/i915: Fix cursor src/dst rectangle with bigjoiner

2020-11-13 Thread Ville Syrjala
From: Ville Syrjälä We can't call drm_plane_state_src() this late for the slave plane since it would consult the wrong uapi state. We've alreayd done the correct uapi->hw copy earlier, so let's just preserve the unclipped src/dst rects using a temp copy across the intel_atomic_plane_check_clippin

[Intel-gfx] [PATCH 18/23] drm/i915: Add bigjoiner aware plane clipping checks

2020-11-13 Thread Ville Syrjala
From: Maarten Lankhorst We need to look at hw.fb for the framebuffer, and add the translation for the slave_plane_state. With these changes we set the correct rectangle on the bigjoiner slave, and don't set incorrect src/dst/visibility on the slave plane. v2: * Manual rebase (Manasi) v3: * hw.r

[Intel-gfx] [PATCH 12/23] drm/i915/dp: Modify VDSC helpers to configure DSC for Bigjoiner slave

2020-11-13 Thread Ville Syrjala
From: Manasi Navare Make vdsc work when no output is enabled. The big joiner needs VDSC on the slave, so enable it and set the appropriate bits. So remove encoder usage from dsc functions. Signed-off-by: Manasi Navare --- drivers/gpu/drm/i915/display/icl_dsi.c | 2 +- drivers/gpu/drm/i

[Intel-gfx] [PATCH 17/23] drm/i915: Get the uapi state from the correct plane when bigjoiner is used

2020-11-13 Thread Ville Syrjala
From: Ville Syrjälä When using bigjoiner userspace is only controlling the "master" plane, so use its uapi state for the "slave" plane as well. hw.crtc needs a bit of magic since we don't want to copy that from the uapi state (as it points to the wrong pipe for the "slave " plane). Instead we pa

[Intel-gfx] [PATCH 04/23] drm/i915: Pimp the watermark documentation a bit

2020-11-13 Thread Ville Syrjala
From: Ville Syrjälä Document what each of the "raw" vs. "optimal" vs. "intermediate" watermarks do. Signed-off-by: Ville Syrjälä --- .../drm/i915/display/intel_display_types.h| 48 ++- 1 file changed, 25 insertions(+), 23 deletions(-) diff --git a/drivers/gpu/drm/i915/disp

[Intel-gfx] [PATCH 03/23] drm/i915: Nuke intel_atomic_crtc_state_for_each_plane_state() from skl+ wm code

2020-11-13 Thread Ville Syrjala
From: Ville Syrjälä intel_atomic_crtc_state_for_each_plane_state() peeks at the plane's current state without holding the plane's mutex, trusting that the crtc's mutex will protect it. In practice that does work since our planes can't move between pipes, but it sets a bad example. intel_atomic_cr

[Intel-gfx] [PATCH 05/23] drm/i915: Precompute can_sagv for each wm level

2020-11-13 Thread Ville Syrjala
From: Ville Syrjälä In order to remove intel_atomic_crtc_state_for_each_plane_state() from skl_crtc_can_enable_sagv() we can simply precompute whether each wm level can tolerate the SAGV block time latency or not. This has the nice side benefit that we remove the duplicated wm level latency calc

[Intel-gfx] [PATCH 10/23] drm/i915/dp: Allow big joiner modes in intel_dp_mode_valid(), v3.

2020-11-13 Thread Ville Syrjala
From: Maarten Lankhorst Small changes to intel_dp_mode_valid(), allow listing modes that can only be supported in the bigjoiner configuration, which is not supported yet. v13: * Allow bigjoiner if hdisplay >5120 v12: * slice_count logic simplify (Ville) * Fix unnecessary changes in downstream_mo

[Intel-gfx] [PATCH 15/23] drm/i915: Add crtcs affected by bigjoiner to the state

2020-11-13 Thread Ville Syrjala
From: Ville Syrjälä Make sure both crtcs participating in the bigjoiner stuff are in the state. Signed-off-by: Ville Syrjälä --- drivers/gpu/drm/i915/display/intel_display.c | 25 1 file changed, 25 insertions(+) diff --git a/drivers/gpu/drm/i915/display/intel_display.c

[Intel-gfx] [PATCH 14/23] drm/i915: HW state readout for Bigjoiner case

2020-11-13 Thread Ville Syrjala
From: Manasi Navare Skip iterating over bigjoiner slaves, only the master has the state we care about. Add the width of the bigjoiner slave to the reconstructed fb. Hide the bigjoiner slave to userspace, and double the mode on bigjoiner master. And last, disable bigjoiner slave from primary if

[Intel-gfx] [PATCH 09/23] drm/i915/dp: Add from_crtc_state to copy color blobs

2020-11-13 Thread Ville Syrjala
From: Manasi Navare No functional changes here, just adds a from_crtc_state as a prep for bigjoiner v2: * More prep with intel_atomic_state (Ville) Cc: Ville Syrjälä Signed-off-by: Manasi Navare Reviewed-by: Ville Syrjälä --- drivers/gpu/drm/i915/display/intel_atomic.c | 9 + drive

[Intel-gfx] [PATCH 08/23] drm/i915: Pass intel_atomic_state instead of drm_atomic_state

2020-11-13 Thread Ville Syrjala
From: Manasi Navare No functional changes, to align with previous cleanups pass intel_atomic_state instead of drm_atomic_state. Also pass this intel_atomic_state with crtc_state to some of the atomic_check functions. v2: * Squash some changes from next patch (Ville) Signed-off-by: Manasi Navare

[Intel-gfx] [PATCH 16/23] drm/i915: Add planes affected by bigjoiner to the state

2020-11-13 Thread Ville Syrjala
From: Ville Syrjälä Make sure both the bigjoiner "master" and "slave" plane are in the state whenever either of them is in the state. Signed-off-by: Ville Syrjälä --- drivers/gpu/drm/i915/display/intel_display.c | 42 1 file changed, 42 insertions(+) diff --git a/drivers/

[Intel-gfx] [PATCH 06/23] drm/i915: Store plane relative data rate in crtc_state

2020-11-13 Thread Ville Syrjala
From: Ville Syrjälä Store the relative data rate for planes in the crtc state so that we don't have to use intel_atomic_crtc_state_for_each_plane_state() to compute it even for the planes that are no part of the current state. Should probably just nuke this stuff entirely an use the normal plane

[Intel-gfx] [PATCH 13/23] drm/i915/dp: Master/Slave enable/disable sequence for bigjoiner

2020-11-13 Thread Ville Syrjala
From: Manasi Navare Enabling is done in a special sequence and so should plane updates be. Ideally the end user never notices the second pipe is used. This way ideally everything will be tear free, and updates are really atomic as userspace expects it. This uses generic modeset_enables() calls

[Intel-gfx] [PATCH 11/23] drm/i915: Try to make bigjoiner work in atomic check

2020-11-13 Thread Ville Syrjala
From: Maarten Lankhorst When the clock is higher than the dotclock, try with 2 pipes enabled. If we can enable 2, then we will go into big joiner mode, and steal the adjacent crtc. This only links the crtc's in software, no hardware or plane programming is done yet. Blobs are also copied fr

[Intel-gfx] [PATCH 07/23] drm/i915: Remove skl_adjusted_plane_pixel_rate()

2020-11-13 Thread Ville Syrjala
From: Ville Syrjälä Replace skl_adjusted_plane_pixel_rate() with the generic intel_plane_pixel_rate(). The two should produce identical results. Signed-off-by: Ville Syrjälä --- drivers/gpu/drm/i915/intel_pm.c | 27 ++- 1 file changed, 2 insertions(+), 25 deletions(-)

  1   2   >