Re: [PATCH] drm/i915/uc: Extra info notice about FW version mis-match vs overrides

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 21 Nov 2019 01:27:23 +0100, <John.C.Harrison@xxxxxxxxx> wrote:

From: John Harrison <John.C.Harrison@xxxxxxxxx>

If a FW override is present then a version mis-match is actually
ignored. The warning message was still being printed, though. Which

It wasn't a "warning", just "notice"

could confuse people by implying that the load had failed due to the
mis-match when actually something else had failed.

The mis-match still might be a reason why something else failed.
If there is possible confusing, it's likely due to lack of or incomplete
message from this other failure point. So we should make sure that all
failure points correctly indicate the failure reason to avoid confusing.
Do you recall what this other confusing failure was?


This patch adds an extra message to say that the mis-match is being
ignored if an override is present.

Signed-off-by: John Harrison <John.C.Harrison@xxxxxxxxx>
---
 drivers/gpu/drm/i915/gt/uc/intel_uc_fw.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/gpu/drm/i915/gt/uc/intel_uc_fw.c b/drivers/gpu/drm/i915/gt/uc/intel_uc_fw.c
index 66a30ab7044a..c1ae807b07ae 100644
--- a/drivers/gpu/drm/i915/gt/uc/intel_uc_fw.c
+++ b/drivers/gpu/drm/i915/gt/uc/intel_uc_fw.c
@@ -361,6 +361,9 @@ int intel_uc_fw_fetch(struct intel_uc_fw *uc_fw, struct drm_i915_private *i915)
 			err = -ENOEXEC;
 			goto fail;
 		}
+
+ dev_notice(dev, "%s firmware %s: Firmware override so ignoring version mis-match\n",
+			   intel_uc_fw_type_repr(uc_fw->type), uc_fw->path);

If you still want to include clear statement about mis-match being ignored,
then maybe instead of adding new message it could be combined with old one:

        if (uc_fw->major_ver_found != uc_fw->major_ver_wanted ||
            uc_fw->minor_ver_found < uc_fw->minor_ver_wanted) {
- dev_notice(dev, "%s firmware %s: unexpected version: %u.%u != %u.%u\n",
+               dev_notice(dev, "%s firmware %s: %s: %u.%u != %u.%u\n",
                           intel_uc_fw_type_repr(uc_fw->type), uc_fw->path,
+                          intel_uc_fw_is_overridden(uc_fw) ?
+                          "ignoring unexpected version" : "wrong version",
                           uc_fw->major_ver_found, uc_fw->minor_ver_found,
uc_fw->major_ver_wanted, uc_fw->minor_ver_wanted);
                if (!intel_uc_fw_is_overridden(uc_fw)) {

Michal
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux