[PATCH v6 19/43] drm/vkms: Use plane folder name as plane name

From: Louis Chauvet

Date: Fri Nov 20 2026 - 13:05:17 EST


The plane name is now directly derived from the configfs folder
name. When a plane directory is created under
/config/vkms/<device>/planes/, the folder name is used as the
plane name via vkms_config_plane_set_name.

Signed-off-by: Louis Chauvet <louis.chauvet@xxxxxxxxxxx>
---
Documentation/ABI/testing/configfs-vkms | 3 ++-
drivers/gpu/drm/vkms/vkms_configfs.c | 6 ++++++
2 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/Documentation/ABI/testing/configfs-vkms b/Documentation/ABI/testing/configfs-vkms
index 26e7f81b5b7d..55e4183046ec 100644
--- a/Documentation/ABI/testing/configfs-vkms
+++ b/Documentation/ABI/testing/configfs-vkms
@@ -98,7 +98,8 @@ Date: Nov 2025
Contact: dri-devel@xxxxxxxxxxxxxxxxxxxxx
Description:
This group contains attributes corresponding to the
- plane <plane> of the VKMS device <device>.
+ plane <plane> of the VKMS device <device>. The name of
+ the directory becomes the name of the DRM plane.

What: /sys/kernel/config/vkms/<device>/planes/<plane>/type
Date: Nov 2025
diff --git a/drivers/gpu/drm/vkms/vkms_configfs.c b/drivers/gpu/drm/vkms/vkms_configfs.c
index a7ddcfd4e86e..3a1a34643cce 100644
--- a/drivers/gpu/drm/vkms/vkms_configfs.c
+++ b/drivers/gpu/drm/vkms/vkms_configfs.c
@@ -375,6 +375,12 @@ static struct config_group *make_plane_group(struct config_group *group,
return ERR_PTR(ret);
}

+ ret = vkms_config_plane_set_name(plane->config, name, strlen(name));
+ if (ret) {
+ vkms_config_destroy_plane(plane->config);
+ return ERR_PTR(ret);
+ }
+
config_group_init_type_name(&plane->group, name, &plane_item_type);

config_group_init_type_name(&plane->possible_crtcs_group,

--
2.56.0