Skip to contentSkip to conversation

drm/i915/dg2: enable G8 with a workaround

PATCH In review Raag Jadav 7 participants 14 messages Oct 7, 2024 – Oct 15, 2024

Subsystems (2)
lore
Share & tools
lore

Raag Jadav

author
#0 lore raw

PATCH 1/1 drm/i915/dg2: enable G8 with a workaround

Host BIOS doesn't enable G8 power mode due to an issue on DG2, so we enable it from kernel with Wa_14022698589. Currently it is enabled for all DG2 devices with the exception of a few, for which, it is enabled only when paired with whitelisted CPU models.

---
 drivers/gpu/drm/i915/gt/intel_workarounds.c | 43 +++++++++++++++++++++
 drivers/gpu/drm/i915/i915_reg.h             |  1 +
 2 files changed, 44 insertions(+)
drivers/gpu/drm/i915/gt/intel_workarounds.c +43 -0
index e539a656cfc3..b2db51377488 100644
@@ -14,11 +14,30 @@
 #include "intel_gt_mcr.h"
 #include "intel_gt_print.h"
 #include "intel_gt_regs.h"
+#include "intel_pcode.h"
 #include "intel_ring.h"
 #include "intel_workarounds.h"
 
 #include "display/intel_fbc_regs.h"
 
+#ifdef CONFIG_X86
+#include <asm/cpu_device_id.h>
+#include <asm/intel-family.h>
+
+static const struct x86_cpu_id g8_cpu_ids[] = {
+	X86_MATCH_VFM(INTEL_ALDERLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_ALDERLAKE_L,	NULL),
+	X86_MATCH_VFM(INTEL_COMETLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_KABYLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_KABYLAKE_L,		NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE_P,	NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE_S,	NULL),
+	X86_MATCH_VFM(INTEL_ROCKETLAKE,		NULL),
+	{}
+};
+#endif
+
 /**
  * DOC: Hardware workarounds
  *
@@ -1770,9 +1789,33 @@ static void wa_list_apply(const struct i915_wa_list *wal)
 	intel_gt_mcr_unlock(gt, flags);
 }
 
+#define DG2_G8_WA_RANGE_1		0x56A0 ... 0x56AF
+#define DG2_G8_WA_RANGE_2		0x56B0 ... 0x56B9
+
+/* Wa_14022698589:dg2 */
+static void intel_enable_g8(struct intel_uncore *uncore)
+{
+	if (IS_DG2(uncore->i915)) {
+		switch (INTEL_DEVID(uncore->i915)) {
+		case DG2_G8_WA_RANGE_1:
+		case DG2_G8_WA_RANGE_2:
+#ifdef CONFIG_X86
+			if (!x86_match_cpu(g8_cpu_ids))
+#endif
+				return;
+		}
+
+		snb_pcode_write_p(uncore, PCODE_POWER_SETUP,
+				  POWER_SETUP_SUBCOMMAND_G8_ENABLE, 0, 0);
+	}
+}
+
 void intel_gt_apply_workarounds(struct intel_gt *gt)
 {
 	wa_list_apply(&gt->wa_list);
+
+	/* Special case for pcode mailbox which can't be on wa_list */
+	intel_enable_g8(gt->uncore);
 }
 
 static bool wa_list_verify(struct intel_gt *gt,
drivers/gpu/drm/i915/i915_reg.h +1 -0
index 41f4350a7c6c..e948b194550c 100644
@@ -3568,6 +3568,7 @@
 #define   PCODE_POWER_SETUP			0x7C
 #define     POWER_SETUP_SUBCOMMAND_READ_I1	0x4
 #define     POWER_SETUP_SUBCOMMAND_WRITE_I1	0x5
+#define     POWER_SETUP_SUBCOMMAND_G8_ENABLE	0x6
 #define	    POWER_SETUP_I1_WATTS		REG_BIT(31)
 #define	    POWER_SETUP_I1_SHIFT		6	/* 10.6 fixed point format */
 #define	    POWER_SETUP_I1_DATA_MASK		REG_GENMASK(15, 0)
Signature · 1 line
2.34.1
#1 lore raw
Quoted 47 lines · Raag Jadav

Host BIOS doesn't enable G8 power mode due to an issue on DG2, so we enable it from kernel with Wa_14022698589. Currently it is enabled for all DG2 devices with the exception of a few, for which, it is enabled only when paired with whitelisted CPU models.

---
  drivers/gpu/drm/i915/gt/intel_workarounds.c | 43 +++++++++++++++++++++
  drivers/gpu/drm/i915/i915_reg.h             |  1 +
  2 files changed, 44 insertions(+)
drivers/gpu/drm/i915/gt/intel_workarounds.c +19 -0
index e539a656cfc3..b2db51377488 100644
@@ -14,11 +14,30 @@
  #include "intel_gt_mcr.h"
  #include "intel_gt_print.h"
  #include "intel_gt_regs.h"
+#include "intel_pcode.h"
  #include "intel_ring.h"
  #include "intel_workarounds.h"
 
  #include "display/intel_fbc_regs.h"
 
+#ifdef CONFIG_X86
+#include <asm/cpu_device_id.h>
+#include <asm/intel-family.h>
+
+static const struct x86_cpu_id g8_cpu_ids[] = {
+	X86_MATCH_VFM(INTEL_ALDERLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_ALDERLAKE_L,	NULL),
+	X86_MATCH_VFM(INTEL_COMETLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_KABYLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_KABYLAKE_L,		NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE_P,	NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE_S,	NULL),
+	X86_MATCH_VFM(INTEL_ROCKETLAKE,		NULL),
+	{}
+};
+#endif
+
  /**
   * DOC: Hardware workarounds
   *

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct i915_wa_list *wal) · line 1795

Quoted 7 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +4 -0
@@ -1770,9 +1789,33 @@ static void wa_list_apply(const struct i915_wa_list *wal)
  	intel_gt_mcr_unlock(gt, flags);
  }
 
+#define DG2_G8_WA_RANGE_1		0x56A0 ... 0x56AF
+#define DG2_G8_WA_RANGE_2		0x56B0 ... 0x56B9
+
+/* Wa_14022698589:dg2 */

As per bspecs correct Wa id for this Wa is 14022698537.

Regards,
Badal

Quoted 38 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +20 -0
+static void intel_enable_g8(struct intel_uncore *uncore)
+{
+	if (IS_DG2(uncore->i915)) {
+		switch (INTEL_DEVID(uncore->i915)) {
+		case DG2_G8_WA_RANGE_1:
+		case DG2_G8_WA_RANGE_2:
+#ifdef CONFIG_X86
+			if (!x86_match_cpu(g8_cpu_ids))
+#endif
+				return;
+		}
+
+		snb_pcode_write_p(uncore, PCODE_POWER_SETUP,
+				  POWER_SETUP_SUBCOMMAND_G8_ENABLE, 0, 0);
+	}
+}
+
  void intel_gt_apply_workarounds(struct intel_gt *gt)
  {
  	wa_list_apply(&gt->wa_list);
+
+	/* Special case for pcode mailbox which can't be on wa_list */
+	intel_enable_g8(gt->uncore);
  }
 
  static bool wa_list_verify(struct intel_gt *gt,
drivers/gpu/drm/i915/i915_reg.h +1 -0
index 41f4350a7c6c..e948b194550c 100644
@@ -3568,6 +3568,7 @@
  #define   PCODE_POWER_SETUP			0x7C
  #define     POWER_SETUP_SUBCOMMAND_READ_I1	0x4
  #define     POWER_SETUP_SUBCOMMAND_WRITE_I1	0x5
+#define     POWER_SETUP_SUBCOMMAND_G8_ENABLE	0x6
  #define	    POWER_SETUP_I1_WATTS		REG_BIT(31)
  #define	    POWER_SETUP_I1_SHIFT		6	/* 10.6 fixed point format */
  #define	    POWER_SETUP_I1_DATA_MASK		REG_GENMASK(15, 0)
#2 lore raw
Quoted 3 lines · Badal

On 07-10-2024 17:54, Raag Jadav wrote:

Usually Wa_ID is included in commit message title for simplified searching.

~/workspace/drmtip/drm-tip$ git log --oneline | grep "Wa_" da9a73b7b25e drm/xe/xe2hpg: Add Wa_15016589081
9db969b36b2f drm/xe/xe2hpg: Add Wa_15016589081
54f90b033359 drm/i915/guc: Fix missing enable of Wa_14019159160 on ARL 8776b0234e1d drm/xe/xe2hpg: Add Wa_14021821874
cbc6e98ab11b drm/xe/xe2: Add Wa_15015404425
03a2dc84f5c4 drm/xe/xe2lpm: Extend Wa_16021639441 27cb2b7fec2a drm/xe/bmg: implement Wa_16023588340 1d734a3e5d6b drm/xe: Name and document Wa_14019789679 21ff3a16e92e drm/xe/xe2hpg: Add Wa_14021821874
843f10ce6539 drm/i915/gt: Add Wa_14019789679
104bcfae57d8 drm/i915/arl: Enable Wa_14019159160 for ARL 86c5b70a9c0c drm/xe/xe2: Add Wa_15015404425
74e307680006 drm/xe/xe2lpm: Extend Wa_16021639441 c55f79f317ab drm/i915: disable fbc due to Wa_16023588340 01570b446939 drm/xe/bmg: implement Wa_16023588340 aaa08078e725 drm/xe/bmg: Apply Wa_22019338487
3b1592fb7835 drm/xe/lnl: Apply Wa_22019338487
d35386b3a77b drm/xe/xelpgp: Extend Wa_14019877138 to graphics 12.74 62712be3a4e0 drm/xe/xe2: Add proper check for media in Wa_14020756599 5d7612ae201e drm/xe/xe2lpg: Add Wa_14021490052
24d0d98af1c3 drm/xe/xe2lpm: Fixup Wa_14020756599 131328aa5699 drm/xe/xe2lpm: Add permanent Wa_14020756599

Badal

Quoted 96 lines
Quoted 45 lines

Host BIOS doesn't enable G8 power mode due to an issue on DG2, so we enable it from kernel with Wa_14022698589. Currently it is enabled for all DG2 devices with the exception of a few, for which, it is enabled only when paired with whitelisted CPU models.

---
  drivers/gpu/drm/i915/gt/intel_workarounds.c | 43 +++++++++++++++++++++ drivers/gpu/drm/i915/i915_reg.h             |  1 +

  2 files changed, 44 insertions(+)
drivers/gpu/drm/i915/gt/intel_workarounds.c +19 -0
index e539a656cfc3..b2db51377488 100644
@@ -14,11 +14,30 @@
   #include "intel_gt_mcr.h"
   #include "intel_gt_print.h"
   #include "intel_gt_regs.h"
+#include "intel_pcode.h"
   #include "intel_ring.h"
   #include "intel_workarounds.h"
   #include "display/intel_fbc_regs.h"
+#ifdef CONFIG_X86
+#include <asm/cpu_device_id.h>
+#include <asm/intel-family.h>
+
+static const struct x86_cpu_id g8_cpu_ids[] = {
+    X86_MATCH_VFM(INTEL_ALDERLAKE,        NULL),
+    X86_MATCH_VFM(INTEL_ALDERLAKE_L,    NULL),
+    X86_MATCH_VFM(INTEL_COMETLAKE,        NULL),
+    X86_MATCH_VFM(INTEL_KABYLAKE,        NULL),
+    X86_MATCH_VFM(INTEL_KABYLAKE_L,        NULL),
+    X86_MATCH_VFM(INTEL_RAPTORLAKE,        NULL),
+    X86_MATCH_VFM(INTEL_RAPTORLAKE_P,    NULL),
+    X86_MATCH_VFM(INTEL_RAPTORLAKE_S,    NULL),
+    X86_MATCH_VFM(INTEL_ROCKETLAKE,        NULL),
+    {}
+};
+#endif
+
   /**
    * DOC: Hardware workarounds
    *

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct · line 1795

Quoted 7 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +4 -0
@@ -1770,9 +1789,33 @@ static void wa_list_apply(const struct 
 i915_wa_list *wal)
       intel_gt_mcr_unlock(gt, flags);
   }
+#define DG2_G8_WA_RANGE_1        0x56A0 ... 0x56AF
+#define DG2_G8_WA_RANGE_2        0x56B0 ... 0x56B9
+
+/* Wa_14022698589:dg2 */

As per bspecs correct Wa id for this Wa is 14022698537.

Regards,
Badal

Quoted 37 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +20 -0
+static void intel_enable_g8(struct intel_uncore *uncore)
+{
+    if (IS_DG2(uncore->i915)) {
+        switch (INTEL_DEVID(uncore->i915)) {
+        case DG2_G8_WA_RANGE_1:
+        case DG2_G8_WA_RANGE_2:
+#ifdef CONFIG_X86
+            if (!x86_match_cpu(g8_cpu_ids))
+#endif
+                return;
+        }
+
+        snb_pcode_write_p(uncore, PCODE_POWER_SETUP,
+                  POWER_SETUP_SUBCOMMAND_G8_ENABLE, 0, 0);
+    }
+}
+
   void intel_gt_apply_workarounds(struct intel_gt *gt)
   {
       wa_list_apply(&gt->wa_list);
+
+    /* Special case for pcode mailbox which can't be on wa_list */
+    intel_enable_g8(gt->uncore);
   }
   static bool wa_list_verify(struct intel_gt *gt,
drivers/gpu/drm/i915/i915_reg.h +1 -0
index 41f4350a7c6c..e948b194550c 100644
@@ -3568,6 +3568,7 @@
   #define   PCODE_POWER_SETUP            0x7C
   #define     POWER_SETUP_SUBCOMMAND_READ_I1    0x4
   #define     POWER_SETUP_SUBCOMMAND_WRITE_I1    0x5
+#define     POWER_SETUP_SUBCOMMAND_G8_ENABLE    0x6
   #define        POWER_SETUP_I1_WATTS        REG_BIT(31)
   #define        POWER_SETUP_I1_SHIFT        6    /* 10.6 fixed point format */
   #define        POWER_SETUP_I1_DATA_MASK        REG_GENMASK(15, 0)
#3 lore raw

✗ Fi.CI.CHECKPATCH: warning for drm/i915/dg2: enable G8 with a workaround

In reply to Raag Jadav
== Series Details ==

== Series Details ==

Series: drm/i915/dg2: enable G8 with a workaround
URL : https://patchwork.freedesktop.org/series/139628/
State : warning

== Summary ==

Error: dim checkpatch failed
3502ee93c20a drm/i915/dg2: enable G8 with a workaround
-:52: ERROR:COMPLEX_MACRO: Macros with complex values should be enclosed in parentheses #52: FILE: drivers/gpu/drm/i915/gt/intel_workarounds.c:1792:
+#define DG2_G8_WA_RANGE_1 0x56A0 ... 0x56AF

-:53: ERROR:COMPLEX_MACRO: Macros with complex values should be enclosed in parentheses #53: FILE: drivers/gpu/drm/i915/gt/intel_workarounds.c:1793:
+#define DG2_G8_WA_RANGE_2 0x56B0 ... 0x56B9

total: 2 errors, 0 warnings, 0 checks, 70 lines checked

#4 lore raw

✗ Fi.CI.BAT: failure for drm/i915/dg2: enable G8 with a workaround

In reply to Raag Jadav
== Series Details ==

== Series Details ==

Series: drm/i915/dg2: enable G8 with a workaround
URL : https://patchwork.freedesktop.org/series/139628/
State : failure

== Summary ==

CI Bug Log - changes from CI_DRM_15489 -> Patchwork_139628v1
====================================================

Summary
-------

**FAILURE**

Serious unknown changes coming with Patchwork_139628v1 absolutely need to be verified manually.

If you think the reported changes have nothing to do with the changes
introduced in Patchwork_139628v1, please notify your bug team ([email protected]) to allow them to document this new failure mode, which will reduce false positives in CI.

External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/index.html

Participating hosts (43 -> 42)
------------------------------

Missing (1): bat-arls-1

Possible new issues
-------------------

Here are the unknown changes that may have been introduced in Patchwork_139628v1:

### IGT changes ###

#### Possible regressions ####

* igt@gem_render_linear_blits@basic:
- fi-glk-j4005: [PASS][1] -> [DMESG-FAIL][2] +2 other tests dmesg-fail
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-glk-j4005/igt@[email protected]
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-glk-j4005/igt@[email protected]
- fi-kbl-7567u: [PASS][3] -> [DMESG-FAIL][4] +2 other tests dmesg-fail
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-kbl-7567u/igt@[email protected]
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-kbl-7567u/igt@[email protected]
- bat-apl-1: [PASS][5] -> [DMESG-FAIL][6] +1 other test dmesg-fail
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-apl-1/igt@[email protected]
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-apl-1/igt@[email protected]
- fi-kbl-x1275: [PASS][7] -> [DMESG-FAIL][8] +1 other test dmesg-fail
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-kbl-x1275/igt@[email protected]
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-kbl-x1275/igt@[email protected]

* igt@gem_render_tiled_blits@basic:
- bat-kbl-2: [PASS][9] -> [DMESG-FAIL][10] +1 other test dmesg-fail
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-kbl-2/igt@[email protected]
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-kbl-2/igt@[email protected]
- fi-kbl-guc: [PASS][11] -> [DMESG-FAIL][12] +1 other test dmesg-fail
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-kbl-guc/igt@[email protected]
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-kbl-guc/igt@[email protected]

* igt@i915_hangman@error-state-basic:
- bat-apl-1: [PASS][13] -> [DMESG-WARN][14]
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-apl-1/igt@[email protected]
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-apl-1/igt@[email protected]

* igt@i915_module_load@load:
- fi-bsw-n3050: [PASS][15] -> [ABORT][16]
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-bsw-n3050/igt@[email protected]
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-bsw-n3050/igt@[email protected]
- bat-arlh-2: [PASS][17] -> [ABORT][18]
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-arlh-2/igt@[email protected]
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-arlh-2/igt@[email protected]
- bat-dg2-13: [PASS][19] -> [ABORT][20]
[19]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-dg2-13/igt@[email protected]
[20]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-dg2-13/igt@[email protected]
- fi-cfl-guc: [PASS][21] -> [ABORT][22]
[21]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-cfl-guc/igt@[email protected]
[22]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-cfl-guc/igt@[email protected]
- bat-mtlp-6: [PASS][23] -> [ABORT][24]
[23]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-mtlp-6/igt@[email protected]
[24]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-mtlp-6/igt@[email protected]
- bat-dg2-9: [PASS][25] -> [ABORT][26]
[25]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-dg2-9/igt@[email protected]
[26]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-dg2-9/igt@[email protected]
- bat-arls-2: [PASS][27] -> [ABORT][28]
[27]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-arls-2/igt@[email protected]
[28]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-arls-2/igt@[email protected]
- fi-ilk-650: [PASS][29] -> [ABORT][30]
[29]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-ilk-650/igt@[email protected]
[30]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-ilk-650/igt@[email protected]
- fi-blb-e6850: [PASS][31] -> [ABORT][32]
[31]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-blb-e6850/igt@[email protected]
[32]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-blb-e6850/igt@[email protected]
- bat-dg2-11: [PASS][33] -> [ABORT][34]
[33]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-dg2-11/igt@[email protected]
[34]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-dg2-11/igt@[email protected]
- fi-cfl-8700k: [PASS][35] -> [ABORT][36]
[35]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-cfl-8700k/igt@[email protected]
[36]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-cfl-8700k/igt@[email protected]
- bat-dg2-14: [PASS][37] -> [ABORT][38]
[37]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-dg2-14/igt@[email protected]
[38]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-dg2-14/igt@[email protected]
- fi-elk-e7500: [PASS][39] -> [ABORT][40]
[39]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-elk-e7500/igt@[email protected]
[40]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-elk-e7500/igt@[email protected]
- fi-bsw-nick: [PASS][41] -> [ABORT][42]
[41]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-bsw-nick/igt@[email protected]
[42]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-bsw-nick/igt@[email protected]
- fi-hsw-4770: [PASS][43] -> [ABORT][44]
[43]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-hsw-4770/igt@[email protected]
[44]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-hsw-4770/igt@[email protected]
- fi-ivb-3770: [PASS][45] -> [ABORT][46]
[45]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-ivb-3770/igt@[email protected]
[46]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-ivb-3770/igt@[email protected]
- bat-mtlp-8: [PASS][47] -> [ABORT][48]
[47]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-mtlp-8/igt@[email protected]
[48]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-mtlp-8/igt@[email protected]
- bat-dg2-8: [PASS][49] -> [ABORT][50]
[49]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-dg2-8/igt@[email protected]
[50]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-dg2-8/igt@[email protected]

* igt@i915_pm_rpm@module-reload:
- bat-kbl-2: [PASS][51] -> [DMESG-WARN][52] +42 other tests dmesg-warn
[51]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-kbl-2/igt@[email protected]
[52]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-kbl-2/igt@[email protected]
- bat-adlp-6: [PASS][53] -> [DMESG-WARN][54] +41 other tests dmesg-warn
[53]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-adlp-6/igt@[email protected]
[54]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-adlp-6/igt@[email protected]

* igt@i915_selftest@live@client:
- fi-kbl-guc: [PASS][55] -> [DMESG-WARN][56] +42 other tests dmesg-warn
[55]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-kbl-guc/igt@i915_selftest@[email protected]
[56]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-kbl-guc/igt@i915_selftest@[email protected]
- bat-adls-6: [PASS][57] -> [DMESG-WARN][58] +41 other tests dmesg-warn
[57]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-adls-6/igt@i915_selftest@[email protected]
[58]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-adls-6/igt@i915_selftest@[email protected]
- bat-adlm-1: [PASS][59] -> [DMESG-WARN][60] +34 other tests dmesg-warn
[59]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-adlm-1/igt@i915_selftest@[email protected]
[60]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-adlm-1/igt@i915_selftest@[email protected]

* igt@i915_selftest@live@coherency:
- fi-kbl-x1275: [PASS][61] -> [DMESG-WARN][62] +42 other tests dmesg-warn
[61]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-kbl-x1275/igt@i915_selftest@[email protected]
[62]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-kbl-x1275/igt@i915_selftest@[email protected]
- bat-adlp-11: [PASS][63] -> [DMESG-WARN][64] +41 other tests dmesg-warn
[63]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-adlp-11/igt@i915_selftest@[email protected]
[64]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-adlp-11/igt@i915_selftest@[email protected]

* igt@i915_selftest@live@gem:
- fi-rkl-11600: [PASS][65] -> [DMESG-WARN][66] +34 other tests dmesg-warn
[65]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-rkl-11600/igt@i915_selftest@[email protected]
[66]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-rkl-11600/igt@i915_selftest@[email protected]

* igt@i915_selftest@live@gt_contexts:
- bat-jsl-1: [PASS][67] -> [DMESG-WARN][68] +40 other tests dmesg-warn
[67]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-jsl-1/igt@i915_selftest@live@gt_contexts.html
[68]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-jsl-1/igt@i915_selftest@live@gt_contexts.html

* igt@i915_selftest@live@gt_heartbeat:
- bat-rpls-4: [PASS][69] -> [DMESG-WARN][70] +41 other tests dmesg-warn
[69]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-rpls-4/igt@i915_selftest@live@gt_heartbeat.html
[70]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-rpls-4/igt@i915_selftest@live@gt_heartbeat.html

* igt@i915_selftest@live@gt_mocs:
- bat-twl-2: [PASS][71] -> [DMESG-WARN][72] +34 other tests dmesg-warn
[71]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-twl-2/igt@i915_selftest@live@gt_mocs.html
[72]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-twl-2/igt@i915_selftest@live@gt_mocs.html

* igt@i915_selftest@live@gt_pm:
- fi-tgl-1115g4: [PASS][73] -> [DMESG-WARN][74] +41 other tests dmesg-warn
[73]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-tgl-1115g4/igt@i915_selftest@live@gt_pm.html
[74]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-tgl-1115g4/igt@i915_selftest@live@gt_pm.html

* igt@i915_selftest@live@gt_tlb:
- bat-adlp-9: [PASS][75] -> [DMESG-WARN][76] +41 other tests dmesg-warn
[75]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-adlp-9/igt@i915_selftest@live@gt_tlb.html
[76]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-adlp-9/igt@i915_selftest@live@gt_tlb.html

* igt@i915_selftest@live@hangcheck:
- bat-jsl-3: [PASS][77] -> [DMESG-WARN][78] +39 other tests dmesg-warn
[77]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-jsl-3/igt@i915_selftest@[email protected]
[78]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-jsl-3/igt@i915_selftest@[email protected]

* igt@i915_selftest@live@hugepages:
- fi-glk-j4005: [PASS][79] -> [DMESG-WARN][80] +35 other tests dmesg-warn
[79]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-glk-j4005/igt@i915_selftest@[email protected]
[80]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-glk-j4005/igt@i915_selftest@[email protected]

* igt@i915_selftest@live@late_gt_pm:
- fi-cfl-8109u: [PASS][81] -> [DMESG-WARN][82] +42 other tests dmesg-warn
[81]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-cfl-8109u/igt@i915_selftest@live@late_gt_pm.html
[82]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-cfl-8109u/igt@i915_selftest@live@late_gt_pm.html

* igt@i915_selftest@live@sanitycheck:
- fi-kbl-7567u: [PASS][83] -> [DMESG-WARN][84] +41 other tests dmesg-warn
[83]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-kbl-7567u/igt@i915_selftest@[email protected]
[84]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-kbl-7567u/igt@i915_selftest@[email protected]
- bat-twl-1: [PASS][85] -> [DMESG-WARN][86] +33 other tests dmesg-warn
[85]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-twl-1/igt@i915_selftest@[email protected]
[86]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-twl-1/igt@i915_selftest@[email protected]
- bat-rplp-1: [PASS][87] -> [DMESG-WARN][88] +41 other tests dmesg-warn
[87]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-rplp-1/igt@i915_selftest@[email protected]
[88]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-rplp-1/igt@i915_selftest@[email protected]

* igt@i915_selftest@live@uncore:
- bat-dg1-7: [PASS][89] -> [DMESG-WARN][90] +38 other tests dmesg-warn
[89]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-dg1-7/igt@i915_selftest@[email protected]
[90]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-dg1-7/igt@i915_selftest@[email protected]

* igt@kms_frontbuffer_tracking@basic:
- fi-cfl-8109u: [PASS][91] -> [DMESG-FAIL][92] +2 other tests dmesg-fail
[91]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-cfl-8109u/igt@[email protected]
[92]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-cfl-8109u/igt@[email protected]

#### Warnings ####

* igt@i915_module_load@load:
- bat-arls-5: [DMESG-WARN][93] ([i915#11637]) -> [ABORT][94]
[93]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-arls-5/igt@[email protected]
[94]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-arls-5/igt@[email protected]

* igt@i915_selftest@live:
- bat-apl-1: [DMESG-WARN][95] ([i915#11621]) -> [INCOMPLETE][96] +1 other test incomplete
[95]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-apl-1/igt@[email protected]
[96]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-apl-1/igt@[email protected]

* igt@kms_frontbuffer_tracking@basic:
- bat-apl-1: [DMESG-WARN][97] ([i915#11621]) -> [DMESG-FAIL][98]
[97]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-apl-1/igt@[email protected]
[98]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-apl-1/igt@[email protected]

#### Suppressed ####

The following results come from untrusted machines, tests, or statuses. They do not affect the overall result.

* igt@i915_module_load@load:
- {bat-arlh-3}: [PASS][99] -> [ABORT][100]
[99]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-arlh-3/igt@[email protected]
[100]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-arlh-3/igt@[email protected]

* igt@i915_selftest@live@gt_engines:
- {bat-dg1-6}: [PASS][101] -> [DMESG-WARN][102] +45 other tests dmesg-warn
[101]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-dg1-6/igt@i915_selftest@live@gt_engines.html
[102]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-dg1-6/igt@i915_selftest@live@gt_engines.html

Known issues
------------

Here are the changes found in Patchwork_139628v1 that come from known issues:

### IGT changes ###

#### Issues hit ####

* igt@core_hotunplug@unbind-rebind:
- bat-jsl-1: [PASS][103] -> [DMESG-WARN][104] ([i915#1982])
[103]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-jsl-1/igt@[email protected]
[104]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-jsl-1/igt@[email protected]

* igt@i915_module_load@reload:
- fi-kbl-7567u: [PASS][105] -> [DMESG-WARN][106] ([i915#1982])
[105]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-kbl-7567u/igt@[email protected]
[106]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-kbl-7567u/igt@[email protected]
- bat-twl-1: [PASS][107] -> [DMESG-WARN][108] ([i915#1982])
[107]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-twl-1/igt@[email protected]
[108]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-twl-1/igt@[email protected]
- bat-jsl-3: [PASS][109] -> [DMESG-WARN][110] ([i915#1982])
[109]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-jsl-3/igt@[email protected]
[110]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-jsl-3/igt@[email protected]

* igt@i915_selftest@live:
- bat-adlm-1: [PASS][111] -> [DMESG-WARN][112] ([i915#12133]) +6 other tests dmesg-warn
[111]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-adlm-1/igt@[email protected]
[112]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-adlm-1/igt@[email protected]
- bat-jsl-3: [PASS][113] -> [DMESG-WARN][114] ([i915#12010])
[113]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-jsl-3/igt@[email protected]
[114]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-jsl-3/igt@[email protected]

* igt@i915_selftest@live@gt_heartbeat:
- bat-twl-1: [PASS][115] -> [DMESG-WARN][116] ([i915#12133]) +6 other tests dmesg-warn
[115]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-twl-1/igt@i915_selftest@live@gt_heartbeat.html
[116]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-twl-1/igt@i915_selftest@live@gt_heartbeat.html
- fi-rkl-11600: [PASS][117] -> [DMESG-WARN][118] ([i915#12133]) +6 other tests dmesg-warn
[117]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-rkl-11600/igt@i915_selftest@live@gt_heartbeat.html
[118]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-rkl-11600/igt@i915_selftest@live@gt_heartbeat.html

* igt@i915_selftest@live@late_gt_pm:
- bat-twl-2: [PASS][119] -> [DMESG-WARN][120] ([i915#12133]) +6 other tests dmesg-warn
[119]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-twl-2/igt@i915_selftest@live@late_gt_pm.html
[120]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-twl-2/igt@i915_selftest@live@late_gt_pm.html

* igt@i915_selftest@live@migrate:
- bat-dg1-7: [PASS][121] -> [DMESG-WARN][122] ([i915#12133]) +6 other tests dmesg-warn
[121]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-dg1-7/igt@i915_selftest@[email protected]
[122]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-dg1-7/igt@i915_selftest@[email protected]
- fi-glk-j4005: [PASS][123] -> [DMESG-WARN][124] ([i915#12133]) +6 other tests dmesg-warn
[123]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/fi-glk-j4005/igt@i915_selftest@[email protected]
[124]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/fi-glk-j4005/igt@i915_selftest@[email protected]

#### Warnings ####

* igt@i915_module_load@reload:
- bat-apl-1: [DMESG-WARN][125] ([i915#180] / [i915#1982]) -> [DMESG-WARN][126] ([i915#180]) +1 other test dmesg-warn
[125]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-apl-1/igt@[email protected]
[126]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-apl-1/igt@[email protected]

* igt@i915_pm_rpm@module-reload:
- bat-apl-1: [DMESG-WARN][127] ([i915#11621] / [i915#180] / [i915#1982]) -> [DMESG-WARN][128] ([i915#11621] / [i915#180])
[127]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_15489/bat-apl-1/igt@[email protected]
[128]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/bat-apl-1/igt@[email protected]

{name}: This element is suppressed. This means it is ignored when computing
the status of the difference (SUCCESS, WARNING, or FAILURE).

[i915#11621]: https://gitlab.freedesktop.org/drm/i915/kernel/-/issues/11621
[i915#11637]: https://gitlab.freedesktop.org/drm/i915/kernel/-/issues/11637
[i915#12010]: https://gitlab.freedesktop.org/drm/i915/kernel/-/issues/12010
[i915#12133]: https://gitlab.freedesktop.org/drm/i915/kernel/-/issues/12133
[i915#180]: https://gitlab.freedesktop.org/drm/i915/kernel/-/issues/180
[i915#1982]: https://gitlab.freedesktop.org/drm/i915/kernel/-/issues/1982

Build changes
-------------

* Linux: CI_DRM_15489 -> Patchwork_139628v1

CI-20190529: 20190529
CI_DRM_15489: fc6867c683c18ec3ac31682fd37d418d8a8ebde1 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_8054: 3f627b7fd48c6ab324ceaa80dd8cf0131292bf63 @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git
Patchwork_139628v1: fc6867c683c18ec3ac31682fd37d418d8a8ebde1 @ git://anongit.freedesktop.org/gfx-ci/linux

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_139628v1/index.html

maintainer
#5 lore raw
In reply to Raag Jadav
Quoted 4 lines · Raag Jadav

Host BIOS doesn't enable G8 power mode due to an issue on DG2, so we enable it from kernel with Wa_14022698589. Currently it is enabled for all DG2 devices with the exception of a few, for which, it is enabled only when paired with whitelisted CPU models.

In commit messages "currently" and the present tense usually refer to the status quo before the patch has been merged. Doesn't seem to be the case here, and it confuses what we have now and what the patch changes.

Quoted 43 lines
---
 drivers/gpu/drm/i915/gt/intel_workarounds.c | 43 +++++++++++++++++++++
 drivers/gpu/drm/i915/i915_reg.h             |  1 +
 2 files changed, 44 insertions(+)
drivers/gpu/drm/i915/gt/intel_workarounds.c +19 -0
index e539a656cfc3..b2db51377488 100644
@@ -14,11 +14,30 @@
 #include "intel_gt_mcr.h"
 #include "intel_gt_print.h"
 #include "intel_gt_regs.h"
+#include "intel_pcode.h"
 #include "intel_ring.h"
 #include "intel_workarounds.h"
 
 #include "display/intel_fbc_regs.h"
 
+#ifdef CONFIG_X86
+#include <asm/cpu_device_id.h>
+#include <asm/intel-family.h>
+
+static const struct x86_cpu_id g8_cpu_ids[] = {
+	X86_MATCH_VFM(INTEL_ALDERLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_ALDERLAKE_L,	NULL),
+	X86_MATCH_VFM(INTEL_COMETLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_KABYLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_KABYLAKE_L,		NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE_P,	NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE_S,	NULL),
+	X86_MATCH_VFM(INTEL_ROCKETLAKE,		NULL),
+	{}
+};
+#endif
+
 /**
  * DOC: Hardware workarounds
  *

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct i915_wa_list *wal) · line 1793

Quoted 5 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +2 -0
@@ -1770,9 +1789,33 @@ static void wa_list_apply(const struct i915_wa_list *wal)
 	intel_gt_mcr_unlock(gt, flags);
 }
 
+#define DG2_G8_WA_RANGE_1		0x56A0 ... 0x56AF
+#define DG2_G8_WA_RANGE_2		0x56B0 ... 0x56B9

Absolutely not.

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct i915_wa_list *wal) · line 1799

Quoted 6 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +6 -0
+
+/* Wa_14022698589:dg2 */
+static void intel_enable_g8(struct intel_uncore *uncore)
+{
+	if (IS_DG2(uncore->i915)) {
+		switch (INTEL_DEVID(uncore->i915)) {

Even using INTEL_DEVID() is a no-go. There are currently four users, and even some of them are too much.

We try hard to abstract this stuff at a higher level, and there must be zero direct PCI ID checks in code other than the table driven device identification. Otherwise it's just impossible to figure out where we do platform specific stuff for each platform.

I understand those ranges above are a PITA to deal with, because they span across DG2 subplatforms.

BR,
Jani.

Quoted 34 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +16 -0
+		case DG2_G8_WA_RANGE_1:
+		case DG2_G8_WA_RANGE_2:
+#ifdef CONFIG_X86
+			if (!x86_match_cpu(g8_cpu_ids))
+#endif
+				return;
+		}
+
+		snb_pcode_write_p(uncore, PCODE_POWER_SETUP,
+				  POWER_SETUP_SUBCOMMAND_G8_ENABLE, 0, 0);
+	}
+}
+
 void intel_gt_apply_workarounds(struct intel_gt *gt)
 {
 	wa_list_apply(&gt->wa_list);
+
+	/* Special case for pcode mailbox which can't be on wa_list */
+	intel_enable_g8(gt->uncore);
 }
 
 static bool wa_list_verify(struct intel_gt *gt,
drivers/gpu/drm/i915/i915_reg.h +1 -0
index 41f4350a7c6c..e948b194550c 100644
@@ -3568,6 +3568,7 @@
 #define   PCODE_POWER_SETUP			0x7C
 #define     POWER_SETUP_SUBCOMMAND_READ_I1	0x4
 #define     POWER_SETUP_SUBCOMMAND_WRITE_I1	0x5
+#define     POWER_SETUP_SUBCOMMAND_G8_ENABLE	0x6
 #define	    POWER_SETUP_I1_WATTS		REG_BIT(31)
 #define	    POWER_SETUP_I1_SHIFT		6	/* 10.6 fixed point format */
 #define	    POWER_SETUP_I1_DATA_MASK		REG_GENMASK(15, 0)
Signature · 1 line
Jani Nikula, Intel
author
#6 lore raw
Quoted 9 lines · Jani Nikula
Quoted 4 lines · Raag Jadav

Host BIOS doesn't enable G8 power mode due to an issue on DG2, so we enable it from kernel with Wa_14022698589. Currently it is enabled for all DG2 devices with the exception of a few, for which, it is enabled only when paired with whitelisted CPU models.

In commit messages "currently" and the present tense usually refer to the status quo before the patch has been merged. Doesn't seem to be the case here, and it confuses what we have now and what the patch changes.

True.

Quoted 46 lines
Quoted 46 lines
---
 drivers/gpu/drm/i915/gt/intel_workarounds.c | 43 +++++++++++++++++++++
 drivers/gpu/drm/i915/i915_reg.h             |  1 +
 2 files changed, 44 insertions(+)
drivers/gpu/drm/i915/gt/intel_workarounds.c +19 -0
index e539a656cfc3..b2db51377488 100644
@@ -14,11 +14,30 @@
 #include "intel_gt_mcr.h"
 #include "intel_gt_print.h"
 #include "intel_gt_regs.h"
+#include "intel_pcode.h"
 #include "intel_ring.h"
 #include "intel_workarounds.h"
 
 #include "display/intel_fbc_regs.h"
 
+#ifdef CONFIG_X86
+#include <asm/cpu_device_id.h>
+#include <asm/intel-family.h>
+
+static const struct x86_cpu_id g8_cpu_ids[] = {
+	X86_MATCH_VFM(INTEL_ALDERLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_ALDERLAKE_L,	NULL),
+	X86_MATCH_VFM(INTEL_COMETLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_KABYLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_KABYLAKE_L,		NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE_P,	NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE_S,	NULL),
+	X86_MATCH_VFM(INTEL_ROCKETLAKE,		NULL),
+	{}
+};
+#endif
+
 /**
  * DOC: Hardware workarounds
  *
@@ -1770,9 +1789,33 @@ static void wa_list_apply(const struct i915_wa_list *wal)
 	intel_gt_mcr_unlock(gt, flags);
 }
 
Quoted 4 lines

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct i915_wa_list *wal) · line 1793

Quoted 2 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +2 -0
+#define DG2_G8_WA_RANGE_1		0x56A0 ... 0x56AF
+#define DG2_G8_WA_RANGE_2		0x56B0 ... 0x56B9

Absolutely not.

I had an "ugly" self-note which I forgot to add while sending out :D

Quoted 10 lines

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct i915_wa_list *wal) · line 1799

Quoted 6 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +6 -0
+
+/* Wa_14022698589:dg2 */
+static void intel_enable_g8(struct intel_uncore *uncore)
+{
+	if (IS_DG2(uncore->i915)) {
+		switch (INTEL_DEVID(uncore->i915)) {

Even using INTEL_DEVID() is a no-go. There are currently four users, and even some of them are too much.

Quoted 4 lines

We try hard to abstract this stuff at a higher level, and there must be zero direct PCI ID checks in code other than the table driven device identification. Otherwise it's just impossible to figure out where we do platform specific stuff for each platform.

Even if we use pci_match_id(), we'd need an explicit list to match against. Any better way?

Raag

maintainer
#7 lore raw
Quoted 76 lines · Raag Jadav
Quoted 9 lines · Jani Nikula
Quoted 4 lines · Raag Jadav

Host BIOS doesn't enable G8 power mode due to an issue on DG2, so we enable it from kernel with Wa_14022698589. Currently it is enabled for all DG2 devices with the exception of a few, for which, it is enabled only when paired with whitelisted CPU models.

In commit messages "currently" and the present tense usually refer to the status quo before the patch has been merged. Doesn't seem to be the case here, and it confuses what we have now and what the patch changes.

True.

Quoted 46 lines
Quoted 46 lines
---
 drivers/gpu/drm/i915/gt/intel_workarounds.c | 43 +++++++++++++++++++++
 drivers/gpu/drm/i915/i915_reg.h             |  1 +
 2 files changed, 44 insertions(+)
drivers/gpu/drm/i915/gt/intel_workarounds.c +19 -0
index e539a656cfc3..b2db51377488 100644
@@ -14,11 +14,30 @@
 #include "intel_gt_mcr.h"
 #include "intel_gt_print.h"
 #include "intel_gt_regs.h"
+#include "intel_pcode.h"
 #include "intel_ring.h"
 #include "intel_workarounds.h"
 
 #include "display/intel_fbc_regs.h"
 
+#ifdef CONFIG_X86
+#include <asm/cpu_device_id.h>
+#include <asm/intel-family.h>
+
+static const struct x86_cpu_id g8_cpu_ids[] = {
+	X86_MATCH_VFM(INTEL_ALDERLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_ALDERLAKE_L,	NULL),
+	X86_MATCH_VFM(INTEL_COMETLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_KABYLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_KABYLAKE_L,		NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE_P,	NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE_S,	NULL),
+	X86_MATCH_VFM(INTEL_ROCKETLAKE,		NULL),
+	{}
+};
+#endif
+
 /**
  * DOC: Hardware workarounds
  *
@@ -1770,9 +1789,33 @@ static void wa_list_apply(const struct i915_wa_list *wal)
 	intel_gt_mcr_unlock(gt, flags);
 }
 
Quoted 4 lines

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct i915_wa_list *wal) · line 1793

Quoted 2 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +2 -0
+#define DG2_G8_WA_RANGE_1		0x56A0 ... 0x56AF
+#define DG2_G8_WA_RANGE_2		0x56B0 ... 0x56B9

Absolutely not.

I had an "ugly" self-note which I forgot to add while sending out :D

Quoted 10 lines

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct i915_wa_list *wal) · line 1799

Quoted 6 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +6 -0
+
+/* Wa_14022698589:dg2 */
+static void intel_enable_g8(struct intel_uncore *uncore)
+{
+	if (IS_DG2(uncore->i915)) {
+		switch (INTEL_DEVID(uncore->i915)) {

Even using INTEL_DEVID() is a no-go. There are currently four users, and even some of them are too much.

Quoted 6 lines
Quoted 4 lines

We try hard to abstract this stuff at a higher level, and there must be zero direct PCI ID checks in code other than the table driven device identification. Otherwise it's just impossible to figure out where we do platform specific stuff for each platform.

Even if we use pci_match_id(), we'd need an explicit list to match against.

Well, we don't use that for individual workarounds or hacks either. When you think of using something like that, see what git grep says.

Quoted 1 line

Any better way?

You probably need to turn it into another subplatform, and add it in intel_device_info.c. You're probably going to need to rehash the INTEL_DG2_*_IDS PCI ID macros too. That's how we tell platforms apart at the PCI ID granularity.

BR,
Jani.

Quoted 2 lines

Raag

Signature · 1 line
Jani Nikula, Intel
author
#8 lore raw
Quoted 23 lines · Jani Nikula
Quoted 12 lines · Raag Jadav
Quoted 11 lines · Jani Nikula

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct i915_wa_list *wal) · line 1799

Quoted 6 lines · Raag Jadav
drivers/gpu/drm/i915/gt/intel_workarounds.c +6 -0
+
+/* Wa_14022698589:dg2 */
+static void intel_enable_g8(struct intel_uncore *uncore)
+{
+	if (IS_DG2(uncore->i915)) {
+		switch (INTEL_DEVID(uncore->i915)) {

Even using INTEL_DEVID() is a no-go. There are currently four users, and even some of them are too much.

Quoted 6 lines
Quoted 4 lines

We try hard to abstract this stuff at a higher level, and there must be zero direct PCI ID checks in code other than the table driven device identification. Otherwise it's just impossible to figure out where we do platform specific stuff for each platform.

Even if we use pci_match_id(), we'd need an explicit list to match against.

Well, we don't use that for individual workarounds or hacks either. When you think of using something like that, see what git grep says.

Quoted 6 lines
Quoted 1 line

Any better way?

You probably need to turn it into another subplatform, and add it in intel_device_info.c. You're probably going to need to rehash the INTEL_DG2_*_IDS PCI ID macros too. That's how we tell platforms apart at the PCI ID granularity.

Which would be controversial since the ids span across existing subplatforms, which we don't want to break.

Don't we have quirk mask thing like display?

Raag

maintainer
#9 lore raw
Quoted 26 lines · Raag Jadav
Quoted 25 lines · Jani Nikula
Quoted 12 lines · Raag Jadav
Quoted 11 lines · Jani Nikula

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct i915_wa_list *wal) · line 1799

Quoted 6 lines · Raag Jadav
drivers/gpu/drm/i915/gt/intel_workarounds.c +6 -0
+
+/* Wa_14022698589:dg2 */
+static void intel_enable_g8(struct intel_uncore *uncore)
+{
+	if (IS_DG2(uncore->i915)) {
+		switch (INTEL_DEVID(uncore->i915)) {

Even using INTEL_DEVID() is a no-go. There are currently four users, and even some of them are too much.

Quoted 6 lines
Quoted 4 lines

We try hard to abstract this stuff at a higher level, and there must be zero direct PCI ID checks in code other than the table driven device identification. Otherwise it's just impossible to figure out where we do platform specific stuff for each platform.

Even if we use pci_match_id(), we'd need an explicit list to match against.

Well, we don't use that for individual workarounds or hacks either. When you think of using something like that, see what git grep says.

Quoted 1 line

Any better way?

Quoted 7 lines
Quoted 4 lines

You probably need to turn it into another subplatform, and add it in intel_device_info.c. You're probably going to need to rehash the INTEL_DG2_*_IDS PCI ID macros too. That's how we tell platforms apart at the PCI ID granularity.

Which would be controversial since the ids span across existing subplatforms, which we don't want to break.

The i915 subplatform thing supports multiple subplatforms.

Quoted 1 line

Don't we have quirk mask thing like display?

Please elaborate.

BR,
Jani.

Signature · 1 line
Jani Nikula, Intel
#10 lore raw
In reply to Raag Jadav
Quoted 26 lines · Raag Jadav
Quoted 25 lines · Jani Nikula
Quoted 12 lines · Raag Jadav
Quoted 11 lines · Jani Nikula

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct i915_wa_list *wal) · line 1799

Quoted 6 lines · Raag Jadav
drivers/gpu/drm/i915/gt/intel_workarounds.c +6 -0
+
+/* Wa_14022698589:dg2 */
+static void intel_enable_g8(struct intel_uncore *uncore)
+{
+	if (IS_DG2(uncore->i915)) {
+		switch (INTEL_DEVID(uncore->i915)) {

Even using INTEL_DEVID() is a no-go. There are currently four users, and even some of them are too much.

Quoted 6 lines
Quoted 4 lines

We try hard to abstract this stuff at a higher level, and there must be zero direct PCI ID checks in code other than the table driven device identification. Otherwise it's just impossible to figure out where we do platform specific stuff for each platform.

Even if we use pci_match_id(), we'd need an explicit list to match against.

Well, we don't use that for individual workarounds or hacks either. When you think of using something like that, see what git grep says.

Quoted 1 line

Any better way?

Quoted 7 lines
Quoted 4 lines

You probably need to turn it into another subplatform, and add it in intel_device_info.c. You're probably going to need to rehash the INTEL_DG2_*_IDS PCI ID macros too. That's how we tell platforms apart at the PCI ID granularity.

Which would be controversial since the ids span across existing subplatforms, which we don't want to break.

A single platform can belong to multiple subplatforms. So it's fine, for example, for a specific device ID to belong to both the DG2-G11 subplatform and the "do extra G8 stuff" subplatform. You'll just need to make sure you separate out the G8 subplatform into a separate 'if' statement rather than trying to include it in the current if/else ladder.

Matt

Quoted 4 lines

Don't we have quirk mask thing like display?

Raag

Signature · 4 lines
Matt Roper
Graphics Software Engineer
Linux GPU Platform Enablement
Intel Corporation
#11 lore raw
In reply to Raag Jadav
Quoted 13 lines

-----Original Message-----
From: Jadav, Raag <[email protected]>
Sent: Wednesday, October 9, 2024 6:18 PM
To: Jani Nikula <[email protected]>
Cc: [email protected]; Vivi, Rodrigo <[email protected]>; Roper, Matthew D <[email protected]>; [email protected]; [email protected]; Gupta, Anshuman <[email protected]>; Nilawar, Badal <[email protected]>; Tauro, Riana <[email protected]>
Subject: Re: [PATCH v1] drm/i915/dg2: enable G8 with a workaround

Quoted 3 lines
Quoted 2 lines · Jani Nikula
Quoted 1 line · Raag Jadav

Host BIOS doesn't enable G8 power mode due to an issue on DG2, so we

AFAIU it discrete card firmware not HOST bios.
Thanks,
Anshuman.

Quoted 84 lines
Quoted 7 lines
Quoted 3 lines

enable it from kernel with Wa_14022698589. Currently it is enabled for all DG2 devices with the exception of a few, for which, it is enabled only when paired with whitelisted CPU models.

In commit messages "currently" and the present tense usually refer to the status quo before the patch has been merged. Doesn't seem to be the case here, and it confuses what we have now and what the patch changes.

True.

Quoted 4 lines
Quoted 4 lines
---
 drivers/gpu/drm/i915/gt/intel_workarounds.c | 43

+++++++++++++++++++++

Quoted 32 lines
Quoted 32 lines
 drivers/gpu/drm/i915/i915_reg.h             |  1 +
 2 files changed, 44 insertions(+)
drivers/gpu/drm/i915/gt/intel_workarounds.c +15 -0
index e539a656cfc3..b2db51377488 100644
@@ -14,11 +14,30 @@
 #include "intel_gt_mcr.h"
 #include "intel_gt_print.h"
 #include "intel_gt_regs.h"
+#include "intel_pcode.h"
 #include "intel_ring.h"
 #include "intel_workarounds.h"
 
 #include "display/intel_fbc_regs.h"
 
+#ifdef CONFIG_X86
+#include <asm/cpu_device_id.h>
+#include <asm/intel-family.h>
+
+static const struct x86_cpu_id g8_cpu_ids[] = {
+	X86_MATCH_VFM(INTEL_ALDERLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_ALDERLAKE_L,	NULL),
+	X86_MATCH_VFM(INTEL_COMETLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_KABYLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_KABYLAKE_L,		NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE,		NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE_P,	NULL),
+	X86_MATCH_VFM(INTEL_RAPTORLAKE_S,	NULL),
+	X86_MATCH_VFM(INTEL_ROCKETLAKE,		NULL),
Quoted 8 lines

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct

Quoted 8 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +4 -0
+	{}
+};
+#endif
+
 /**
  * DOC: Hardware workarounds
  *
@@ -1770,9 +1789,33 @@ static void wa_list_apply(const struct

i915_wa_list *wal)

Quoted 7 lines

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct i915_wa_list *wal) · line 1793

Quoted 5 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +2 -0
 	intel_gt_mcr_unlock(gt, flags);
 }
 
+#define DG2_G8_WA_RANGE_1		0x56A0 ... 0x56AF
+#define DG2_G8_WA_RANGE_2		0x56B0 ... 0x56B9

Absolutely not.

I had an "ugly" self-note which I forgot to add while sending out :D

Quoted 9 lines

drivers/gpu/drm/i915/gt/intel_workarounds.c static void wa_list_apply(const struct i915_wa_list *wal) · line 1799

Quoted 5 lines
drivers/gpu/drm/i915/gt/intel_workarounds.c +5 -0
+
+/* Wa_14022698589:dg2 */
+static void intel_enable_g8(struct intel_uncore *uncore) {
+	if (IS_DG2(uncore->i915)) {
+		switch (INTEL_DEVID(uncore->i915)) {

Even using INTEL_DEVID() is a no-go. There are currently four users, and even some of them are too much.

Quoted 4 lines

We try hard to abstract this stuff at a higher level, and there must be zero direct PCI ID checks in code other than the table driven device identification. Otherwise it's just impossible to figure out where we do platform specific stuff for each platform.

Even if we use pci_match_id(), we'd need an explicit list to match against. Any better way?

Raag

#13 lore raw
In reply to Raag Jadav
kernel test robot noticed "UBSAN:array-index-out-of-bounds_in_drivers/gpu/drm/i915/i915_drv.h" on:

Hello,

kernel test robot noticed "UBSAN:array-index-out-of-bounds_in_drivers/gpu/drm/i915/i915_drv.h" on:

commit: 3d845c2240623759952e06027546304b127ec1c5 ("[PATCH v1] drm/i915/dg2: enable G8 with a workaround")
url: https://github.com/intel-lab-lkp/linux/commits/Raag-Jadav/drm-i915-dg2-enable-G8-with-a-workaround/20241007-202716
base: git://anongit.freedesktop.org/drm-intel for-linux-next
patch link: https://lore.kernel.org/all/[email protected]/
patch subject: [PATCH v1] drm/i915/dg2: enable G8 with a workaround

in testcase: suspend-stress
version:
with following parameters:

mode: freeze
iterations: 10

config: x86_64-rhel-8.3-func
compiler: gcc-12
test machine: 4 threads (Broadwell) with 8G memory

(please refer to attached dmesg/kmsg for entire log/backtrace)

If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <[email protected]>
| Closes: https://lore.kernel.org/oe-lkp/[email protected]

kern  :warn  : [   28.439916] ------------[ cut here ]------------
kern  :err   : [   28.440035] UBSAN: array-index-out-of-bounds in drivers/gpu/drm/i915/i915_drv.h:466:28
kern  :err   : [   28.440211] index 58 is out of range for type 'u32 [2]'
kern  :warn  : [   28.440322] CPU: 1 UID: 0 PID: 202 Comm: systemd-udevd Not tainted 6.12.0-rc1-00198-g3d845c224062 #1
kern  :warn  : [   28.440489] Hardware name:  /NUC5i3RYB, BIOS RYBDWi35.86A.0363.2017.0316.1028 03/16/2017
kern  :warn  : [   28.440636] Call Trace:
kern  :warn  : [   28.440703]  <TASK>
kern :warn : [   28.440764] dump_stack_lvl (lib/dump_stack.c:123 (discriminator 1)) 
kern :warn : [   28.440862] __ubsan_handle_out_of_bounds (lib/ubsan.c:232 lib/ubsan.c:429) 
kern :warn : [   28.440977] gt_init_workarounds (drivers/gpu/drm/i915/i915_drv.h:466 drivers/gpu/drm/i915/gt/intel_workarounds.c:1689) i915
kern :warn : [   28.441968] ? __pfx_gt_init_workarounds (drivers/gpu/drm/i915/gt/intel_workarounds.c:1665) i915
kern :warn : [   28.442781] ? fwtable_write32 (drivers/gpu/drm/i915/intel_uncore.c:2012 (discriminator 11)) i915
kern :warn : [   28.443526] intel_gt_init_workarounds (drivers/gpu/drm/i915/gt/intel_workarounds.c:1725) i915
kern :warn : [   28.444297] intel_gt_init (drivers/gpu/drm/i915/gt/intel_gt.c:715) i915
kern :warn : [   28.445032] i915_gem_init (drivers/gpu/drm/i915/i915_gem.c:1191) i915
kern :warn : [   28.445793] i915_driver_probe (drivers/gpu/drm/i915/i915_driver.c:799) i915
kern :warn : [   28.446517] ? __pfx_i915_driver_probe (drivers/gpu/drm/i915/i915_driver.c:751) i915
kern :warn : [   28.447243] ? drm_privacy_screen_get (drivers/gpu/drm/drm_privacy_screen.c:168) drm
kern :warn : [   28.447499] ? intel_display_driver_probe_defer (drivers/gpu/drm/i915/display/intel_display_driver.c:81) i915
kern :warn : [   28.448300] ? i915_pci_probe (drivers/gpu/drm/i915/i915_pci.c:996) i915
kern :warn : [   28.449003] ? __pfx_i915_pci_probe (drivers/gpu/drm/i915/i915_pci.c:957) i915
kern :warn : [   28.449712] local_pci_probe (drivers/pci/pci-driver.c:324) 
kern :warn : [   28.449811] pci_call_probe (drivers/pci/pci-driver.c:392) 
kern :warn : [   28.449905] ? _raw_spin_lock (arch/x86/include/asm/atomic.h:107 include/linux/atomic/atomic-arch-fallback.h:2170 include/linux/atomic/atomic-instrumented.h:1302 include/asm-generic/qspinlock.h:111 include/linux/spinlock.h:187 include/linux/spinlock_api_smp.h:134 kernel/locking/spinlock.c:154) 
kern :warn : [   28.449998] ? __pfx_pci_call_probe (drivers/pci/pci-driver.c:352) 
kern :warn : [   28.450095] ? kernfs_add_one (fs/kernfs/dir.c:819) 
kern :warn : [   28.450190] ? pci_assign_irq (drivers/pci/irq.c:149) 
kern :warn : [   28.450282] ? pci_match_device (drivers/pci/pci-driver.c:159 (discriminator 1)) 
kern :warn : [   28.450379] ? kernfs_put (arch/x86/include/asm/atomic.h:67 (discriminator 1) include/linux/atomic/atomic-arch-fallback.h:2278 (discriminator 1) include/linux/atomic/atomic-instrumented.h:1384 (discriminator 1) fs/kernfs/dir.c:557 (discriminator 1)) 
kern :warn : [   28.450465] pci_device_probe (drivers/pci/pci-driver.c:452) 
kern :warn : [   28.450557] ? pci_dma_configure (drivers/pci/pci-driver.c:1656) 
kern :warn : [   28.450653] really_probe (drivers/base/dd.c:579 drivers/base/dd.c:658) 
kern :warn : [   28.450741] __driver_probe_device (drivers/base/dd.c:738 drivers/base/dd.c:798) 
kern :warn : [   28.450841] driver_probe_device (drivers/base/dd.c:830) 
kern :warn : [   28.450937] __driver_attach (drivers/base/dd.c:1217) 
kern :warn : [   28.451028] ? __pfx___driver_attach (drivers/base/dd.c:1157) 
kern :warn : [   28.451124] bus_for_each_dev (drivers/base/bus.c:369) 
kern :warn : [   28.451217] ? __pfx_bus_for_each_dev (drivers/base/bus.c:358) 
kern :warn : [   28.451318] ? klist_add_tail (include/linux/list.h:150 include/linux/list.h:183 lib/klist.c:104 lib/klist.c:137) 
kern :warn : [   28.451410] bus_add_driver (drivers/base/bus.c:675) 
kern :warn : [   28.451500] driver_register (drivers/base/driver.c:246) 
kern :warn : [   28.451594] i915_init (drivers/gpu/drm/i915/i915_driver.c:1395) i915
kern :warn : [   28.452466] ? __pfx_i915_init (drivers/gpu/drm/i915/i915_config.c:13) i915
kern :warn : [   28.453207] do_one_initcall (init/main.c:1269) 
kern :warn : [   28.453304] ? __pfx_do_one_initcall (init/main.c:1260) 
kern :warn : [   28.453408] ? kasan_unpoison (mm/kasan/shadow.c:157 mm/kasan/shadow.c:151 mm/kasan/shadow.c:182) 
kern :warn : [   28.453499] ? kasan_unpoison (mm/kasan/shadow.c:156 mm/kasan/shadow.c:182) 
kern :warn : [   28.453592] do_init_module (kernel/module/main.c:2543) 
kern :warn : [   28.453687] init_module_from_file (kernel/module/main.c:3198) 
kern :warn : [   28.453787] ? __pfx_init_module_from_file (kernel/module/main.c:3174) 
kern :warn : [   28.453895] ? __pfx_userfaultfd_unmap_complete (fs/userfaultfd.c:810) 
kern :warn : [   28.454012] ? __pfx__raw_spin_lock (kernel/locking/spinlock.c:153) 
kern :warn : [   28.454112] idempotent_init_module (kernel/module/main.c:3210) 
kern :warn : [   28.454214] ? __pfx_idempotent_init_module (kernel/module/main.c:3202) 
kern :warn : [   28.454321] ? __pfx___seccomp_filter (kernel/seccomp.c:1218) 
kern :warn : [   28.454424] ? fdget (include/linux/atomic/atomic-arch-fallback.h:479 include/linux/atomic/atomic-instrumented.h:50 fs/file.c:1141 fs/file.c:1155) 
kern :warn : [   28.454504] ? security_capable (security/security.c:1142) 
kern :warn : [   28.454599] __x64_sys_finit_module (include/linux/file.h:68 kernel/module/main.c:3238 kernel/module/main.c:3220 kernel/module/main.c:3220) 
kern :warn : [   28.454698] do_syscall_64 (arch/x86/entry/common.c:52 arch/x86/entry/common.c:83) 
kern :warn : [   28.454790] entry_SYSCALL_64_after_hwframe (arch/x86/entry/entry_64.S:130) 

kern :warn : [ 28.454900] RIP: 0033:0x7efbffb92229
kern :warn : [ 28.454984] Code: 00 f3 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d 3f 4c 2b 00 f7 d8 64 89 01 48 All code
========
0: 00 f3 add %dh,%bl
2: c3 retq
3: 66 2e 0f 1f 84 00 00 nopw %cs:0x0(%rax,%rax,1)
a: 00 00 00

   d:	0f 1f 40 00          	nopl   0x0(%rax)
  11:	48 89 f8             	mov    %rdi,%rax
  14:	48 89 f7             	mov    %rsi,%rdi
  17:	48 89 d6             	mov    %rdx,%rsi
  1a:	48 89 ca             	mov    %rcx,%rdx
  1d:	4d 89 c2             	mov    %r8,%r10
  20:	4d 89 c8             	mov    %r9,%r8
  23:	4c 8b 4c 24 08       	mov    0x8(%rsp),%r9
  28:	0f 05                	syscall 
  2a:*	48 3d 01 f0 ff ff    	cmp    $0xfffffffffffff001,%rax		<-- trapping instruction
  30:	73 01                	jae    0x33
  32:	c3                   	retq   
  33:	48 8b 0d 3f 4c 2b 00 	mov    0x2b4c3f(%rip),%rcx        # 0x2b4c79
  3a:	f7 d8                	neg    %eax
  3c:	64 89 01             	mov    %eax,%fs:(%rcx)

3f: 48 rex.W

Code starting with the faulting instruction
===========================================

   0:	48 3d 01 f0 ff ff    	cmp    $0xfffffffffffff001,%rax
   6:	73 01                	jae    0x9
   8:	c3                   	retq   
   9:	48 8b 0d 3f 4c 2b 00 	mov    0x2b4c3f(%rip),%rcx        # 0x2b4c4f
  10:	f7 d8                	neg    %eax
  12:	64 89 01             	mov    %eax,%fs:(%rcx)
  15:	48                   	rex.W
kern  :warn  : [   28.455283] RSP: 002b:00007ffe0d7f9428 EFLAGS: 00000246 ORIG_RAX: 0000000000000139
kern  :warn  : [   28.455429] RAX: ffffffffffffffda RBX: 000055b5a7168b10 RCX: 00007efbffb92229
kern  :warn  : [   28.455562] RDX: 0000000000000000 RSI: 00007efc004ab265 RDI: 0000000000000014
kern  :warn  : [   28.455695] RBP: 00007efc004ab265 R08: 0000000000000000 R09: 00007ffe0d7f99a0
kern  :warn  : [   28.455826] R10: 0000000000000014 R11: 0000000000000246 R12: 0000000000000000
kern  :warn  : [   28.455959] R13: 000055b5a7170fe0 R14: 0000000000020000 R15: 000055b575213cbc
kern  :warn  : [   28.456095]  </TASK>
kern  :warn  : [   28.456422] ---[ end trace ]---

The kernel config and materials to reproduce are available at:
https://download.01.org/0day-ci/archive/20241014/[email protected]

Signature · 2 lines
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki