Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Gustavo Sousa <gustavo.sousa@intel.com>
To: "Nautiyal, Ankit K" <ankit.k.nautiyal@intel.com>,
	Jani Nikula <jani.nikula@linux.intel.com>,
	<intel-gfx@lists.freedesktop.org>,
	<intel-xe@lists.freedesktop.org>
Subject: Re: [PATCH] drm/i915/gmbus: Add Wa_16025573575 for PTL for bit-bashing
Date: Fri, 13 Jun 2025 07:23:37 -0300	[thread overview]
Message-ID: <174981021705.14553.10495600609368679486@intel.com> (raw)
In-Reply-To: <7f079861f91861e9e895240cd3272f6e29deab7e@intel.com>

Quoting Jani Nikula (2025-06-13 06:13:55-03:00)
>On Fri, 13 Jun 2025, "Nautiyal, Ankit K" <ankit.k.nautiyal@intel.com> wrote:
>> On 6/12/2025 5:30 PM, Gustavo Sousa wrote:
>>> Instead of open-coding the conditions for the workaround in three
>>> different places in the file, I think we should have a function
>>> needs_wa_16025573575() and use it.
>>>
>>> Also, note that the workaround is also required for WCL (display version
>>> 30.02), and we would then include that in needs_wa_16025573575().
>>
>> I agree, will make a separate function needs_wa_16025573575().
>>
>> Thanks for the suggestions. I will make suggested changes in next revision.
>
>Please let's aim for something a little more generic and unified than
>that, and one that can be easily extended and switched to a generated
>version in the future.
>
>intel_display_wa.h:
>
>enum intel_display_wa {
>        INTEL_DISPLAY_WA_16025573575,
>};
>
>bool __intel_display_wa(struct intel_display *display, enum intel_display_wa wa);
>
>#define intel_display_wa(__display, __wa) __intel_display_wa((__display), INTEL_DISPLAY_WA_ ## __wa)
>
>In code you'd use:
>
>        if (intel_display_wa(display, 16025573575))

Yep. Sounds good.

>
>For now, you'd manually check for each enum in __intel_display_wa()
>implementation, but in the future that code could be generated similar
>to what xe currently has. I'm just not very enthusiastic about adding C
>language hostprogs with custom .rules files and parsing.

Hehe. Yeah. I'm wondering if something nice could be achieved with
header files and cpp magic...

--
Gustavo Sousa

  reply	other threads:[~2025-06-13 10:24 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-12  7:53 [PATCH] drm/i915/gmbus: Add Wa_16025573575 for PTL for bit-bashing Ankit Nautiyal
2025-06-12  9:05 ` ✓ CI.checkpatch: success for " Patchwork
2025-06-12  9:06 ` ✓ CI.KUnit: " Patchwork
2025-06-12  9:17 ` ✓ CI.Build: " Patchwork
2025-06-12  9:58 ` ✓ Xe.CI.BAT: " Patchwork
2025-06-12 12:00 ` [PATCH] " Gustavo Sousa
2025-06-13  6:15   ` Nautiyal, Ankit K
2025-06-13  9:13     ` Jani Nikula
2025-06-13 10:23       ` Gustavo Sousa [this message]
2025-06-13 10:38         ` Jani Nikula
2025-06-15 15:17       ` Nautiyal, Ankit K
2025-06-12 21:08 ` ✗ Xe.CI.Full: failure for " 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=174981021705.14553.10495600609368679486@intel.com \
    --to=gustavo.sousa@intel.com \
    --cc=ankit.k.nautiyal@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=jani.nikula@linux.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