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: <20240820152919.2863-1-jose.exposito89@gmail.com>
Date: Tue, 20 Aug 2024 17:29:18 +0200
From: José Expósito <jose.exposito89@...il.com>
To: louis.chauvet@...tlin.com
Cc: airlied@...il.com,
	arthurgrillo@...eup.net,
	daniel@...ll.ch,
	dri-devel@...ts.freedesktop.org,
	hamohammed.sa@...il.com,
	jeremie.dautheribes@...tlin.com,
	linux-kernel@...r.kernel.org,
	maarten.lankhorst@...ux.intel.com,
	mairacanal@...eup.net,
	marcheu@...gle.com,
	melissa.srw@...il.com,
	miquel.raynal@...tlin.com,
	mripard@...nel.org,
	nicolejadeyee@...gle.com,
	rodrigosiqueiramelo@...il.com,
	seanpaul@...gle.com,
	thomas.petazzoni@...tlin.com,
	tzimmermann@...e.de,
	José Expósito <jose.exposito89@...il.com>
Subject: [PATCH RFC 4/6] drm/vkms: Rename to_vkms_plane_state to avoid confusion

> The macro to_vkms_plane_state was not explicit about its expected content.
> Rename it to drm_plane_state_to_vkms_plane_state to avoid confusion and
> help the reader.
> 
> Signed-off-by: Louis Chauvet <louis.chauvet@...tlin.com>

Reviewed-by: José Expósito <jose.exposito89@...il.com>

> ---
>  drivers/gpu/drm/vkms/vkms_crtc.c  | 2 +-
>  drivers/gpu/drm/vkms/vkms_plane.c | 4 ++--
>  drivers/gpu/drm/vkms/vkms_plane.h | 2 +-
>  3 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/gpu/drm/vkms/vkms_crtc.c b/drivers/gpu/drm/vkms/vkms_crtc.c
> index 6a4de8f7a678..08e5db07aca6 100644
> --- a/drivers/gpu/drm/vkms/vkms_crtc.c
> +++ b/drivers/gpu/drm/vkms/vkms_crtc.c
> @@ -212,7 +212,7 @@ static int vkms_crtc_atomic_check(struct drm_crtc *crtc,
>  			continue;
>  
>  		vkms_state->active_planes[i++] =
> -			to_vkms_plane_state(plane_state);
> +			drm_plane_state_to_vkms_plane_state(plane_state);
>  	}
>  
>  	return 0;
> diff --git a/drivers/gpu/drm/vkms/vkms_plane.c b/drivers/gpu/drm/vkms/vkms_plane.c
> index de2c83e1b02c..e549c9523a34 100644
> --- a/drivers/gpu/drm/vkms/vkms_plane.c
> +++ b/drivers/gpu/drm/vkms/vkms_plane.c
> @@ -80,7 +80,7 @@ vkms_plane_duplicate_state(struct drm_plane *plane)
>  static void vkms_plane_destroy_state(struct drm_plane *plane,
>  				     struct drm_plane_state *old_state)
>  {
> -	struct vkms_plane_state *vkms_state = to_vkms_plane_state(old_state);
> +	struct vkms_plane_state *vkms_state = drm_plane_state_to_vkms_plane_state(old_state);
>  	struct drm_crtc *crtc = vkms_state->base.base.crtc;
>  
>  	if (crtc && vkms_state->frame_info->fb) {
> @@ -139,7 +139,7 @@ static void vkms_plane_atomic_update(struct drm_plane *plane,
>  		return;
>  
>  	fmt = fb->format->format;
> -	vkms_plane_state = to_vkms_plane_state(new_state);
> +	vkms_plane_state = drm_plane_state_to_vkms_plane_state(new_state);
>  	shadow_plane_state = &vkms_plane_state->base;
>  
>  	frame_info = vkms_plane_state->frame_info;
> diff --git a/drivers/gpu/drm/vkms/vkms_plane.h b/drivers/gpu/drm/vkms/vkms_plane.h
> index 161b44da0240..68170a75e9c9 100644
> --- a/drivers/gpu/drm/vkms/vkms_plane.h
> +++ b/drivers/gpu/drm/vkms/vkms_plane.h
> @@ -59,7 +59,7 @@ struct vkms_frame_info {
>  struct vkms_plane *vkms_plane_init(struct vkms_device *vkmsdev,
>  				   enum drm_plane_type type, int possible_crtc_index);
>  
> -#define to_vkms_plane_state(target)\
> +#define drm_plane_state_to_vkms_plane_state(target) \
>  	container_of(target, struct vkms_plane_state, base.base)
>  
>  #endif //_VKMS_PLANE_H
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ