Skip to contentSkip to conversation

drm/i915/guc: Sanitory checks for platform that dont have GuC

PATCH In review Anusha Srivatsa 4 participants 5 messages Oct 5, 2016 – Oct 7, 2016

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/i915/guc: Sanitory checks for platform that dont have GuC

i915.enable_guc_loading/submission=2 forces the usage of GuC. For platforms that do not have a GuC, asking the kernel to use a GuC should not result in an error state. Do extra checks to see if the platform even has a GuC or not, regardless of the kernel parameter.

---
 drivers/gpu/drm/i915/intel_guc_loader.c | 15 +++++++++------
 1 file changed, 9 insertions(+), 6 deletions(-)
drivers/gpu/drm/i915/intel_guc_loader.c +9 -6
index 7ace96b..15d2d53 100644
@@ -717,13 +717,16 @@ void intel_guc_init(struct drm_device *dev)
 	struct drm_i915_private *dev_priv = to_i915(dev);
 	struct intel_guc_fw *guc_fw = &dev_priv->guc.guc_fw;
 	const char *fw_path;
-
+	if (!HAS_GUC(dev)) {
+		i915.enable_guc_loading = 0;
+		i915.enable_guc_submission = 0;
+	} else {
 	/* A negative value means "use platform default" */
-	if (i915.enable_guc_loading < 0)
-		i915.enable_guc_loading = HAS_GUC_UCODE(dev);
-	if (i915.enable_guc_submission < 0)
-		i915.enable_guc_submission = HAS_GUC_SCHED(dev);
-
+		if (i915.enable_guc_loading < 0)
+			i915.enable_guc_loading = HAS_GUC_UCODE(dev);
+		if (i915.enable_guc_submission < 0)
+			i915.enable_guc_submission = HAS_GUC_SCHED(dev);
+	}
 	if (!HAS_GUC_UCODE(dev)) {
 		fw_path = NULL;
 	} else if (IS_SKYLAKE(dev)) {
Signature · 6 lines
2.7.4

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
#1 lore raw

✗ Fi.CI.BAT: failure for drm/i915/guc: Sanitory checks for platform that dont have GuC

== Series Details ==

== Series Details ==

Series: drm/i915/guc: Sanitory checks for platform that dont have GuC
URL : https://patchwork.freedesktop.org/series/13358/
State : failure

== Summary ==

Series 13358v1 drm/i915/guc: Sanitory checks for platform that dont have GuC
https://patchwork.freedesktop.org/api/1.0/series/13358/revisions/1/mbox/

Test gem_busy:

        Subgroup basic-hang-default:
                pass       -> FAIL       (fi-hsw-4770r)
Test kms_flip:
        Subgroup basic-flip-vs-modeset:
                pass       -> DMESG-WARN (fi-skl-6770hq)
Test kms_pipe_crc_basic:
        Subgroup suspend-read-crc-pipe-a:
                dmesg-warn -> PASS       (fi-byt-j1900)
        Subgroup suspend-read-crc-pipe-b:
                dmesg-warn -> PASS       (fi-byt-j1900)
fi-bdw-5557u     total:244  pass:229  dwarn:0   dfail:0   fail:0   skip:15 
fi-bsw-n3050     total:244  pass:202  dwarn:0   dfail:0   fail:0   skip:42 
fi-bxt-t5700     total:244  pass:214  dwarn:0   dfail:0   fail:0   skip:30 
fi-byt-j1900     total:244  pass:212  dwarn:0   dfail:0   fail:1   skip:31 
fi-byt-n2820     total:244  pass:208  dwarn:0   dfail:0   fail:1   skip:35 
fi-hsw-4770      total:244  pass:222  dwarn:0   dfail:0   fail:0   skip:22 
fi-hsw-4770r     total:244  pass:221  dwarn:0   dfail:0   fail:1   skip:22 
fi-ilk-650       total:244  pass:182  dwarn:0   dfail:0   fail:2   skip:60 
fi-ivb-3520m     total:244  pass:219  dwarn:0   dfail:0   fail:0   skip:25 
fi-ivb-3770      total:244  pass:207  dwarn:0   dfail:0   fail:0   skip:37 
fi-kbl-7200u     total:244  pass:220  dwarn:0   dfail:0   fail:0   skip:24 
fi-skl-6260u     total:244  pass:230  dwarn:0   dfail:0   fail:0   skip:14 
fi-skl-6700hq    total:244  pass:222  dwarn:0   dfail:0   fail:0   skip:22 
fi-skl-6700k     total:244  pass:219  dwarn:1   dfail:0   fail:0   skip:24 
fi-skl-6770hq    total:244  pass:227  dwarn:2   dfail:0   fail:1   skip:14 
fi-snb-2520m     total:244  pass:208  dwarn:0   dfail:0   fail:0   skip:36 
fi-snb-2600      total:244  pass:207  dwarn:0   dfail:0   fail:0   skip:37 

Results at /archive/results/CI_IGT_test/Patchwork_2634/

2dff18acaa95a26b882a5f9910d7ded514f18415 drm-intel-nightly: 2016y-10m-05d-13h-58m-08s UTC integration manifest 0484c38 drm/i915/guc: Sanitory checks for platform that dont have GuC

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

#2 lore raw
In reply to Anusha Srivatsa

Em Qua, 2016-10-05 às 16:50 -0700, Anusha Srivatsa escreveu:

Quoted 5 lines

i915.enable_guc_loading/submission=2 forces the usage of GuC. For platforms that do not have a GuC, asking the kernel to use a GuC should not result in an error state. Do extra checks to see if the platform even has a GuC or not, regardless of the kernel parameter.

I'm not exactly sure who did what here, but I think Rodrigo deserves some credit for his initial work (and possibly debug). Maybe add:

Quoted 1 line
Cc Zanoni Paulo <[email protected]>

I see the Cc tag here but no Cc mail header with my email on it, so this email wasn't colored blue on my intel-gfx folder. Why didn't I actually get Cc'd here? Did you use git-send-email? This may be worth investigating since it may happen again in the future, and you want to make sure people you Cc actually get Cc'd.

Quoted 11 lines

---
 drivers/gpu/drm/i915/intel_guc_loader.c | 15 +++++++++------

 1 file changed, 9 insertions(+), 6 deletions(-)
drivers/gpu/drm/i915/intel_guc_loader.c +0 -0
index 7ace96b..15d2d53 100644

drivers/gpu/drm/i915/intel_guc_loader.c void intel_guc_init(struct drm_device *dev) · line 720

Quoted 4 lines
drivers/gpu/drm/i915/intel_guc_loader.c +0 -1
@@ -717,13 +717,16 @@ void intel_guc_init(struct drm_device *dev)
  	struct drm_i915_private *dev_priv = to_i915(dev);
  	struct intel_guc_fw *guc_fw = &dev_priv->guc.guc_fw;
  	const char *fw_path;
-

Please do not remove the blank line above.

drivers/gpu/drm/i915/intel_guc_loader.c void intel_guc_init(struct drm_device *dev) · line 724

Quoted 5 lines
drivers/gpu/drm/i915/intel_guc_loader.c +4 -0
+	if (!HAS_GUC(dev)) {
+		i915.enable_guc_loading = 0;
+		i915.enable_guc_submission = 0;
+	} else {
  	/* A negative value means "use platform default" */

Bad indentation here.

drivers/gpu/drm/i915/intel_guc_loader.c void intel_guc_init(struct drm_device *dev) · line 726

Quoted 5 lines
drivers/gpu/drm/i915/intel_guc_loader.c +0 -5
-	if (i915.enable_guc_loading < 0)
-		i915.enable_guc_loading = HAS_GUC_UCODE(dev);
-	if (i915.enable_guc_submission < 0)
-		i915.enable_guc_submission = HAS_GUC_SCHED(dev);
-

Please also do not remove the blank line above.

Otherwise, looks good.

Quoted 10 lines
drivers/gpu/drm/i915/intel_guc_loader.c +5 -0
+		if (i915.enable_guc_loading < 0)
+			i915.enable_guc_loading =
 HAS_GUC_UCODE(dev);
+		if (i915.enable_guc_submission < 0)
+			i915.enable_guc_submission =
 HAS_GUC_SCHED(dev);
+	}
  	if (!HAS_GUC_UCODE(dev)) {

  fw_path = NULL;
  } else if (IS_SKYLAKE(dev)) {

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

maintainer
#3 lore raw
Quoted 10 lines · Paulo Zanoni

Em Qua, 2016-10-05 às 16:50 -0700, Anusha Srivatsa escreveu:

Quoted 5 lines

i915.enable_guc_loading/submission=2 forces the usage of GuC. For platforms that do not have a GuC, asking the kernel to use a GuC should not result in an error state. Do extra checks to see if the platform even has a GuC or not, regardless of the kernel parameter.

I'm not exactly sure who did what here, but I think Rodrigo deserves some credit for his initial work (and possibly debug). Maybe add:

I just drop a quickly patch that day, but she did the work, specially debugging it after.

Quoted 47 lines
Quoted 3 lines
Cc Zanoni Paulo <[email protected]>

I see the Cc tag here but no Cc mail header with my email on it, so this email wasn't colored blue on my intel-gfx folder. Why didn't I actually get Cc'd here? Did you use git-send-email? This may be worth investigating since it may happen again in the future, and you want to make sure people you Cc actually get Cc'd.

Quoted 11 lines
---
 drivers/gpu/drm/i915/intel_guc_loader.c | 15 +++++++++------
 1 file changed, 9 insertions(+), 6 deletions(-)
drivers/gpu/drm/i915/intel_guc_loader.c +0 -0
index 7ace96b..15d2d53 100644

drivers/gpu/drm/i915/intel_guc_loader.c void intel_guc_init(struct drm_device *dev) · line 720

Quoted 4 lines
drivers/gpu/drm/i915/intel_guc_loader.c +0 -1
@@ -717,13 +717,16 @@ void intel_guc_init(struct drm_device *dev)
 	struct drm_i915_private *dev_priv = to_i915(dev);
 	struct intel_guc_fw *guc_fw = &dev_priv->guc.guc_fw;
 	const char *fw_path;
-

Please do not remove the blank line above.

drivers/gpu/drm/i915/intel_guc_loader.c void intel_guc_init(struct drm_device *dev) · line 724

Quoted 5 lines
drivers/gpu/drm/i915/intel_guc_loader.c +4 -0
+	if (!HAS_GUC(dev)) {
+		i915.enable_guc_loading = 0;
+		i915.enable_guc_submission = 0;
+	} else {
 	/* A negative value means "use platform default" */

Bad indentation here.

drivers/gpu/drm/i915/intel_guc_loader.c void intel_guc_init(struct drm_device *dev) · line 726

Quoted 5 lines
drivers/gpu/drm/i915/intel_guc_loader.c +0 -5
-	if (i915.enable_guc_loading < 0)
-		i915.enable_guc_loading = HAS_GUC_UCODE(dev);
-	if (i915.enable_guc_submission < 0)
-		i915.enable_guc_submission = HAS_GUC_SCHED(dev);
-

Please also do not remove the blank line above.

Otherwise, looks good.

Quoted 10 lines

drivers/gpu/drm/i915/intel_guc_loader.c void intel_guc_init(struct drm_device *dev) · line 732

Quoted 10 lines
drivers/gpu/drm/i915/intel_guc_loader.c +5 -0
+		if (i915.enable_guc_loading < 0)
+			i915.enable_guc_loading =
 HAS_GUC_UCODE(dev);
+		if (i915.enable_guc_submission < 0)
+			i915.enable_guc_submission =
 HAS_GUC_SCHED(dev);
+	}
 	if (!HAS_GUC_UCODE(dev)) {
drivers/gpu/drm/i915/intel_guc_loader.c +0 -0
 		fw_path = NULL;
 	} else if (IS_SKYLAKE(dev)) {

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

#4 lore raw
Quoted 18 lines

-----Original Message-----
From: Vivi, Rodrigo
Sent: Friday, October 7, 2016 7:06 AM
To: Zanoni, Paulo R <[email protected]>
Cc: [email protected]; Srivatsa, Anusha <[email protected]>
Subject: Re: [Intel-gfx] [PATCH] drm/i915/guc: Sanitory checks for platform that dont have GuC

Quoted 6 lines · Paulo Zanoni

Em Qua, 2016-10-05 às 16:50 -0700, Anusha Srivatsa escreveu:

Quoted 4 lines

i915.enable_guc_loading/submission=2 forces the usage of GuC. For platforms that do not have a GuC, asking the kernel to use a GuC should not result in an error state. Do extra checks to see if the platform even has a GuC or not, regardless of the kernel parameter.

Quoted 6 lines
Quoted 3 lines

I'm not exactly sure who did what here, but I think Rodrigo deserves some credit for his initial work (and possibly debug). Maybe add:

I just drop a quickly patch that day, but she did the work, specially debugging it after.

I agree with you Paulo. In fact I was thinking of an exact way of giving credit to both you and Rodrigo since the patch is inspired by his patch and I have taken your suggestion as well. Will update the patch with "Based-on".

Quoted 9 lines
Quoted 9 lines
Quoted 3 lines
Cc Zanoni Paulo <[email protected]>

I see the Cc tag here but no Cc mail header with my email on it, so this email wasn't colored blue on my intel-gfx folder. Why didn't I actually get Cc'd here? Did you use git-send-email? This may be worth investigating since it may happen again in the future, and you want to make sure people you Cc actually get Cc'd.

I used git send-email. Will investigate it.

Quoted 35 lines
Quoted 35 lines
Quoted 12 lines
---
 drivers/gpu/drm/i915/intel_guc_loader.c | 15 +++++++++------
 1 file changed, 9 insertions(+), 6 deletions(-)
drivers/gpu/drm/i915/intel_guc_loader.c +0 -0
index 7ace96b..15d2d53 100644

drivers/gpu/drm/i915/intel_guc_loader.c void intel_guc_init(struct drm_device *dev) · line 720

Quoted 4 lines
drivers/gpu/drm/i915/intel_guc_loader.c +0 -1
@@ -717,13 +717,16 @@ void intel_guc_init(struct drm_device *dev)
 	struct drm_i915_private *dev_priv = to_i915(dev);
 	struct intel_guc_fw *guc_fw = &dev_priv->guc.guc_fw;
 	const char *fw_path;
-

Please do not remove the blank line above.

drivers/gpu/drm/i915/intel_guc_loader.c void intel_guc_init(struct drm_device *dev) · line 724

Quoted 5 lines
drivers/gpu/drm/i915/intel_guc_loader.c +4 -0
+	if (!HAS_GUC(dev)) {
+		i915.enable_guc_loading = 0;
+		i915.enable_guc_submission = 0;
+	} else {
 	/* A negative value means "use platform default" */

Bad indentation here.

drivers/gpu/drm/i915/intel_guc_loader.c void intel_guc_init(struct drm_device *dev) · line 726

Quoted 5 lines
drivers/gpu/drm/i915/intel_guc_loader.c +0 -5
-	if (i915.enable_guc_loading < 0)
-		i915.enable_guc_loading = HAS_GUC_UCODE(dev);
-	if (i915.enable_guc_submission < 0)
-		i915.enable_guc_submission = HAS_GUC_SCHED(dev);
-

Please also do not remove the blank line above.

Quoted 1 line
Quoted 1 line

Otherwise, looks good.

Will fix indentation issue. Thank you.

Quoted 10 lines
Quoted 10 lines

drivers/gpu/drm/i915/intel_guc_loader.c void intel_guc_init(struct drm_device *dev) · line 732

Quoted 10 lines
drivers/gpu/drm/i915/intel_guc_loader.c +5 -0
+		if (i915.enable_guc_loading < 0)
+			i915.enable_guc_loading =
 HAS_GUC_UCODE(dev);
+		if (i915.enable_guc_submission < 0)
+			i915.enable_guc_submission =
 HAS_GUC_SCHED(dev);
+	}
 	if (!HAS_GUC_UCODE(dev)) {
drivers/gpu/drm/i915/intel_guc_loader.c +0 -0
 		fw_path = NULL;
 	} else if (IS_SKYLAKE(dev)) {

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx