From: Gustavo Sousa <gustavo.sousa@intel.com>
To: Jani Nikula <jani.nikula@linux.intel.com>,
<intel-xe@lists.freedesktop.org>
Cc: "Michal Wajdeczko" <michal.wajdeczko@intel.com>,
"Matthew Brost" <matthew.brost@intel.com>,
"Thomas Hellström" <thomas.hellstrom@linux.intel.com>,
"Rodrigo Vivi" <rodrigo.vivi@intel.com>
Subject: Re: [PATCH v2 4/8] drm/xe/kunit: Add xe_kunit_helper_is_live_test()
Date: Mon, 11 May 2026 09:30:49 -0300 [thread overview]
Message-ID: <87qzniqgau.fsf@intel.com> (raw)
In-Reply-To: <619ba2cfdac33128f92c4f83b8573770146cead8@intel.com>
Jani Nikula <jani.nikula@linux.intel.com> writes:
> On Mon, 11 May 2026, Gustavo Sousa <gustavo.sousa@intel.com> wrote:
>> Jani Nikula <jani.nikula@linux.intel.com> writes:
>>
>>> On Fri, 08 May 2026, Gustavo Sousa <gustavo.sousa@intel.com> wrote:
>>>> +/**
>>>> + * xe_kunit_helper_is_live_test - Return true if @test is a live test.
>>>> + * @test: the &kunit test
>>>> + *
>>>> + * Return: True for a live test and false otherwise.
>>>> + */
>>>
>>> Pardon me for being blunt, but I think this is the worst kind of
>>> kernel-doc comment.
>>
>> I appreciate the bluntness! :-)
>>
>>>
>>> It doesn't provide any additional information to what the function name
>>> and signature already convey (which is to say excellent job on naming
>>> the function), but it fails to explain what "live test" means.
>>
>> I kind of just added this kernel-doc to fill a hole for "consistency",
>> but, yeah, it does not provide any new info.
>>
>>>
>>> The extra bits of useful information people might need after seeing the
>>> function xe_kunit_helper_is_live_test() in code are: What is a live
>>> test, and what is it if it's not live? Dead?
>>
>> Zombie? ;-)
>>
>> Joking apart, I personally tend to use "regular" to refer to non-live
>> tests. I do agree we are missing some documentation on the subject. I'm
>> not sure though this function should be the place to do it. I think we
>> would be better off with a "DOC:" section for that (and also explain
>> other bits in there). I think it would be sensible to rename
>> xe_kunit_helpers.c to simply xe_kunit.c and add such a section.
>>
>> With that in place, this function would be kind of self-explanatory,
>> right? Is this a case we just drop the kernel-doc?
>>
>> Or should we try to be consistent on "every public function should have
>> a kernel-doc"? Is that even a rule or am I imagining things? :-)
>
> I believe xe maintainership leans more towards requiring kernel-doc
> comments than we do with i915 or display. I think the hard requirement
> leads to a lot of unnecessary boilerplate, more geared towards filling
> the requirement than being informative and helpful.
>
> Personally, I value overview DOC: comments much more than kernel-doc
> comments. If I were to add any hard requirement for documentation, it
> would be for DOC: comments for each .c file.
>
> Bottom line, for xe, ask for xe maintainer opinion.
Cc:Xe maintainers, in case they want to chime in.
--
Gustavo Sousa
>
>
> BR,
> Jani.
>
>>
>> --
>> Gustavo Sousa
>>
>>>
>>>
>>> BR,
>>> Jani.
>>>
>>>> +bool xe_kunit_helper_is_live_test(struct kunit *test)
>>>> +{
>>>> + KUNIT_STATIC_STUB_REDIRECT(xe_kunit_helper_is_live_test, test);
>>>> + return false;
>>>> +}
>>>
>>> --
>>> Jani Nikula, Intel
>
> --
> Jani Nikula, Intel
next prev parent reply other threads:[~2026-05-11 12:31 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-08 21:42 [PATCH v2 0/8] Fix MCR inconsistencies in RTP tables Gustavo Sousa
2026-05-08 21:42 ` [PATCH v2 1/8] drm/xe: Define CACHE_MODE_1 as MCR register Gustavo Sousa
2026-05-08 21:42 ` [PATCH v2 2/8] drm/xe: Define and use MCR version of COMMON_SLICE_CHICKEN1 Gustavo Sousa
2026-05-08 21:42 ` [PATCH v2 3/8] drm/xe: Define and use MCR version of COMMON_SLICE_CHICKEN4 Gustavo Sousa
2026-05-13 22:35 ` Matt Roper
2026-05-08 21:42 ` [PATCH v2 4/8] drm/xe/kunit: Add xe_kunit_helper_is_live_test() Gustavo Sousa
2026-05-11 10:37 ` Jani Nikula
2026-05-11 11:45 ` Gustavo Sousa
2026-05-11 12:03 ` Jani Nikula
2026-05-11 12:30 ` Gustavo Sousa [this message]
2026-05-11 20:33 ` Rodrigo Vivi
2026-05-11 21:01 ` Gustavo Sousa
2026-05-12 19:00 ` Rodrigo Vivi
2026-05-12 19:26 ` Michal Wajdeczko
2026-05-13 13:03 ` Gustavo Sousa
2026-05-13 12:58 ` Gustavo Sousa
2026-05-08 21:42 ` [PATCH v2 5/8] drm/xe: Extract xe_hw_engine_setup_reg_lrc() Gustavo Sousa
2026-05-08 21:42 ` [PATCH v2 6/8] drm/xe/kunit: Use KUNIT_EXPECT_EQ() in xe_wa_gt() Gustavo Sousa
2026-05-08 21:42 ` [PATCH v2 7/8] drm/xe/mcr: Extract reg_in_steering_type_ranges() Gustavo Sousa
2026-05-08 21:42 ` [PATCH v2 8/8] drm/xe/reg_sr: Do sanity check for MCR vs non-MCR Gustavo Sousa
2026-05-13 22:49 ` Matt Roper
2026-05-08 21:50 ` ✓ CI.KUnit: success for Fix MCR inconsistencies in RTP tables (rev2) Patchwork
2026-05-08 23:04 ` ✓ Xe.CI.BAT: " Patchwork
2026-05-09 10:54 ` ✗ Xe.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=87qzniqgau.fsf@intel.com \
--to=gustavo.sousa@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=jani.nikula@linux.intel.com \
--cc=matthew.brost@intel.com \
--cc=michal.wajdeczko@intel.com \
--cc=rodrigo.vivi@intel.com \
--cc=thomas.hellstrom@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