lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5z66ivuhfrzrnuzt6lwjfm5fuozxlgqsco3qb5rfzyf6mil5ms@2svqtlcncyjj>
Date: Mon, 8 Jan 2024 11:15:29 +0100
From: Maxime Ripard <mripard@...nel.org>
To: Arthur Grillo <arthurgrillo@...eup.net>
Cc: Daniel Vetter <daniel@...ll.ch>, David Airlie <airlied@...il.com>, 
	Haneen Mohammed <hamohammed.sa@...il.com>, Harry Wentland <harry.wentland@....com>, 
	Jonathan Corbet <corbet@....net>, Maarten Lankhorst <maarten.lankhorst@...ux.intel.com>, 
	MaĆ­ra Canal <mairacanal@...eup.net>, Melissa Wen <melissa.srw@...il.com>, 
	Rodrigo Siqueira <rodrigosiqueiramelo@...il.com>, Thomas Zimmermann <tzimmermann@...e.de>, 
	dri-devel@...ts.freedesktop.org, linux-kernel@...r.kernel.org, linux-doc@...r.kernel.org
Subject: Re: [PATCH 7/7] drm/vkms: Create KUnit tests for YUV conversions

Hi Arthur,

On Fri, Jan 05, 2024 at 01:35:08PM -0300, Arthur Grillo wrote:
> diff --git a/drivers/gpu/drm/vkms/vkms_formats.c b/drivers/gpu/drm/vkms/vkms_formats.c
> index b654b6661a20..11df990a0fa9 100644
> --- a/drivers/gpu/drm/vkms/vkms_formats.c
> +++ b/drivers/gpu/drm/vkms/vkms_formats.c
> @@ -440,3 +440,7 @@ void *get_pixel_write_function(u32 format)
>  		return NULL;
>  	}
>  }
> +
> +#ifdef CONFIG_DRM_VKMS_KUNIT_TESTS
> +#include "tests/vkms_format_test.c"
> +#endif

I assume this is due to testing a static function?

If so, the preferred way nowadays is to use EXPORT_SYMBOL_IF_KUNIT or
EXPORT_SYMBOL_FOR_TESTS_ONLY if it's DRM/KMS only.

Maxime

Download attachment "signature.asc" of type "application/pgp-signature" (229 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ