From: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
To: John Harrison <john.c.harrison@intel.com>,
<Intel-GFX@Lists.FreeDesktop.Org>
Cc: <DRI-Devel@Lists.FreeDesktop.Org>
Subject: Re: [PATCH] drm/i915: Add debug print about hw config table size
Date: Tue, 24 Dec 2024 11:10:04 -0800 [thread overview]
Message-ID: <5c2c8e5c-c16d-41c1-90e7-07b1ddf0f923@intel.com> (raw)
In-Reply-To: <16414d38-e5ae-4bc5-9b22-a2a7a928264b@intel.com>
[-- Attachment #1: Type: text/plain, Size: 2804 bytes --]
On 12/24/2024 10:13 AM, John Harrison wrote:
> On 12/23/2024 15:20, Daniele Ceraolo Spurio wrote:
>> On 12/20/2024 5:19 PM, John.C.Harrison@Intel.com wrote:
>>> From: John Harrison<John.C.Harrison@Intel.com>
>>>
>>> Add debug info to help investigate a very rare bug:
>>> https://gitlab.freedesktop.org/drm/i915/kernel/-/issues/13385
>>>
>>> Signed-off-by: John Harrison<John.C.Harrison@Intel.com>
>>> ---
>>> drivers/gpu/drm/i915/gt/uc/intel_guc_hwconfig.c | 3 +++
>>> 1 file changed, 3 insertions(+)
>>>
>>> diff --git a/drivers/gpu/drm/i915/gt/uc/intel_guc_hwconfig.c b/drivers/gpu/drm/i915/gt/uc/intel_guc_hwconfig.c
>>> index b67a15f742762..868195c33f5b3 100644
>>> --- a/drivers/gpu/drm/i915/gt/uc/intel_guc_hwconfig.c
>>> +++ b/drivers/gpu/drm/i915/gt/uc/intel_guc_hwconfig.c
>>> @@ -7,6 +7,7 @@
>>> #include "gt/intel_hwconfig.h"
>>> #include "i915_drv.h"
>>> #include "i915_memcpy.h"
>>> +#include "intel_guc_print.h"
>>>
>>> /*
>>> * GuC has a blob containing hardware configuration information (HWConfig).
>>> @@ -42,6 +43,8 @@ static int __guc_action_get_hwconfig(struct intel_guc *guc,
>>> };
>>> int ret;
>>>
>>> + guc_dbg(guc, "Querying HW config table: size = %d, offset = 0x%08X\n",
>>> + ggtt_size, ggtt_offset);
>>
>> This seems to result in a double-log where the first print has no
>> useful information, e.g.:
>>
>> [drm:__guc_action_get_hwconfig [i915]] GT0: GUC: Querying HW config
>> table: size = 0, offset = 0x00000000
>> [drm:__guc_action_get_hwconfig [i915]] GT0: GUC: Querying HW config
>> table: size = 752, offset = 0x00D05000
>>
>> Given that only the second log is useful, IMO better to move the
>> guc_dbg to guc_hwconfig_fill_buffer(), because the info needed for
>> the second print is available there and it is only called once.
> I disagree that the first print has no useful information. It tells us
> that a call is being made and these are the parameters. We do not know
> what the failure is. It seems highly unlikely that the size changes
> from query to the next given that the table is a fixed entity. It is
> much more likely to be a caching type issue with GuC reading data the
> KMD did not write. If so, GuC could potentially read non-zero data for
> the initial size query and complain that data is invalid.
>
> The intention is to report all calls with their parameters to try to
> narrow down exactly what calls are not working.
But we don't need both prints to know which of the 2 calls has failed,
if the error comes before we get the second print then we know the
failure was in the first call, otherwise it was in the second.
Daniele
>
> John.
>
>
>>
>> Daniele
>>
>>> ret = intel_guc_send_mmio(guc, action, ARRAY_SIZE(action), NULL, 0);
>>> if (ret == -ENXIO)
>>> return -ENOENT;
>>
>
[-- Attachment #2: Type: text/html, Size: 5760 bytes --]
next prev parent reply other threads:[~2024-12-24 19:10 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-21 1:19 [PATCH] drm/i915: Add debug print about hw config table size John.C.Harrison
2024-12-21 2:29 ` ✗ i915.CI.BAT: failure for " Patchwork
2024-12-23 23:20 ` [PATCH] " Daniele Ceraolo Spurio
2024-12-24 18:13 ` John Harrison
2024-12-24 19:10 ` Daniele Ceraolo Spurio [this message]
2025-01-07 1:15 ` John Harrison
2025-01-13 19:48 ` Julia Filipchuk
2025-01-15 0:22 ` ✓ i915.CI.BAT: success for drm/i915: Add debug print about hw config table size (rev2) Patchwork
2025-01-15 17:11 ` ✗ i915.CI.Full: failure " Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5c2c8e5c-c16d-41c1-90e7-07b1ddf0f923@intel.com \
--to=daniele.ceraolospurio@intel.com \
--cc=DRI-Devel@Lists.FreeDesktop.Org \
--cc=Intel-GFX@Lists.FreeDesktop.Org \
--cc=john.c.harrison@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox