* [PATCH] drm/i915/pxp: limit drm-errors or warning on firmware API failures
@ 2023-02-04 5:48 ` Alan Previn
0 siblings, 0 replies; 6+ messages in thread
From: Alan Previn @ 2023-02-04 5:48 UTC (permalink / raw)
To: intel-gfx; +Cc: Tvrtko Ursulin, Daniele Ceraolo Spurio, dri-devel, Alan Previn
MESA driver is creating protected context on every driver handle
creation to query caps bits for app. So when running CI tests,
they are observing hundreds of drm_errors when enabling PXP
in .config but using SOC fusing or BIOS configuration that cannot
support PXP sessions.
The fixes tag referenced below was to resolve a related issue
where we wanted to silence error messages, but that case was due
to outdated IFWI (firmware) that definitely needed an upgrade and
was, at that point, considered a one-off case as opposed to today's
realization that default CI was enabling PXP in kernel config for
all testing.
So with this patch, let's strike a balance between issues that is
critical but are root-caused from HW/platform gaps (louder drm-warn
but just ONCE) vs other cases where it could also come from session
state machine (which cannot be a WARN_ONCE since it can be triggered
due to runtime operation events).
Let's use helpers for these so as more functions are added in future
features / HW (or as FW designers continue to bless upstreaming of
the error codes and meanings), we only need to update the helpers.
NOTE: Don't completely remove FW errors (via drm_debug) or else cusomer
apps that really needs to know that content protection failed won't
be aware of it.
Fixes: b762787bf767 ("drm/i915/pxp: Use drm_dbg if arb session failed due to fw version")
Signed-off-by: Alan Previn <alan.previn.teres.alexis@intel.com>
---
.../i915/pxp/intel_pxp_cmd_interface_cmn.h | 3 +
drivers/gpu/drm/i915/pxp/intel_pxp_session.c | 2 +-
drivers/gpu/drm/i915/pxp/intel_pxp_tee.c | 73 +++++++++++++++----
3 files changed, 64 insertions(+), 14 deletions(-)
diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h b/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h
index ae9b151b7cb7..6f6541d5e49a 100644
--- a/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h
+++ b/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h
@@ -18,6 +18,9 @@
enum pxp_status {
PXP_STATUS_SUCCESS = 0x0,
PXP_STATUS_ERROR_API_VERSION = 0x1002,
+ PXP_STATUS_NOT_READY = 0x100e,
+ PXP_STATUS_PLATFCONFIG_KF1_NOVERIF = 0x101a,
+ PXP_STATUS_PLATFCONFIG_KF1_BAD = 0x101f,
PXP_STATUS_OP_NOT_PERMITTED = 0x4013
};
diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_session.c b/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
index 448cacb0465d..7de849cb6c47 100644
--- a/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
+++ b/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
@@ -74,7 +74,7 @@ static int pxp_create_arb_session(struct intel_pxp *pxp)
ret = pxp_wait_for_session_state(pxp, ARB_SESSION, true);
if (ret) {
- drm_err(>->i915->drm, "arb session failed to go in play\n");
+ drm_dbg(>->i915->drm, "arb session failed to go in play\n");
return ret;
}
drm_dbg(>->i915->drm, "PXP ARB session is alive\n");
diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c b/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c
index d9d248b48093..2d3bcff93da3 100644
--- a/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c
+++ b/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c
@@ -19,6 +19,37 @@
#include "intel_pxp_tee.h"
#include "intel_pxp_types.h"
+static bool
+is_fw_err_platform_config(u32 type)
+{
+ switch (type) {
+ case PXP_STATUS_ERROR_API_VERSION:
+ case PXP_STATUS_PLATFCONFIG_KF1_NOVERIF:
+ case PXP_STATUS_PLATFCONFIG_KF1_BAD:
+ return true;
+ default:
+ break;
+ }
+ return false;
+}
+
+static const char *
+fw_err_to_string(u32 type)
+{
+ switch (type) {
+ case PXP_STATUS_ERROR_API_VERSION:
+ return "ERR_API_VERSION";
+ case PXP_STATUS_NOT_READY:
+ return "ERR_NOT_READY";
+ case PXP_STATUS_PLATFCONFIG_KF1_NOVERIF:
+ case PXP_STATUS_PLATFCONFIG_KF1_BAD:
+ return "ERR_PLATFORM_CONFIG";
+ default:
+ break;
+ }
+ return NULL;
+}
+
static int intel_pxp_tee_io_message(struct intel_pxp *pxp,
void *msg_in, u32 msg_in_size,
void *msg_out, u32 msg_out_max_size,
@@ -307,15 +338,21 @@ int intel_pxp_tee_cmd_create_arb_session(struct intel_pxp *pxp,
&msg_out, sizeof(msg_out),
NULL);
- if (ret)
- drm_err(&i915->drm, "Failed to send tee msg ret=[%d]\n", ret);
- else if (msg_out.header.status == PXP_STATUS_ERROR_API_VERSION)
- drm_dbg(&i915->drm, "PXP firmware version unsupported, requested: "
- "CMD-ID-[0x%08x] on API-Ver-[0x%08x]\n",
- msg_in.header.command_id, msg_in.header.api_version);
- else if (msg_out.header.status != 0x0)
- drm_warn(&i915->drm, "PXP firmware failed arb session init request ret=[0x%08x]\n",
- msg_out.header.status);
+ if (ret) {
+ drm_err(&i915->drm, "Failed to send tee msg init arb session, ret=[%d]\n", ret);
+ } else if (msg_out.header.status != 0) {
+ if (is_fw_err_platform_config(msg_out.header.status))
+ drm_WARN_ONCE(&i915->drm, true,
+ "PXP init-arb-session-%d failed due to BIOS/SOC:0x%08x:%s\n",
+ (int)arb_session_id, msg_out.header.status,
+ fw_err_to_string(msg_out.header.status));
+ else
+ drm_dbg(&i915->drm, "PXP init-arb-session--%d failed 0x%08x:%st:\n"
+ "CMD-ID-[0x%08x]:API-Ver-[0x%08x]\n",
+ (int)arb_session_id, msg_out.header.status,
+ fw_err_to_string(msg_out.header.status),
+ msg_in.header.command_id, msg_in.header.api_version);
+ }
return ret;
}
@@ -347,10 +384,20 @@ void intel_pxp_tee_end_arb_fw_session(struct intel_pxp *pxp, u32 session_id)
if ((ret || msg_out.header.status != 0x0) && ++trials < 3)
goto try_again;
- if (ret)
+ if (ret) {
drm_err(&i915->drm, "Failed to send tee msg for inv-stream-key-%d, ret=[%d]\n",
session_id, ret);
- else if (msg_out.header.status != 0x0)
- drm_warn(&i915->drm, "PXP firmware failed inv-stream-key-%d with status 0x%08x\n",
- session_id, msg_out.header.status);
+ } else if (msg_out.header.status != 0) {
+ if (is_fw_err_platform_config(msg_out.header.status))
+ drm_WARN_ONCE(&i915->drm, true,
+ "PXP inv-stream-key-%d failed due to BIOS/SOC :0x%08x:%s\n",
+ (int)session_id, msg_out.header.status,
+ fw_err_to_string(msg_out.header.status));
+ else
+ drm_dbg(&i915->drm, "PXP inv-stream-key-%d failed 0x%08x:%s:\n"
+ "CMD-ID-[0x%08x]:API-Ver-[0x%08x]\n",
+ (int)session_id, msg_out.header.status,
+ fw_err_to_string(msg_out.header.status),
+ msg_in.header.command_id, msg_in.header.api_version);
+ }
}
--
2.39.0
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [Intel-gfx] [PATCH] drm/i915/pxp: limit drm-errors or warning on firmware API failures
@ 2023-02-04 5:48 ` Alan Previn
0 siblings, 0 replies; 6+ messages in thread
From: Alan Previn @ 2023-02-04 5:48 UTC (permalink / raw)
To: intel-gfx; +Cc: dri-devel, Alan Previn
MESA driver is creating protected context on every driver handle
creation to query caps bits for app. So when running CI tests,
they are observing hundreds of drm_errors when enabling PXP
in .config but using SOC fusing or BIOS configuration that cannot
support PXP sessions.
The fixes tag referenced below was to resolve a related issue
where we wanted to silence error messages, but that case was due
to outdated IFWI (firmware) that definitely needed an upgrade and
was, at that point, considered a one-off case as opposed to today's
realization that default CI was enabling PXP in kernel config for
all testing.
So with this patch, let's strike a balance between issues that is
critical but are root-caused from HW/platform gaps (louder drm-warn
but just ONCE) vs other cases where it could also come from session
state machine (which cannot be a WARN_ONCE since it can be triggered
due to runtime operation events).
Let's use helpers for these so as more functions are added in future
features / HW (or as FW designers continue to bless upstreaming of
the error codes and meanings), we only need to update the helpers.
NOTE: Don't completely remove FW errors (via drm_debug) or else cusomer
apps that really needs to know that content protection failed won't
be aware of it.
Fixes: b762787bf767 ("drm/i915/pxp: Use drm_dbg if arb session failed due to fw version")
Signed-off-by: Alan Previn <alan.previn.teres.alexis@intel.com>
---
.../i915/pxp/intel_pxp_cmd_interface_cmn.h | 3 +
drivers/gpu/drm/i915/pxp/intel_pxp_session.c | 2 +-
drivers/gpu/drm/i915/pxp/intel_pxp_tee.c | 73 +++++++++++++++----
3 files changed, 64 insertions(+), 14 deletions(-)
diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h b/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h
index ae9b151b7cb7..6f6541d5e49a 100644
--- a/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h
+++ b/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h
@@ -18,6 +18,9 @@
enum pxp_status {
PXP_STATUS_SUCCESS = 0x0,
PXP_STATUS_ERROR_API_VERSION = 0x1002,
+ PXP_STATUS_NOT_READY = 0x100e,
+ PXP_STATUS_PLATFCONFIG_KF1_NOVERIF = 0x101a,
+ PXP_STATUS_PLATFCONFIG_KF1_BAD = 0x101f,
PXP_STATUS_OP_NOT_PERMITTED = 0x4013
};
diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_session.c b/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
index 448cacb0465d..7de849cb6c47 100644
--- a/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
+++ b/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
@@ -74,7 +74,7 @@ static int pxp_create_arb_session(struct intel_pxp *pxp)
ret = pxp_wait_for_session_state(pxp, ARB_SESSION, true);
if (ret) {
- drm_err(>->i915->drm, "arb session failed to go in play\n");
+ drm_dbg(>->i915->drm, "arb session failed to go in play\n");
return ret;
}
drm_dbg(>->i915->drm, "PXP ARB session is alive\n");
diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c b/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c
index d9d248b48093..2d3bcff93da3 100644
--- a/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c
+++ b/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c
@@ -19,6 +19,37 @@
#include "intel_pxp_tee.h"
#include "intel_pxp_types.h"
+static bool
+is_fw_err_platform_config(u32 type)
+{
+ switch (type) {
+ case PXP_STATUS_ERROR_API_VERSION:
+ case PXP_STATUS_PLATFCONFIG_KF1_NOVERIF:
+ case PXP_STATUS_PLATFCONFIG_KF1_BAD:
+ return true;
+ default:
+ break;
+ }
+ return false;
+}
+
+static const char *
+fw_err_to_string(u32 type)
+{
+ switch (type) {
+ case PXP_STATUS_ERROR_API_VERSION:
+ return "ERR_API_VERSION";
+ case PXP_STATUS_NOT_READY:
+ return "ERR_NOT_READY";
+ case PXP_STATUS_PLATFCONFIG_KF1_NOVERIF:
+ case PXP_STATUS_PLATFCONFIG_KF1_BAD:
+ return "ERR_PLATFORM_CONFIG";
+ default:
+ break;
+ }
+ return NULL;
+}
+
static int intel_pxp_tee_io_message(struct intel_pxp *pxp,
void *msg_in, u32 msg_in_size,
void *msg_out, u32 msg_out_max_size,
@@ -307,15 +338,21 @@ int intel_pxp_tee_cmd_create_arb_session(struct intel_pxp *pxp,
&msg_out, sizeof(msg_out),
NULL);
- if (ret)
- drm_err(&i915->drm, "Failed to send tee msg ret=[%d]\n", ret);
- else if (msg_out.header.status == PXP_STATUS_ERROR_API_VERSION)
- drm_dbg(&i915->drm, "PXP firmware version unsupported, requested: "
- "CMD-ID-[0x%08x] on API-Ver-[0x%08x]\n",
- msg_in.header.command_id, msg_in.header.api_version);
- else if (msg_out.header.status != 0x0)
- drm_warn(&i915->drm, "PXP firmware failed arb session init request ret=[0x%08x]\n",
- msg_out.header.status);
+ if (ret) {
+ drm_err(&i915->drm, "Failed to send tee msg init arb session, ret=[%d]\n", ret);
+ } else if (msg_out.header.status != 0) {
+ if (is_fw_err_platform_config(msg_out.header.status))
+ drm_WARN_ONCE(&i915->drm, true,
+ "PXP init-arb-session-%d failed due to BIOS/SOC:0x%08x:%s\n",
+ (int)arb_session_id, msg_out.header.status,
+ fw_err_to_string(msg_out.header.status));
+ else
+ drm_dbg(&i915->drm, "PXP init-arb-session--%d failed 0x%08x:%st:\n"
+ "CMD-ID-[0x%08x]:API-Ver-[0x%08x]\n",
+ (int)arb_session_id, msg_out.header.status,
+ fw_err_to_string(msg_out.header.status),
+ msg_in.header.command_id, msg_in.header.api_version);
+ }
return ret;
}
@@ -347,10 +384,20 @@ void intel_pxp_tee_end_arb_fw_session(struct intel_pxp *pxp, u32 session_id)
if ((ret || msg_out.header.status != 0x0) && ++trials < 3)
goto try_again;
- if (ret)
+ if (ret) {
drm_err(&i915->drm, "Failed to send tee msg for inv-stream-key-%d, ret=[%d]\n",
session_id, ret);
- else if (msg_out.header.status != 0x0)
- drm_warn(&i915->drm, "PXP firmware failed inv-stream-key-%d with status 0x%08x\n",
- session_id, msg_out.header.status);
+ } else if (msg_out.header.status != 0) {
+ if (is_fw_err_platform_config(msg_out.header.status))
+ drm_WARN_ONCE(&i915->drm, true,
+ "PXP inv-stream-key-%d failed due to BIOS/SOC :0x%08x:%s\n",
+ (int)session_id, msg_out.header.status,
+ fw_err_to_string(msg_out.header.status));
+ else
+ drm_dbg(&i915->drm, "PXP inv-stream-key-%d failed 0x%08x:%s:\n"
+ "CMD-ID-[0x%08x]:API-Ver-[0x%08x]\n",
+ (int)session_id, msg_out.header.status,
+ fw_err_to_string(msg_out.header.status),
+ msg_in.header.command_id, msg_in.header.api_version);
+ }
}
--
2.39.0
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915/pxp: limit drm-errors or warning on firmware API failures
2023-02-04 5:48 ` [Intel-gfx] " Alan Previn
(?)
@ 2023-02-04 17:22 ` Patchwork
-1 siblings, 0 replies; 6+ messages in thread
From: Patchwork @ 2023-02-04 17:22 UTC (permalink / raw)
To: Teres Alexis, Alan Previn; +Cc: intel-gfx
[-- Attachment #1: Type: text/plain, Size: 2091 bytes --]
== Series Details ==
Series: drm/i915/pxp: limit drm-errors or warning on firmware API failures
URL : https://patchwork.freedesktop.org/series/113680/
State : success
== Summary ==
CI Bug Log - changes from CI_DRM_12693 -> Patchwork_113680v1
====================================================
Summary
-------
**SUCCESS**
No regressions found.
External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/index.html
Participating hosts (27 -> 25)
------------------------------
Missing (2): fi-kbl-soraka fi-snb-2520m
Known issues
------------
Here are the changes found in Patchwork_113680v1 that come from known issues:
### IGT changes ###
#### Possible fixes ####
* igt@i915_selftest@live@requests:
- {bat-rpls-1}: [ABORT][1] ([i915#4983]) -> [PASS][2]
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/bat-rpls-1/igt@i915_selftest@live@requests.html
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/bat-rpls-1/igt@i915_selftest@live@requests.html
{name}: This element is suppressed. This means it is ignored when computing
the status of the difference (SUCCESS, WARNING, or FAILURE).
[i915#4983]: https://gitlab.freedesktop.org/drm/intel/issues/4983
[i915#5354]: https://gitlab.freedesktop.org/drm/intel/issues/5354
[i915#6367]: https://gitlab.freedesktop.org/drm/intel/issues/6367
[i915#7978]: https://gitlab.freedesktop.org/drm/intel/issues/7978
Build changes
-------------
* Linux: CI_DRM_12693 -> Patchwork_113680v1
CI-20190529: 20190529
CI_DRM_12693: 3119889d6832bf30bbe7afd66fdf486f5b14e40f @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_7149: 1c7ea154b625e1fb826f1519b816b4256dd10b62 @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git
Patchwork_113680v1: 3119889d6832bf30bbe7afd66fdf486f5b14e40f @ git://anongit.freedesktop.org/gfx-ci/linux
### Linux commits
117710416172 drm/i915/pxp: limit drm-errors or warning on firmware API failures
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/index.html
[-- Attachment #2: Type: text/html, Size: 2492 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Intel-gfx] ✓ Fi.CI.IGT: success for drm/i915/pxp: limit drm-errors or warning on firmware API failures
2023-02-04 5:48 ` [Intel-gfx] " Alan Previn
(?)
(?)
@ 2023-02-05 17:12 ` Patchwork
-1 siblings, 0 replies; 6+ messages in thread
From: Patchwork @ 2023-02-05 17:12 UTC (permalink / raw)
To: Teres Alexis, Alan Previn; +Cc: intel-gfx
[-- Attachment #1: Type: text/plain, Size: 19888 bytes --]
== Series Details ==
Series: drm/i915/pxp: limit drm-errors or warning on firmware API failures
URL : https://patchwork.freedesktop.org/series/113680/
State : success
== Summary ==
CI Bug Log - changes from CI_DRM_12693_full -> Patchwork_113680v1_full
====================================================
Summary
-------
**SUCCESS**
No regressions found.
External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/index.html
Participating hosts (9 -> 9)
------------------------------
No changes in participating hosts
Possible new issues
-------------------
Here are the unknown changes that may have been introduced in Patchwork_113680v1_full:
### IGT changes ###
#### Suppressed ####
The following results come from untrusted machines, tests, or statuses.
They do not affect the overall result.
* {igt@v3d/v3d_submit_cl@simple-flush-cache}:
- {shard-dg1}: NOTRUN -> [SKIP][1] +2 similar issues
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-dg1-18/igt@v3d/v3d_submit_cl@simple-flush-cache.html
Known issues
------------
Here are the changes found in Patchwork_113680v1_full that come from known issues:
### IGT changes ###
#### Issues hit ####
* igt@gem_lmem_swapping@heavy-verify-multi-ccs:
- shard-glk: NOTRUN -> [SKIP][2] ([fdo#109271] / [i915#4613])
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-glk7/igt@gem_lmem_swapping@heavy-verify-multi-ccs.html
* igt@kms_ccs@pipe-a-crc-sprite-planes-basic-y_tiled_gen12_rc_ccs_cc:
- shard-glk: NOTRUN -> [SKIP][3] ([fdo#109271] / [i915#3886])
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-glk7/igt@kms_ccs@pipe-a-crc-sprite-planes-basic-y_tiled_gen12_rc_ccs_cc.html
* igt@kms_ccs@pipe-c-bad-rotation-90-y_tiled_gen12_rc_ccs:
- shard-glk: NOTRUN -> [SKIP][4] ([fdo#109271]) +14 similar issues
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-glk7/igt@kms_ccs@pipe-c-bad-rotation-90-y_tiled_gen12_rc_ccs.html
* igt@kms_flip@flip-vs-expired-vblank@b-hdmi-a1:
- shard-glk: [PASS][5] -> [FAIL][6] ([i915#79])
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-glk6/igt@kms_flip@flip-vs-expired-vblank@b-hdmi-a1.html
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-glk6/igt@kms_flip@flip-vs-expired-vblank@b-hdmi-a1.html
* igt@kms_plane_alpha_blend@alpha-transparent-fb@pipe-b-hdmi-a-2:
- shard-glk: NOTRUN -> [FAIL][7] ([i915#4573]) +2 similar issues
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-glk7/igt@kms_plane_alpha_blend@alpha-transparent-fb@pipe-b-hdmi-a-2.html
#### Possible fixes ####
* igt@drm_fdinfo@virtual-idle:
- {shard-rkl}: [FAIL][8] ([i915#7742]) -> [PASS][9]
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-3/igt@drm_fdinfo@virtual-idle.html
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-6/igt@drm_fdinfo@virtual-idle.html
* igt@fbdev@nullptr:
- {shard-rkl}: [SKIP][10] ([i915#2582]) -> [PASS][11]
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-3/igt@fbdev@nullptr.html
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-6/igt@fbdev@nullptr.html
* igt@gem_eio@wait-wedge-immediate:
- shard-glk: [TIMEOUT][12] -> [PASS][13] +2 similar issues
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-glk4/igt@gem_eio@wait-wedge-immediate.html
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-glk7/igt@gem_eio@wait-wedge-immediate.html
* igt@gem_exec_fair@basic-none-share@rcs0:
- shard-glk: [FAIL][14] ([i915#2842]) -> [PASS][15]
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-glk8/igt@gem_exec_fair@basic-none-share@rcs0.html
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-glk5/igt@gem_exec_fair@basic-none-share@rcs0.html
* igt@gem_exec_reloc@basic-gtt-wc-noreloc:
- {shard-rkl}: [SKIP][16] ([i915#3281]) -> [PASS][17] +10 similar issues
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-2/igt@gem_exec_reloc@basic-gtt-wc-noreloc.html
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-5/igt@gem_exec_reloc@basic-gtt-wc-noreloc.html
* igt@gem_partial_pwrite_pread@write-snoop:
- {shard-rkl}: [SKIP][18] ([i915#3282]) -> [PASS][19]
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-2/igt@gem_partial_pwrite_pread@write-snoop.html
[19]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-5/igt@gem_partial_pwrite_pread@write-snoop.html
* igt@gen9_exec_parse@unaligned-access:
- {shard-rkl}: [SKIP][20] ([i915#2527]) -> [PASS][21] +1 similar issue
[20]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-2/igt@gen9_exec_parse@unaligned-access.html
[21]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-5/igt@gen9_exec_parse@unaligned-access.html
* igt@i915_pm_rpm@fences:
- {shard-rkl}: [SKIP][22] ([i915#1849]) -> [PASS][23]
[22]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-3/igt@i915_pm_rpm@fences.html
[23]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-6/igt@i915_pm_rpm@fences.html
* igt@i915_pm_rpm@modeset-lpsp-stress:
- {shard-dg1}: [SKIP][24] ([i915#1397]) -> [PASS][25]
[24]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-dg1-17/igt@i915_pm_rpm@modeset-lpsp-stress.html
[25]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-dg1-14/igt@i915_pm_rpm@modeset-lpsp-stress.html
* {igt@i915_power@sanity}:
- {shard-rkl}: [SKIP][26] ([i915#7984]) -> [PASS][27]
[26]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-2/igt@i915_power@sanity.html
[27]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-5/igt@i915_power@sanity.html
* igt@kms_cursor_legacy@2x-long-flip-vs-cursor-legacy:
- shard-glk: [FAIL][28] ([i915#72]) -> [PASS][29]
[28]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-glk2/igt@kms_cursor_legacy@2x-long-flip-vs-cursor-legacy.html
[29]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-glk6/igt@kms_cursor_legacy@2x-long-flip-vs-cursor-legacy.html
* igt@kms_cursor_legacy@flip-vs-cursor@atomic-transitions-varying-size:
- shard-glk: [FAIL][30] ([i915#2346]) -> [PASS][31] +1 similar issue
[30]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-glk5/igt@kms_cursor_legacy@flip-vs-cursor@atomic-transitions-varying-size.html
[31]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-glk9/igt@kms_cursor_legacy@flip-vs-cursor@atomic-transitions-varying-size.html
* igt@kms_frontbuffer_tracking@psr-1p-primscrn-cur-indfb-move:
- {shard-rkl}: [SKIP][32] ([i915#1849] / [i915#4098]) -> [PASS][33] +7 similar issues
[32]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-3/igt@kms_frontbuffer_tracking@psr-1p-primscrn-cur-indfb-move.html
[33]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-6/igt@kms_frontbuffer_tracking@psr-1p-primscrn-cur-indfb-move.html
* igt@kms_psr@primary_blt:
- {shard-rkl}: [SKIP][34] ([i915#1072]) -> [PASS][35]
[34]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-3/igt@kms_psr@primary_blt.html
[35]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-6/igt@kms_psr@primary_blt.html
* igt@kms_vblank@pipe-a-ts-continuation-suspend:
- {shard-rkl}: [SKIP][36] ([i915#1845] / [i915#4098]) -> [PASS][37] +5 similar issues
[36]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-3/igt@kms_vblank@pipe-a-ts-continuation-suspend.html
[37]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-6/igt@kms_vblank@pipe-a-ts-continuation-suspend.html
* igt@perf@enable-disable:
- shard-glk: [TIMEOUT][38] ([i915#6943]) -> [PASS][39]
[38]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-glk4/igt@perf@enable-disable.html
[39]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-glk7/igt@perf@enable-disable.html
* igt@perf@gen12-oa-tlb-invalidate:
- {shard-rkl}: [SKIP][40] ([fdo#109289]) -> [PASS][41]
[40]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-5/igt@perf@gen12-oa-tlb-invalidate.html
[41]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-1/igt@perf@gen12-oa-tlb-invalidate.html
* igt@prime_vgem@basic-fence-read:
- {shard-rkl}: [SKIP][42] ([fdo#109295] / [i915#3291] / [i915#3708]) -> [PASS][43]
[42]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-2/igt@prime_vgem@basic-fence-read.html
[43]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-5/igt@prime_vgem@basic-fence-read.html
* igt@prime_vgem@coherency-gtt:
- {shard-rkl}: [SKIP][44] ([fdo#109295] / [fdo#111656] / [i915#3708]) -> [PASS][45]
[44]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-rkl-2/igt@prime_vgem@coherency-gtt.html
[45]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-rkl-5/igt@prime_vgem@coherency-gtt.html
#### Warnings ####
* igt@feature_discovery@psr2:
- shard-glk: [TIMEOUT][46] -> [SKIP][47] ([fdo#109271])
[46]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12693/shard-glk4/igt@feature_discovery@psr2.html
[47]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/shard-glk7/igt@feature_discovery@psr2.html
{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#109274]: https://bugs.freedesktop.org/show_bug.cgi?id=109274
[fdo#109279]: https://bugs.freedesktop.org/show_bug.cgi?id=109279
[fdo#109280]: https://bugs.freedesktop.org/show_bug.cgi?id=109280
[fdo#109285]: https://bugs.freedesktop.org/show_bug.cgi?id=109285
[fdo#109289]: https://bugs.freedesktop.org/show_bug.cgi?id=109289
[fdo#109295]: https://bugs.freedesktop.org/show_bug.cgi?id=109295
[fdo#109302]: https://bugs.freedesktop.org/show_bug.cgi?id=109302
[fdo#109307]: https://bugs.freedesktop.org/show_bug.cgi?id=109307
[fdo#109312]: https://bugs.freedesktop.org/show_bug.cgi?id=109312
[fdo#109314]: https://bugs.freedesktop.org/show_bug.cgi?id=109314
[fdo#109315]: https://bugs.freedesktop.org/show_bug.cgi?id=109315
[fdo#109506]: https://bugs.freedesktop.org/show_bug.cgi?id=109506
[fdo#109642]: https://bugs.freedesktop.org/show_bug.cgi?id=109642
[fdo#110189]: https://bugs.freedesktop.org/show_bug.cgi?id=110189
[fdo#110542]: https://bugs.freedesktop.org/show_bug.cgi?id=110542
[fdo#110723]: https://bugs.freedesktop.org/show_bug.cgi?id=110723
[fdo#111068]: https://bugs.freedesktop.org/show_bug.cgi?id=111068
[fdo#111614]: https://bugs.freedesktop.org/show_bug.cgi?id=111614
[fdo#111615]: https://bugs.freedesktop.org/show_bug.cgi?id=111615
[fdo#111644]: https://bugs.freedesktop.org/show_bug.cgi?id=111644
[fdo#111656]: https://bugs.freedesktop.org/show_bug.cgi?id=111656
[fdo#111825]: https://bugs.freedesktop.org/show_bug.cgi?id=111825
[fdo#111827]: https://bugs.freedesktop.org/show_bug.cgi?id=111827
[fdo#112054]: https://bugs.freedesktop.org/show_bug.cgi?id=112054
[fdo#112283]: https://bugs.freedesktop.org/show_bug.cgi?id=112283
[i915#1072]: https://gitlab.freedesktop.org/drm/intel/issues/1072
[i915#132]: https://gitlab.freedesktop.org/drm/intel/issues/132
[i915#1397]: https://gitlab.freedesktop.org/drm/intel/issues/1397
[i915#1769]: https://gitlab.freedesktop.org/drm/intel/issues/1769
[i915#1825]: https://gitlab.freedesktop.org/drm/intel/issues/1825
[i915#1839]: https://gitlab.freedesktop.org/drm/intel/issues/1839
[i915#1845]: https://gitlab.freedesktop.org/drm/intel/issues/1845
[i915#1849]: https://gitlab.freedesktop.org/drm/intel/issues/1849
[i915#2346]: https://gitlab.freedesktop.org/drm/intel/issues/2346
[i915#2437]: https://gitlab.freedesktop.org/drm/intel/issues/2437
[i915#2527]: https://gitlab.freedesktop.org/drm/intel/issues/2527
[i915#2575]: https://gitlab.freedesktop.org/drm/intel/issues/2575
[i915#2582]: https://gitlab.freedesktop.org/drm/intel/issues/2582
[i915#2587]: https://gitlab.freedesktop.org/drm/intel/issues/2587
[i915#2672]: https://gitlab.freedesktop.org/drm/intel/issues/2672
[i915#2705]: https://gitlab.freedesktop.org/drm/intel/issues/2705
[i915#280]: https://gitlab.freedesktop.org/drm/intel/issues/280
[i915#284]: https://gitlab.freedesktop.org/drm/intel/issues/284
[i915#2842]: https://gitlab.freedesktop.org/drm/intel/issues/2842
[i915#2856]: https://gitlab.freedesktop.org/drm/intel/issues/2856
[i915#2920]: https://gitlab.freedesktop.org/drm/intel/issues/2920
[i915#3116]: https://gitlab.freedesktop.org/drm/intel/issues/3116
[i915#315]: https://gitlab.freedesktop.org/drm/intel/issues/315
[i915#3281]: https://gitlab.freedesktop.org/drm/intel/issues/3281
[i915#3282]: https://gitlab.freedesktop.org/drm/intel/issues/3282
[i915#3291]: https://gitlab.freedesktop.org/drm/intel/issues/3291
[i915#3297]: https://gitlab.freedesktop.org/drm/intel/issues/3297
[i915#3299]: https://gitlab.freedesktop.org/drm/intel/issues/3299
[i915#3301]: https://gitlab.freedesktop.org/drm/intel/issues/3301
[i915#3318]: https://gitlab.freedesktop.org/drm/intel/issues/3318
[i915#3359]: https://gitlab.freedesktop.org/drm/intel/issues/3359
[i915#3458]: https://gitlab.freedesktop.org/drm/intel/issues/3458
[i915#3469]: https://gitlab.freedesktop.org/drm/intel/issues/3469
[i915#3528]: https://gitlab.freedesktop.org/drm/intel/issues/3528
[i915#3539]: https://gitlab.freedesktop.org/drm/intel/issues/3539
[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#3638]: https://gitlab.freedesktop.org/drm/intel/issues/3638
[i915#3689]: https://gitlab.freedesktop.org/drm/intel/issues/3689
[i915#3708]: https://gitlab.freedesktop.org/drm/intel/issues/3708
[i915#3734]: https://gitlab.freedesktop.org/drm/intel/issues/3734
[i915#3743]: https://gitlab.freedesktop.org/drm/intel/issues/3743
[i915#3804]: https://gitlab.freedesktop.org/drm/intel/issues/3804
[i915#3886]: https://gitlab.freedesktop.org/drm/intel/issues/3886
[i915#4036]: https://gitlab.freedesktop.org/drm/intel/issues/4036
[i915#404]: https://gitlab.freedesktop.org/drm/intel/issues/404
[i915#4070]: https://gitlab.freedesktop.org/drm/intel/issues/4070
[i915#4077]: https://gitlab.freedesktop.org/drm/intel/issues/4077
[i915#4078]: https://gitlab.freedesktop.org/drm/intel/issues/4078
[i915#4079]: https://gitlab.freedesktop.org/drm/intel/issues/4079
[i915#4083]: https://gitlab.freedesktop.org/drm/intel/issues/4083
[i915#4098]: https://gitlab.freedesktop.org/drm/intel/issues/4098
[i915#4212]: https://gitlab.freedesktop.org/drm/intel/issues/4212
[i915#426]: https://gitlab.freedesktop.org/drm/intel/issues/426
[i915#4270]: https://gitlab.freedesktop.org/drm/intel/issues/4270
[i915#4281]: https://gitlab.freedesktop.org/drm/intel/issues/4281
[i915#433]: https://gitlab.freedesktop.org/drm/intel/issues/433
[i915#4349]: https://gitlab.freedesktop.org/drm/intel/issues/4349
[i915#4387]: https://gitlab.freedesktop.org/drm/intel/issues/4387
[i915#4538]: https://gitlab.freedesktop.org/drm/intel/issues/4538
[i915#4573]: https://gitlab.freedesktop.org/drm/intel/issues/4573
[i915#4613]: https://gitlab.freedesktop.org/drm/intel/issues/4613
[i915#4771]: https://gitlab.freedesktop.org/drm/intel/issues/4771
[i915#4818]: https://gitlab.freedesktop.org/drm/intel/issues/4818
[i915#4833]: https://gitlab.freedesktop.org/drm/intel/issues/4833
[i915#4852]: https://gitlab.freedesktop.org/drm/intel/issues/4852
[i915#4854]: https://gitlab.freedesktop.org/drm/intel/issues/4854
[i915#4860]: https://gitlab.freedesktop.org/drm/intel/issues/4860
[i915#4873]: https://gitlab.freedesktop.org/drm/intel/issues/4873
[i915#4885]: https://gitlab.freedesktop.org/drm/intel/issues/4885
[i915#5176]: https://gitlab.freedesktop.org/drm/intel/issues/5176
[i915#5235]: https://gitlab.freedesktop.org/drm/intel/issues/5235
[i915#5286]: https://gitlab.freedesktop.org/drm/intel/issues/5286
[i915#5288]: https://gitlab.freedesktop.org/drm/intel/issues/5288
[i915#5289]: https://gitlab.freedesktop.org/drm/intel/issues/5289
[i915#5325]: https://gitlab.freedesktop.org/drm/intel/issues/5325
[i915#533]: https://gitlab.freedesktop.org/drm/intel/issues/533
[i915#5439]: https://gitlab.freedesktop.org/drm/intel/issues/5439
[i915#5461]: https://gitlab.freedesktop.org/drm/intel/issues/5461
[i915#5563]: https://gitlab.freedesktop.org/drm/intel/issues/5563
[i915#6095]: https://gitlab.freedesktop.org/drm/intel/issues/6095
[i915#6117]: https://gitlab.freedesktop.org/drm/intel/issues/6117
[i915#6230]: https://gitlab.freedesktop.org/drm/intel/issues/6230
[i915#6248]: https://gitlab.freedesktop.org/drm/intel/issues/6248
[i915#6259]: https://gitlab.freedesktop.org/drm/intel/issues/6259
[i915#6301]: https://gitlab.freedesktop.org/drm/intel/issues/6301
[i915#6335]: https://gitlab.freedesktop.org/drm/intel/issues/6335
[i915#6497]: https://gitlab.freedesktop.org/drm/intel/issues/6497
[i915#6524]: https://gitlab.freedesktop.org/drm/intel/issues/6524
[i915#658]: https://gitlab.freedesktop.org/drm/intel/issues/658
[i915#6590]: https://gitlab.freedesktop.org/drm/intel/issues/6590
[i915#6621]: https://gitlab.freedesktop.org/drm/intel/issues/6621
[i915#6768]: https://gitlab.freedesktop.org/drm/intel/issues/6768
[i915#6943]: https://gitlab.freedesktop.org/drm/intel/issues/6943
[i915#6944]: https://gitlab.freedesktop.org/drm/intel/issues/6944
[i915#6946]: https://gitlab.freedesktop.org/drm/intel/issues/6946
[i915#7037]: https://gitlab.freedesktop.org/drm/intel/issues/7037
[i915#7116]: https://gitlab.freedesktop.org/drm/intel/issues/7116
[i915#7118]: https://gitlab.freedesktop.org/drm/intel/issues/7118
[i915#72]: https://gitlab.freedesktop.org/drm/intel/issues/72
[i915#7456]: https://gitlab.freedesktop.org/drm/intel/issues/7456
[i915#7561]: https://gitlab.freedesktop.org/drm/intel/issues/7561
[i915#7582]: https://gitlab.freedesktop.org/drm/intel/issues/7582
[i915#7707]: https://gitlab.freedesktop.org/drm/intel/issues/7707
[i915#7711]: https://gitlab.freedesktop.org/drm/intel/issues/7711
[i915#7742]: https://gitlab.freedesktop.org/drm/intel/issues/7742
[i915#7828]: https://gitlab.freedesktop.org/drm/intel/issues/7828
[i915#79]: https://gitlab.freedesktop.org/drm/intel/issues/79
[i915#7949]: https://gitlab.freedesktop.org/drm/intel/issues/7949
[i915#7975]: https://gitlab.freedesktop.org/drm/intel/issues/7975
[i915#7984]: https://gitlab.freedesktop.org/drm/intel/issues/7984
Build changes
-------------
* Linux: CI_DRM_12693 -> Patchwork_113680v1
CI-20190529: 20190529
CI_DRM_12693: 3119889d6832bf30bbe7afd66fdf486f5b14e40f @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_7149: 1c7ea154b625e1fb826f1519b816b4256dd10b62 @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git
Patchwork_113680v1: 3119889d6832bf30bbe7afd66fdf486f5b14e40f @ git://anongit.freedesktop.org/gfx-ci/linux
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_113680v1/index.html
[-- Attachment #2: Type: text/html, Size: 13927 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] drm/i915/pxp: limit drm-errors or warning on firmware API failures
2023-02-04 5:48 ` [Intel-gfx] " Alan Previn
@ 2023-03-03 19:34 ` Ceraolo Spurio, Daniele
-1 siblings, 0 replies; 6+ messages in thread
From: Ceraolo Spurio, Daniele @ 2023-03-03 19:34 UTC (permalink / raw)
To: Alan Previn, intel-gfx; +Cc: Tvrtko Ursulin, dri-devel
On 2/3/2023 9:48 PM, Alan Previn wrote:
> MESA driver is creating protected context on every driver handle
> creation to query caps bits for app. So when running CI tests,
> they are observing hundreds of drm_errors when enabling PXP
> in .config but using SOC fusing or BIOS configuration that cannot
> support PXP sessions.
>
> The fixes tag referenced below was to resolve a related issue
> where we wanted to silence error messages, but that case was due
> to outdated IFWI (firmware) that definitely needed an upgrade and
> was, at that point, considered a one-off case as opposed to today's
> realization that default CI was enabling PXP in kernel config for
> all testing.
>
> So with this patch, let's strike a balance between issues that is
> critical but are root-caused from HW/platform gaps (louder drm-warn
> but just ONCE) vs other cases where it could also come from session
> state machine (which cannot be a WARN_ONCE since it can be triggered
> due to runtime operation events).
>
> Let's use helpers for these so as more functions are added in future
> features / HW (or as FW designers continue to bless upstreaming of
> the error codes and meanings), we only need to update the helpers.
>
> NOTE: Don't completely remove FW errors (via drm_debug) or else cusomer
> apps that really needs to know that content protection failed won't
> be aware of it.
>
> Fixes: b762787bf767 ("drm/i915/pxp: Use drm_dbg if arb session failed due to fw version")
> Signed-off-by: Alan Previn <alan.previn.teres.alexis@intel.com>
> ---
> .../i915/pxp/intel_pxp_cmd_interface_cmn.h | 3 +
> drivers/gpu/drm/i915/pxp/intel_pxp_session.c | 2 +-
> drivers/gpu/drm/i915/pxp/intel_pxp_tee.c | 73 +++++++++++++++----
> 3 files changed, 64 insertions(+), 14 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h b/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h
> index ae9b151b7cb7..6f6541d5e49a 100644
> --- a/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h
> +++ b/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h
> @@ -18,6 +18,9 @@
> enum pxp_status {
> PXP_STATUS_SUCCESS = 0x0,
> PXP_STATUS_ERROR_API_VERSION = 0x1002,
> + PXP_STATUS_NOT_READY = 0x100e,
> + PXP_STATUS_PLATFCONFIG_KF1_NOVERIF = 0x101a,
> + PXP_STATUS_PLATFCONFIG_KF1_BAD = 0x101f,
> PXP_STATUS_OP_NOT_PERMITTED = 0x4013
> };
>
> diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_session.c b/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
> index 448cacb0465d..7de849cb6c47 100644
> --- a/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
> +++ b/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
> @@ -74,7 +74,7 @@ static int pxp_create_arb_session(struct intel_pxp *pxp)
>
> ret = pxp_wait_for_session_state(pxp, ARB_SESSION, true);
> if (ret) {
> - drm_err(>->i915->drm, "arb session failed to go in play\n");
> + drm_dbg(>->i915->drm, "arb session failed to go in play\n");
> return ret;
> }
> drm_dbg(>->i915->drm, "PXP ARB session is alive\n");
> diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c b/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c
> index d9d248b48093..2d3bcff93da3 100644
> --- a/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c
> +++ b/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c
> @@ -19,6 +19,37 @@
> #include "intel_pxp_tee.h"
> #include "intel_pxp_types.h"
>
> +static bool
> +is_fw_err_platform_config(u32 type)
> +{
> + switch (type) {
> + case PXP_STATUS_ERROR_API_VERSION:
> + case PXP_STATUS_PLATFCONFIG_KF1_NOVERIF:
> + case PXP_STATUS_PLATFCONFIG_KF1_BAD:
> + return true;
> + default:
> + break;
> + }
> + return false;
> +}
> +
> +static const char *
> +fw_err_to_string(u32 type)
> +{
> + switch (type) {
> + case PXP_STATUS_ERROR_API_VERSION:
> + return "ERR_API_VERSION";
> + case PXP_STATUS_NOT_READY:
> + return "ERR_NOT_READY";
> + case PXP_STATUS_PLATFCONFIG_KF1_NOVERIF:
> + case PXP_STATUS_PLATFCONFIG_KF1_BAD:
> + return "ERR_PLATFORM_CONFIG";
> + default:
> + break;
> + }
> + return NULL;
> +}
> +
> static int intel_pxp_tee_io_message(struct intel_pxp *pxp,
> void *msg_in, u32 msg_in_size,
> void *msg_out, u32 msg_out_max_size,
> @@ -307,15 +338,21 @@ int intel_pxp_tee_cmd_create_arb_session(struct intel_pxp *pxp,
> &msg_out, sizeof(msg_out),
> NULL);
>
> - if (ret)
> - drm_err(&i915->drm, "Failed to send tee msg ret=[%d]\n", ret);
> - else if (msg_out.header.status == PXP_STATUS_ERROR_API_VERSION)
> - drm_dbg(&i915->drm, "PXP firmware version unsupported, requested: "
> - "CMD-ID-[0x%08x] on API-Ver-[0x%08x]\n",
> - msg_in.header.command_id, msg_in.header.api_version);
> - else if (msg_out.header.status != 0x0)
> - drm_warn(&i915->drm, "PXP firmware failed arb session init request ret=[0x%08x]\n",
> - msg_out.header.status);
> + if (ret) {
> + drm_err(&i915->drm, "Failed to send tee msg init arb session, ret=[%d]\n", ret);
> + } else if (msg_out.header.status != 0) {
> + if (is_fw_err_platform_config(msg_out.header.status))
> + drm_WARN_ONCE(&i915->drm, true,
> + "PXP init-arb-session-%d failed due to BIOS/SOC:0x%08x:%s\n",
> + (int)arb_session_id, msg_out.header.status,
> + fw_err_to_string(msg_out.header.status));
> + else
> + drm_dbg(&i915->drm, "PXP init-arb-session--%d failed 0x%08x:%st:\n"
I think we usually prefer to emit 2 separate drm_dbg instead of having a
newline in the middle
> + "CMD-ID-[0x%08x]:API-Ver-[0x%08x]\n",
> + (int)arb_session_id, msg_out.header.status,
Isn't arb_session_id already an int? why the need to cast it?
> + fw_err_to_string(msg_out.header.status),
> + msg_in.header.command_id, msg_in.header.api_version);
> + }
>
> return ret;
> }
> @@ -347,10 +384,20 @@ void intel_pxp_tee_end_arb_fw_session(struct intel_pxp *pxp, u32 session_id)
> if ((ret || msg_out.header.status != 0x0) && ++trials < 3)
> goto try_again;
>
> - if (ret)
> + if (ret) {
> drm_err(&i915->drm, "Failed to send tee msg for inv-stream-key-%d, ret=[%d]\n",
> session_id, ret);
> - else if (msg_out.header.status != 0x0)
> - drm_warn(&i915->drm, "PXP firmware failed inv-stream-key-%d with status 0x%08x\n",
> - session_id, msg_out.header.status);
> + } else if (msg_out.header.status != 0) {
> + if (is_fw_err_platform_config(msg_out.header.status))
> + drm_WARN_ONCE(&i915->drm, true,
> + "PXP inv-stream-key-%d failed due to BIOS/SOC :0x%08x:%s\n",
> + (int)session_id, msg_out.header.status,
This time this is a u32, so why not just use %u?
Patch LGTM apart from these nits.
Daniele
> + fw_err_to_string(msg_out.header.status));
> + else
> + drm_dbg(&i915->drm, "PXP inv-stream-key-%d failed 0x%08x:%s:\n"
> + "CMD-ID-[0x%08x]:API-Ver-[0x%08x]\n",
> + (int)session_id, msg_out.header.status,
> + fw_err_to_string(msg_out.header.status),
> + msg_in.header.command_id, msg_in.header.api_version);
> + }
> }
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Intel-gfx] [PATCH] drm/i915/pxp: limit drm-errors or warning on firmware API failures
@ 2023-03-03 19:34 ` Ceraolo Spurio, Daniele
0 siblings, 0 replies; 6+ messages in thread
From: Ceraolo Spurio, Daniele @ 2023-03-03 19:34 UTC (permalink / raw)
To: Alan Previn, intel-gfx; +Cc: dri-devel
On 2/3/2023 9:48 PM, Alan Previn wrote:
> MESA driver is creating protected context on every driver handle
> creation to query caps bits for app. So when running CI tests,
> they are observing hundreds of drm_errors when enabling PXP
> in .config but using SOC fusing or BIOS configuration that cannot
> support PXP sessions.
>
> The fixes tag referenced below was to resolve a related issue
> where we wanted to silence error messages, but that case was due
> to outdated IFWI (firmware) that definitely needed an upgrade and
> was, at that point, considered a one-off case as opposed to today's
> realization that default CI was enabling PXP in kernel config for
> all testing.
>
> So with this patch, let's strike a balance between issues that is
> critical but are root-caused from HW/platform gaps (louder drm-warn
> but just ONCE) vs other cases where it could also come from session
> state machine (which cannot be a WARN_ONCE since it can be triggered
> due to runtime operation events).
>
> Let's use helpers for these so as more functions are added in future
> features / HW (or as FW designers continue to bless upstreaming of
> the error codes and meanings), we only need to update the helpers.
>
> NOTE: Don't completely remove FW errors (via drm_debug) or else cusomer
> apps that really needs to know that content protection failed won't
> be aware of it.
>
> Fixes: b762787bf767 ("drm/i915/pxp: Use drm_dbg if arb session failed due to fw version")
> Signed-off-by: Alan Previn <alan.previn.teres.alexis@intel.com>
> ---
> .../i915/pxp/intel_pxp_cmd_interface_cmn.h | 3 +
> drivers/gpu/drm/i915/pxp/intel_pxp_session.c | 2 +-
> drivers/gpu/drm/i915/pxp/intel_pxp_tee.c | 73 +++++++++++++++----
> 3 files changed, 64 insertions(+), 14 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h b/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h
> index ae9b151b7cb7..6f6541d5e49a 100644
> --- a/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h
> +++ b/drivers/gpu/drm/i915/pxp/intel_pxp_cmd_interface_cmn.h
> @@ -18,6 +18,9 @@
> enum pxp_status {
> PXP_STATUS_SUCCESS = 0x0,
> PXP_STATUS_ERROR_API_VERSION = 0x1002,
> + PXP_STATUS_NOT_READY = 0x100e,
> + PXP_STATUS_PLATFCONFIG_KF1_NOVERIF = 0x101a,
> + PXP_STATUS_PLATFCONFIG_KF1_BAD = 0x101f,
> PXP_STATUS_OP_NOT_PERMITTED = 0x4013
> };
>
> diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_session.c b/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
> index 448cacb0465d..7de849cb6c47 100644
> --- a/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
> +++ b/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
> @@ -74,7 +74,7 @@ static int pxp_create_arb_session(struct intel_pxp *pxp)
>
> ret = pxp_wait_for_session_state(pxp, ARB_SESSION, true);
> if (ret) {
> - drm_err(>->i915->drm, "arb session failed to go in play\n");
> + drm_dbg(>->i915->drm, "arb session failed to go in play\n");
> return ret;
> }
> drm_dbg(>->i915->drm, "PXP ARB session is alive\n");
> diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c b/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c
> index d9d248b48093..2d3bcff93da3 100644
> --- a/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c
> +++ b/drivers/gpu/drm/i915/pxp/intel_pxp_tee.c
> @@ -19,6 +19,37 @@
> #include "intel_pxp_tee.h"
> #include "intel_pxp_types.h"
>
> +static bool
> +is_fw_err_platform_config(u32 type)
> +{
> + switch (type) {
> + case PXP_STATUS_ERROR_API_VERSION:
> + case PXP_STATUS_PLATFCONFIG_KF1_NOVERIF:
> + case PXP_STATUS_PLATFCONFIG_KF1_BAD:
> + return true;
> + default:
> + break;
> + }
> + return false;
> +}
> +
> +static const char *
> +fw_err_to_string(u32 type)
> +{
> + switch (type) {
> + case PXP_STATUS_ERROR_API_VERSION:
> + return "ERR_API_VERSION";
> + case PXP_STATUS_NOT_READY:
> + return "ERR_NOT_READY";
> + case PXP_STATUS_PLATFCONFIG_KF1_NOVERIF:
> + case PXP_STATUS_PLATFCONFIG_KF1_BAD:
> + return "ERR_PLATFORM_CONFIG";
> + default:
> + break;
> + }
> + return NULL;
> +}
> +
> static int intel_pxp_tee_io_message(struct intel_pxp *pxp,
> void *msg_in, u32 msg_in_size,
> void *msg_out, u32 msg_out_max_size,
> @@ -307,15 +338,21 @@ int intel_pxp_tee_cmd_create_arb_session(struct intel_pxp *pxp,
> &msg_out, sizeof(msg_out),
> NULL);
>
> - if (ret)
> - drm_err(&i915->drm, "Failed to send tee msg ret=[%d]\n", ret);
> - else if (msg_out.header.status == PXP_STATUS_ERROR_API_VERSION)
> - drm_dbg(&i915->drm, "PXP firmware version unsupported, requested: "
> - "CMD-ID-[0x%08x] on API-Ver-[0x%08x]\n",
> - msg_in.header.command_id, msg_in.header.api_version);
> - else if (msg_out.header.status != 0x0)
> - drm_warn(&i915->drm, "PXP firmware failed arb session init request ret=[0x%08x]\n",
> - msg_out.header.status);
> + if (ret) {
> + drm_err(&i915->drm, "Failed to send tee msg init arb session, ret=[%d]\n", ret);
> + } else if (msg_out.header.status != 0) {
> + if (is_fw_err_platform_config(msg_out.header.status))
> + drm_WARN_ONCE(&i915->drm, true,
> + "PXP init-arb-session-%d failed due to BIOS/SOC:0x%08x:%s\n",
> + (int)arb_session_id, msg_out.header.status,
> + fw_err_to_string(msg_out.header.status));
> + else
> + drm_dbg(&i915->drm, "PXP init-arb-session--%d failed 0x%08x:%st:\n"
I think we usually prefer to emit 2 separate drm_dbg instead of having a
newline in the middle
> + "CMD-ID-[0x%08x]:API-Ver-[0x%08x]\n",
> + (int)arb_session_id, msg_out.header.status,
Isn't arb_session_id already an int? why the need to cast it?
> + fw_err_to_string(msg_out.header.status),
> + msg_in.header.command_id, msg_in.header.api_version);
> + }
>
> return ret;
> }
> @@ -347,10 +384,20 @@ void intel_pxp_tee_end_arb_fw_session(struct intel_pxp *pxp, u32 session_id)
> if ((ret || msg_out.header.status != 0x0) && ++trials < 3)
> goto try_again;
>
> - if (ret)
> + if (ret) {
> drm_err(&i915->drm, "Failed to send tee msg for inv-stream-key-%d, ret=[%d]\n",
> session_id, ret);
> - else if (msg_out.header.status != 0x0)
> - drm_warn(&i915->drm, "PXP firmware failed inv-stream-key-%d with status 0x%08x\n",
> - session_id, msg_out.header.status);
> + } else if (msg_out.header.status != 0) {
> + if (is_fw_err_platform_config(msg_out.header.status))
> + drm_WARN_ONCE(&i915->drm, true,
> + "PXP inv-stream-key-%d failed due to BIOS/SOC :0x%08x:%s\n",
> + (int)session_id, msg_out.header.status,
This time this is a u32, so why not just use %u?
Patch LGTM apart from these nits.
Daniele
> + fw_err_to_string(msg_out.header.status));
> + else
> + drm_dbg(&i915->drm, "PXP inv-stream-key-%d failed 0x%08x:%s:\n"
> + "CMD-ID-[0x%08x]:API-Ver-[0x%08x]\n",
> + (int)session_id, msg_out.header.status,
> + fw_err_to_string(msg_out.header.status),
> + msg_in.header.command_id, msg_in.header.api_version);
> + }
> }
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2023-03-03 19:35 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-04 5:48 [PATCH] drm/i915/pxp: limit drm-errors or warning on firmware API failures Alan Previn
2023-02-04 5:48 ` [Intel-gfx] " Alan Previn
2023-02-04 17:22 ` [Intel-gfx] ✓ Fi.CI.BAT: success for " Patchwork
2023-02-05 17:12 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
2023-03-03 19:34 ` [PATCH] " Ceraolo Spurio, Daniele
2023-03-03 19:34 ` [Intel-gfx] " Ceraolo Spurio, Daniele
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.