All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/doc: Document KUnit expectations
@ 2025-01-13 10:11 Maxime Ripard
  2025-01-13 10:50 ` Jani Nikula
                   ` (4 more replies)
  0 siblings, 5 replies; 7+ messages in thread
From: Maxime Ripard @ 2025-01-13 10:11 UTC (permalink / raw)
  To: Jonathan Corbet, Simona Vetter, David Airlie
  Cc: Maarten Lankhorst, Thomas Zimmermann, Maxime Ripard, dri-devel,
	Jani Nikula

The DRM and KMS frameworks and helpers gain more and more kunit
coverage, so let's document what our expectations are.

Suggested-by: Jani Nikula <jani.nikula@intel.com>
Signed-off-by: Maxime Ripard <mripard@kernel.org>

---

I'm not too sure where those guidelines should be placed. Is it the best
place?
---
 Documentation/gpu/drm-internals.rst | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/Documentation/gpu/drm-internals.rst b/Documentation/gpu/drm-internals.rst
index cb9ae282771c..94f93fd3b8a0 100644
--- a/Documentation/gpu/drm-internals.rst
+++ b/Documentation/gpu/drm-internals.rst
@@ -206,10 +206,17 @@ follows:
 	The configuration included in ``.kunitconfig`` should be as generic as
 	possible.
 	``CONFIG_VIRTIO_UML`` and ``CONFIG_UML_PCI_OVER_VIRTIO`` are not
 	included in it because they are only required for User Mode Linux.
 
+KUnit Coverage Rules
+~~~~~~~~~~~~~~~~~~~~
+
+KUnit support is gradually added to the DRM framework and helpers. There's no
+general requirement for the framework and helpers to have KUnit tests at the
+moment. However, patches that are affecting a function or helper already
+covered by KUnit tests must provide tests if the change calls for one.
 
 Legacy Support Code
 ===================
 
 The section very briefly covers some of the old legacy support code
-- 
2.47.1


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/doc: Document KUnit expectations
  2025-01-13 10:11 [PATCH] drm/doc: Document KUnit expectations Maxime Ripard
@ 2025-01-13 10:50 ` Jani Nikula
  2025-02-19  9:06 ` Javier Martinez Canillas
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 7+ messages in thread
From: Jani Nikula @ 2025-01-13 10:50 UTC (permalink / raw)
  To: Maxime Ripard, Jonathan Corbet, Simona Vetter, David Airlie
  Cc: Maarten Lankhorst, Thomas Zimmermann, Maxime Ripard, dri-devel

On Mon, 13 Jan 2025, Maxime Ripard <mripard@kernel.org> wrote:
> The DRM and KMS frameworks and helpers gain more and more kunit
> coverage, so let's document what our expectations are.
>
> Suggested-by: Jani Nikula <jani.nikula@intel.com>
> Signed-off-by: Maxime Ripard <mripard@kernel.org>

Seems fair.

Acked-by: Jani Nikula <jani.nikula@intel.com>

---

On a related note, I was recently pinged again about the framebuffer
kunit tests causing warning backtraces on successful runs. I don't know
what to tell people, we kind of ended at an impasse [1]. Most tests
don't emit warnings, some do, and I'm still as reluctant as ever to
recommend folks to ignore warnings when running tests. We can agree to
disagree, but it doesn't really move things forward.

BR,
Jani.


[1] https://lore.kernel.org/r/cover.1726594684.git.jani.nikula@intel.com



>
> ---
>
> I'm not too sure where those guidelines should be placed. Is it the best
> place?
> ---
>  Documentation/gpu/drm-internals.rst | 7 +++++++
>  1 file changed, 7 insertions(+)
>
> diff --git a/Documentation/gpu/drm-internals.rst b/Documentation/gpu/drm-internals.rst
> index cb9ae282771c..94f93fd3b8a0 100644
> --- a/Documentation/gpu/drm-internals.rst
> +++ b/Documentation/gpu/drm-internals.rst
> @@ -206,10 +206,17 @@ follows:
>  	The configuration included in ``.kunitconfig`` should be as generic as
>  	possible.
>  	``CONFIG_VIRTIO_UML`` and ``CONFIG_UML_PCI_OVER_VIRTIO`` are not
>  	included in it because they are only required for User Mode Linux.
>  
> +KUnit Coverage Rules
> +~~~~~~~~~~~~~~~~~~~~
> +
> +KUnit support is gradually added to the DRM framework and helpers. There's no
> +general requirement for the framework and helpers to have KUnit tests at the
> +moment. However, patches that are affecting a function or helper already
> +covered by KUnit tests must provide tests if the change calls for one.
>  
>  Legacy Support Code
>  ===================
>  
>  The section very briefly covers some of the old legacy support code

-- 
Jani Nikula, Intel

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/doc: Document KUnit expectations
  2025-01-13 10:11 [PATCH] drm/doc: Document KUnit expectations Maxime Ripard
  2025-01-13 10:50 ` Jani Nikula
@ 2025-02-19  9:06 ` Javier Martinez Canillas
  2025-02-19 13:24   ` Simona Vetter
  2025-02-26 12:53 ` Tvrtko Ursulin
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 7+ messages in thread
From: Javier Martinez Canillas @ 2025-02-19  9:06 UTC (permalink / raw)
  To: Maxime Ripard, Jonathan Corbet, Simona Vetter, David Airlie
  Cc: Maarten Lankhorst, Thomas Zimmermann, Maxime Ripard, dri-devel,
	Jani Nikula

Maxime Ripard <mripard@kernel.org> writes:

> The DRM and KMS frameworks and helpers gain more and more kunit
> coverage, so let's document what our expectations are.
>
> Suggested-by: Jani Nikula <jani.nikula@intel.com>
> Signed-off-by: Maxime Ripard <mripard@kernel.org>
>
> ---
>

Seems a reasonable expection to me.

Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>

-- 
Best regards,

Javier Martinez Canillas
Core Platforms
Red Hat


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/doc: Document KUnit expectations
  2025-02-19  9:06 ` Javier Martinez Canillas
@ 2025-02-19 13:24   ` Simona Vetter
  0 siblings, 0 replies; 7+ messages in thread
From: Simona Vetter @ 2025-02-19 13:24 UTC (permalink / raw)
  To: Javier Martinez Canillas
  Cc: Maxime Ripard, Jonathan Corbet, Simona Vetter, David Airlie,
	Maarten Lankhorst, Thomas Zimmermann, dri-devel, Jani Nikula

On Wed, Feb 19, 2025 at 10:06:59AM +0100, Javier Martinez Canillas wrote:
> Maxime Ripard <mripard@kernel.org> writes:
> 
> > The DRM and KMS frameworks and helpers gain more and more kunit
> > coverage, so let's document what our expectations are.
> >
> > Suggested-by: Jani Nikula <jani.nikula@intel.com>
> > Signed-off-by: Maxime Ripard <mripard@kernel.org>
> >
> > ---
> >
> 
> Seems a reasonable expection to me.
> 
> Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>

Acked-by: Simona Vetter <simona.vetter@ffwll.ch>

I think some more acks from folks working on Kunit tests would be great,
but that aside I think this accurately summarizes the discussion we had a
while back.
-Sima
-- 
Simona Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/doc: Document KUnit expectations
  2025-01-13 10:11 [PATCH] drm/doc: Document KUnit expectations Maxime Ripard
  2025-01-13 10:50 ` Jani Nikula
  2025-02-19  9:06 ` Javier Martinez Canillas
@ 2025-02-26 12:53 ` Tvrtko Ursulin
  2025-02-26 14:52 ` Maíra Canal
  2025-02-26 15:34 ` Maxime Ripard
  4 siblings, 0 replies; 7+ messages in thread
From: Tvrtko Ursulin @ 2025-02-26 12:53 UTC (permalink / raw)
  To: Maxime Ripard, Jonathan Corbet, Simona Vetter, David Airlie
  Cc: Maarten Lankhorst, Thomas Zimmermann, dri-devel, Jani Nikula


On 13/01/2025 10:11, Maxime Ripard wrote:
> The DRM and KMS frameworks and helpers gain more and more kunit
> coverage, so let's document what our expectations are.
> 
> Suggested-by: Jani Nikula <jani.nikula@intel.com>
> Signed-off-by: Maxime Ripard <mripard@kernel.org>
> 
> ---
> 
> I'm not too sure where those guidelines should be placed. Is it the best
> place?
> ---
>   Documentation/gpu/drm-internals.rst | 7 +++++++
>   1 file changed, 7 insertions(+)
> 
> diff --git a/Documentation/gpu/drm-internals.rst b/Documentation/gpu/drm-internals.rst
> index cb9ae282771c..94f93fd3b8a0 100644
> --- a/Documentation/gpu/drm-internals.rst
> +++ b/Documentation/gpu/drm-internals.rst
> @@ -206,10 +206,17 @@ follows:
>   	The configuration included in ``.kunitconfig`` should be as generic as
>   	possible.
>   	``CONFIG_VIRTIO_UML`` and ``CONFIG_UML_PCI_OVER_VIRTIO`` are not
>   	included in it because they are only required for User Mode Linux.
>   
> +KUnit Coverage Rules
> +~~~~~~~~~~~~~~~~~~~~
> +
> +KUnit support is gradually added to the DRM framework and helpers. There's no
> +general requirement for the framework and helpers to have KUnit tests at the
> +moment. However, patches that are affecting a function or helper already
> +covered by KUnit tests must provide tests if the change calls for one.
>   
>   Legacy Support Code
>   ===================
>   
>   The section very briefly covers some of the old legacy support code

Acked-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>

Regards,

Tvrtko


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/doc: Document KUnit expectations
  2025-01-13 10:11 [PATCH] drm/doc: Document KUnit expectations Maxime Ripard
                   ` (2 preceding siblings ...)
  2025-02-26 12:53 ` Tvrtko Ursulin
@ 2025-02-26 14:52 ` Maíra Canal
  2025-02-26 15:34 ` Maxime Ripard
  4 siblings, 0 replies; 7+ messages in thread
From: Maíra Canal @ 2025-02-26 14:52 UTC (permalink / raw)
  To: Maxime Ripard, Jonathan Corbet, Simona Vetter, David Airlie
  Cc: Maarten Lankhorst, Thomas Zimmermann, dri-devel, Jani Nikula

Hi Maxime,

On 13/01/25 07:11, Maxime Ripard wrote:
> The DRM and KMS frameworks and helpers gain more and more kunit
> coverage, so let's document what our expectations are.
> 
> Suggested-by: Jani Nikula <jani.nikula@intel.com>
> Signed-off-by: Maxime Ripard <mripard@kernel.org>
> 
> ---
> 
> I'm not too sure where those guidelines should be placed. Is it the best
> place?
> ---
>   Documentation/gpu/drm-internals.rst | 7 +++++++
>   1 file changed, 7 insertions(+)
> 
> diff --git a/Documentation/gpu/drm-internals.rst b/Documentation/gpu/drm-internals.rst
> index cb9ae282771c..94f93fd3b8a0 100644
> --- a/Documentation/gpu/drm-internals.rst
> +++ b/Documentation/gpu/drm-internals.rst
> @@ -206,10 +206,17 @@ follows:
>   	The configuration included in ``.kunitconfig`` should be as generic as
>   	possible.
>   	``CONFIG_VIRTIO_UML`` and ``CONFIG_UML_PCI_OVER_VIRTIO`` are not
>   	included in it because they are only required for User Mode Linux.
>   
> +KUnit Coverage Rules
> +~~~~~~~~~~~~~~~~~~~~
> +
> +KUnit support is gradually added to the DRM framework and helpers. There's no
> +general requirement for the framework and helpers to have KUnit tests at the
> +moment. However, patches that are affecting a function or helper already
> +covered by KUnit tests must provide tests if the change calls for one.
>   

Acked-by: Maíra Canal <mcanal@igalia.com>

Best Regards,
- Maíra

>   Legacy Support Code
>   ===================
>   
>   The section very briefly covers some of the old legacy support code


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/doc: Document KUnit expectations
  2025-01-13 10:11 [PATCH] drm/doc: Document KUnit expectations Maxime Ripard
                   ` (3 preceding siblings ...)
  2025-02-26 14:52 ` Maíra Canal
@ 2025-02-26 15:34 ` Maxime Ripard
  4 siblings, 0 replies; 7+ messages in thread
From: Maxime Ripard @ 2025-02-26 15:34 UTC (permalink / raw)
  To: Jonathan Corbet, Simona Vetter, David Airlie, Maxime Ripard
  Cc: Maarten Lankhorst, Thomas Zimmermann, dri-devel, Jani Nikula

On Mon, 13 Jan 2025 11:11:00 +0100, Maxime Ripard wrote:
> The DRM and KMS frameworks and helpers gain more and more kunit
> coverage, so let's document what our expectations are.
> 
> 

Applied to misc/kernel.git (drm-misc-next).

Thanks!
Maxime

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2025-02-26 15:34 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-01-13 10:11 [PATCH] drm/doc: Document KUnit expectations Maxime Ripard
2025-01-13 10:50 ` Jani Nikula
2025-02-19  9:06 ` Javier Martinez Canillas
2025-02-19 13:24   ` Simona Vetter
2025-02-26 12:53 ` Tvrtko Ursulin
2025-02-26 14:52 ` Maíra Canal
2025-02-26 15:34 ` Maxime Ripard

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.