[PATCH v3 04/33] drm/vkms: Use enabled/disabled instead of 1/0 for debug

Louis Chauvet
2025-12-22T10:11:23Z

Debug information are mainly read by human, so display human
readable values.

Reviewed-by: José Expósito <jose.exposito@redhat.com>
Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Signed-off-by: Louis Chauvet <louis.chauvet@bootlin.com>
---
drivers/gpu/drm/vkms/vkms_config.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/vkms/vkms_config.c b/drivers/gpu/drm/vkms/vkms_config.c
index ec0001adc4d1..233e7ad4d45b 100644
--- a/drivers/gpu/drm/vkms/vkms_config.c
+++ b/drivers/gpu/drm/vkms/vkms_config.c
@@ -1,6 +1,7 @@
// SPDX-License-Identifier: GPL-2.0+

#include <linux/slab.h>
+#include <linux/string_choices.h>

#include <drm/drm_print.h>
#include <drm/drm_debugfs.h>
@@ -358,8 +359,8 @@ static int vkms_config_show(struct seq_file *m, void *data)

vkms_config_for_each_crtc(vkmsdev->config, crtc_cfg) {
seq_puts(m, "crtc:\n");
- seq_printf(m, "\twriteback=%d\n",
- vkms_config_crtc_get_writeback(crtc_cfg));
+ seq_printf(m, "\twriteback=%s\n",
+ str_enabled_disabled(vkms_config_crtc_get_writeback(crtc_cfg)));
}

vkms_config_for_each_encoder(vkmsdev->config, encoder_cfg)

--
2.51.2