From: Louis Chauvet <louis.chauvet@bootlin.com>
To: "Rodrigo Siqueira" <rodrigosiqueiramelo@gmail.com>,
"Melissa Wen" <melissa.srw@gmail.com>,
"Maíra Canal" <mairacanal@riseup.net>,
"Haneen Mohammed" <hamohammed.sa@gmail.com>,
"Daniel Vetter" <daniel@ffwll.ch>,
"Maarten Lankhorst" <maarten.lankhorst@linux.intel.com>,
"Maxime Ripard" <mripard@kernel.org>,
"Thomas Zimmermann" <tzimmermann@suse.de>,
"David Airlie" <airlied@gmail.com>
Cc: dri-devel@lists.freedesktop.org, arthurgrillo@riseup.net,
linux-kernel@vger.kernel.org, jeremie.dautheribes@bootlin.com,
miquel.raynal@bootlin.com, thomas.petazzoni@bootlin.com,
seanpaul@google.com, marcheu@google.com,
nicolejadeyee@google.com,
Louis Chauvet <louis.chauvet@bootlin.com>
Subject: [PATCH RFC 4/6] drm/vkms: Rename to_vkms_plane_state to avoid confusion
Date: Wed, 14 Aug 2024 11:08:57 +0200 [thread overview]
Message-ID: <20240814-google-split-headers-v1-4-51712f088f5d@bootlin.com> (raw)
In-Reply-To: <20240814-google-split-headers-v1-0-51712f088f5d@bootlin.com>
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@bootlin.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
--
2.44.2
next prev parent reply other threads:[~2024-08-14 9:09 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-14 9:08 [PATCH RFC 0/6] drm/vkms: Completly split headers Louis Chauvet
2024-08-14 9:08 ` [PATCH RFC 1/6] drm/vkms: Properly extract vkms_formats header Louis Chauvet
2024-08-15 14:36 ` Maíra Canal
2024-08-20 15:28 ` José Expósito
2024-08-14 9:08 ` [PATCH RFC 2/6] drm/vkms: Extract vkms_writeback header Louis Chauvet
2024-08-20 15:28 ` José Expósito
2024-08-14 9:08 ` [PATCH RFC 3/6] drm/vkms: Extract vkms_plane header Louis Chauvet
2024-08-20 15:28 ` José Expósito
2024-08-14 9:08 ` Louis Chauvet [this message]
2024-08-20 15:29 ` [PATCH RFC 4/6] drm/vkms: Rename to_vkms_plane_state to avoid confusion José Expósito
2024-08-14 9:08 ` [PATCH RFC 5/6] drm/vkms: Extract vkms_crtc header Louis Chauvet
2024-08-20 15:29 ` José Expósito
2024-08-14 9:08 ` [PATCH RFC 6/6] drm/vkms: Extract vkms_composer header Louis Chauvet
2024-08-20 15:30 ` José Expósito
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=20240814-google-split-headers-v1-4-51712f088f5d@bootlin.com \
--to=louis.chauvet@bootlin.com \
--cc=airlied@gmail.com \
--cc=arthurgrillo@riseup.net \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=hamohammed.sa@gmail.com \
--cc=jeremie.dautheribes@bootlin.com \
--cc=linux-kernel@vger.kernel.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mairacanal@riseup.net \
--cc=marcheu@google.com \
--cc=melissa.srw@gmail.com \
--cc=miquel.raynal@bootlin.com \
--cc=mripard@kernel.org \
--cc=nicolejadeyee@google.com \
--cc=rodrigosiqueiramelo@gmail.com \
--cc=seanpaul@google.com \
--cc=thomas.petazzoni@bootlin.com \
--cc=tzimmermann@suse.de \
/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
all inboxes | Powered by JetHome®