Re: [Intel-gfx] [PATCH] drm/i915/huc: Stop printing about unsupported HuC on MTL

2023-11-13 Thread John Harrison

On 11/13/2023 07:36, Daniele Ceraolo Spurio wrote:

On 11/9/2023 6:06 PM, John Harrison wrote:

On 11/9/2023 15:54, Daniele Ceraolo Spurio wrote:

On MTL, the HuC is only supported on the media GT, so our validation
check on the module parameter detects an inconsistency on the root GT
(the modparams asks to enable HuC, but the support is not there) and
prints the following info message:

[drm] GT0: Incompatible option enable_guc=3 - HuC is not supported!

This can be confusing to the user and make them think that something is
wrong when it isn't, so we need to silence it.
Given that any platform that supports HuC also supports GuC, if a user
tries to enable HuC on a platform that really doesn't support it 
they'll

already see a message about GuC not being supported, so instead of just
silencing the HuC message on newer platforms we can just get rid of it
entirely.
Not following this argument. Someone might attempt to enable HuC only 
and do so on a older platform that supports neither HuC nor GuC. 
There would be no GuC warning because GuC was not requested. But now 
there would also be no HuC warning either.




Enabling HuC also enabled GuC loading, because the latter is needed to 
auth the former. The message about GuC not being supported is printed 
for all values of enable_guc that are not zero.


Daniele

This would indeed appear to be the case. So...

Reviewed-by: John Harrison 




John.



Signed-off-by: Daniele Ceraolo Spurio 
Cc: John Harrison 
---
  drivers/gpu/drm/i915/gt/uc/intel_uc.c | 5 -
  1 file changed, 5 deletions(-)

diff --git a/drivers/gpu/drm/i915/gt/uc/intel_uc.c 
b/drivers/gpu/drm/i915/gt/uc/intel_uc.c

index 27f6561dd731..3872d309ed31 100644
--- a/drivers/gpu/drm/i915/gt/uc/intel_uc.c
+++ b/drivers/gpu/drm/i915/gt/uc/intel_uc.c
@@ -106,11 +106,6 @@ static void __confirm_options(struct intel_uc *uc)
  gt_info(gt,  "Incompatible option enable_guc=%d - %s\n",
  i915->params.enable_guc, "GuC is not supported!");
  -    if (i915->params.enable_guc & ENABLE_GUC_LOAD_HUC &&
-    !intel_uc_supports_huc(uc))
-    gt_info(gt, "Incompatible option enable_guc=%d - %s\n",
-    i915->params.enable_guc, "HuC is not supported!");
-
  if (i915->params.enable_guc & ENABLE_GUC_SUBMISSION &&
  !intel_uc_supports_guc_submission(uc))
  gt_info(gt, "Incompatible option enable_guc=%d - %s\n",








Re: [Intel-gfx] [PATCH] drm/i915/huc: Stop printing about unsupported HuC on MTL

2023-11-13 Thread Daniele Ceraolo Spurio




On 11/9/2023 6:06 PM, John Harrison wrote:

On 11/9/2023 15:54, Daniele Ceraolo Spurio wrote:

On MTL, the HuC is only supported on the media GT, so our validation
check on the module parameter detects an inconsistency on the root GT
(the modparams asks to enable HuC, but the support is not there) and
prints the following info message:

[drm] GT0: Incompatible option enable_guc=3 - HuC is not supported!

This can be confusing to the user and make them think that something is
wrong when it isn't, so we need to silence it.
Given that any platform that supports HuC also supports GuC, if a user
tries to enable HuC on a platform that really doesn't support it they'll
already see a message about GuC not being supported, so instead of just
silencing the HuC message on newer platforms we can just get rid of it
entirely.
Not following this argument. Someone might attempt to enable HuC only 
and do so on a older platform that supports neither HuC nor GuC. There 
would be no GuC warning because GuC was not requested. But now there 
would also be no HuC warning either.




Enabling HuC also enabled GuC loading, because the latter is needed to 
auth the former. The message about GuC not being supported is printed 
for all values of enable_guc that are not zero.


Daniele


John.



Signed-off-by: Daniele Ceraolo Spurio 
Cc: John Harrison 
---
  drivers/gpu/drm/i915/gt/uc/intel_uc.c | 5 -
  1 file changed, 5 deletions(-)

diff --git a/drivers/gpu/drm/i915/gt/uc/intel_uc.c 
b/drivers/gpu/drm/i915/gt/uc/intel_uc.c

index 27f6561dd731..3872d309ed31 100644
--- a/drivers/gpu/drm/i915/gt/uc/intel_uc.c
+++ b/drivers/gpu/drm/i915/gt/uc/intel_uc.c
@@ -106,11 +106,6 @@ static void __confirm_options(struct intel_uc *uc)
  gt_info(gt,  "Incompatible option enable_guc=%d - %s\n",
  i915->params.enable_guc, "GuC is not supported!");
  -    if (i915->params.enable_guc & ENABLE_GUC_LOAD_HUC &&
-    !intel_uc_supports_huc(uc))
-    gt_info(gt, "Incompatible option enable_guc=%d - %s\n",
-    i915->params.enable_guc, "HuC is not supported!");
-
  if (i915->params.enable_guc & ENABLE_GUC_SUBMISSION &&
  !intel_uc_supports_guc_submission(uc))
  gt_info(gt, "Incompatible option enable_guc=%d - %s\n",






Re: [Intel-gfx] [PATCH] drm/i915/huc: Stop printing about unsupported HuC on MTL

2023-11-09 Thread John Harrison

On 11/9/2023 15:54, Daniele Ceraolo Spurio wrote:

On MTL, the HuC is only supported on the media GT, so our validation
check on the module parameter detects an inconsistency on the root GT
(the modparams asks to enable HuC, but the support is not there) and
prints the following info message:

[drm] GT0: Incompatible option enable_guc=3 - HuC is not supported!

This can be confusing to the user and make them think that something is
wrong when it isn't, so we need to silence it.
Given that any platform that supports HuC also supports GuC, if a user
tries to enable HuC on a platform that really doesn't support it they'll
already see a message about GuC not being supported, so instead of just
silencing the HuC message on newer platforms we can just get rid of it
entirely.
Not following this argument. Someone might attempt to enable HuC only 
and do so on a older platform that supports neither HuC nor GuC. There 
would be no GuC warning because GuC was not requested. But now there 
would also be no HuC warning either.


John.



Signed-off-by: Daniele Ceraolo Spurio 
Cc: John Harrison 
---
  drivers/gpu/drm/i915/gt/uc/intel_uc.c | 5 -
  1 file changed, 5 deletions(-)

diff --git a/drivers/gpu/drm/i915/gt/uc/intel_uc.c 
b/drivers/gpu/drm/i915/gt/uc/intel_uc.c
index 27f6561dd731..3872d309ed31 100644
--- a/drivers/gpu/drm/i915/gt/uc/intel_uc.c
+++ b/drivers/gpu/drm/i915/gt/uc/intel_uc.c
@@ -106,11 +106,6 @@ static void __confirm_options(struct intel_uc *uc)
gt_info(gt,  "Incompatible option enable_guc=%d - %s\n",
i915->params.enable_guc, "GuC is not supported!");
  
-	if (i915->params.enable_guc & ENABLE_GUC_LOAD_HUC &&

-   !intel_uc_supports_huc(uc))
-   gt_info(gt, "Incompatible option enable_guc=%d - %s\n",
-   i915->params.enable_guc, "HuC is not supported!");
-
if (i915->params.enable_guc & ENABLE_GUC_SUBMISSION &&
!intel_uc_supports_guc_submission(uc))
gt_info(gt, "Incompatible option enable_guc=%d - %s\n",




[Intel-gfx] [PATCH] drm/i915/huc: Stop printing about unsupported HuC on MTL

2023-11-09 Thread Daniele Ceraolo Spurio
On MTL, the HuC is only supported on the media GT, so our validation
check on the module parameter detects an inconsistency on the root GT
(the modparams asks to enable HuC, but the support is not there) and
prints the following info message:

[drm] GT0: Incompatible option enable_guc=3 - HuC is not supported!

This can be confusing to the user and make them think that something is
wrong when it isn't, so we need to silence it.
Given that any platform that supports HuC also supports GuC, if a user
tries to enable HuC on a platform that really doesn't support it they'll
already see a message about GuC not being supported, so instead of just
silencing the HuC message on newer platforms we can just get rid of it
entirely.

Signed-off-by: Daniele Ceraolo Spurio 
Cc: John Harrison 
---
 drivers/gpu/drm/i915/gt/uc/intel_uc.c | 5 -
 1 file changed, 5 deletions(-)

diff --git a/drivers/gpu/drm/i915/gt/uc/intel_uc.c 
b/drivers/gpu/drm/i915/gt/uc/intel_uc.c
index 27f6561dd731..3872d309ed31 100644
--- a/drivers/gpu/drm/i915/gt/uc/intel_uc.c
+++ b/drivers/gpu/drm/i915/gt/uc/intel_uc.c
@@ -106,11 +106,6 @@ static void __confirm_options(struct intel_uc *uc)
gt_info(gt,  "Incompatible option enable_guc=%d - %s\n",
i915->params.enable_guc, "GuC is not supported!");
 
-   if (i915->params.enable_guc & ENABLE_GUC_LOAD_HUC &&
-   !intel_uc_supports_huc(uc))
-   gt_info(gt, "Incompatible option enable_guc=%d - %s\n",
-   i915->params.enable_guc, "HuC is not supported!");
-
if (i915->params.enable_guc & ENABLE_GUC_SUBMISSION &&
!intel_uc_supports_guc_submission(uc))
gt_info(gt, "Incompatible option enable_guc=%d - %s\n",
-- 
2.41.0