]> www.infradead.org Git - users/willy/xarray.git/commitdiff
drm/i915/uc: Squelch load failure error message
authorChris Wilson <chris@chris-wilson.co.uk>
Mon, 14 Dec 2020 10:08:42 +0000 (10:08 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Wed, 23 Dec 2020 10:18:43 +0000 (10:18 +0000)
The caller determines if the failure is an error or not, so avoid
warning when we will try again and succeed. For example,

<7> [111.319321] [drm:intel_guc_fw_upload [i915]] GuC status 0x20
<3> [111.319340] i915 0000:00:02.0: [drm] *ERROR* GuC load failed: status = 0x00000020
<3> [111.319606] i915 0000:00:02.0: [drm] *ERROR* GuC load failed: status: Reset = 0, BootROM = 0x10, UKernel = 0x00, MIA = 0x00, Auth = 0x00
<7> [111.320045] [drm:__uc_init_hw [i915]] GuC fw load failed: -110; will reset and retry 2 more time(s)
<7> [111.322978] [drm:intel_guc_fw_upload [i915]] GuC status 0x8002f0ec

should not have been reported as a _test_ failure, as the GuC was
successfully loaded on the second attempt and the system remained
operational.

Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/2797
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20201214100949.11387-2-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/gt/uc/intel_guc_fw.c

index f9d0907ea1a540433102e74b50e7ef6aa0d6770a..2270d6b3b27201a1ad5a9de4782cb1151c0ff8e4 100644 (file)
@@ -76,7 +76,6 @@ static inline bool guc_ready(struct intel_uncore *uncore, u32 *status)
 
 static int guc_wait_ucode(struct intel_uncore *uncore)
 {
-       struct drm_device *drm = &uncore->i915->drm;
        u32 status;
        int ret;
 
@@ -89,11 +88,11 @@ static int guc_wait_ucode(struct intel_uncore *uncore)
         * attempt the ucode load again if this happens.)
         */
        ret = wait_for(guc_ready(uncore, &status), 100);
-       DRM_DEBUG_DRIVER("GuC status %#x\n", status);
-
        if (ret) {
-               drm_err(drm, "GuC load failed: status = 0x%08X\n", status);
-               drm_err(drm, "GuC load failed: status: Reset = %d, "
+               struct drm_device *drm = &uncore->i915->drm;
+
+               drm_dbg(drm, "GuC load failed: status = 0x%08X\n", status);
+               drm_dbg(drm, "GuC load failed: status: Reset = %d, "
                        "BootROM = 0x%02X, UKernel = 0x%02X, "
                        "MIA = 0x%02X, Auth = 0x%02X\n",
                        REG_FIELD_GET(GS_MIA_IN_RESET, status),
@@ -103,12 +102,12 @@ static int guc_wait_ucode(struct intel_uncore *uncore)
                        REG_FIELD_GET(GS_AUTH_STATUS_MASK, status));
 
                if ((status & GS_BOOTROM_MASK) == GS_BOOTROM_RSA_FAILED) {
-                       drm_err(drm, "GuC firmware signature verification failed\n");
+                       drm_dbg(drm, "GuC firmware signature verification failed\n");
                        ret = -ENOEXEC;
                }
 
                if ((status & GS_UKERNEL_MASK) == GS_UKERNEL_EXCEPTION) {
-                       drm_err(drm, "GuC firmware exception. EIP: %#x\n",
+                       drm_dbg(drm, "GuC firmware exception. EIP: %#x\n",
                                intel_uncore_read(uncore, SOFT_SCRATCH(13)));
                        ret = -ENXIO;
                }