From: liuqiangneo@163.com
To: maarten.lankhorst@linux.intel.com, mripard@kernel.org,
tzimmermann@suse.de, airlied@gmail.com, simona@ffwll.ch
Cc: linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org,
Qiang Liu <liuqiang@kylinos.cn>
Subject: [PATCH 1/2] drm/debugfs: Replace seq_printf with seq_puts for constant strings
Date: Fri, 20 Mar 2026 15:31:27 +0800 [thread overview]
Message-ID: <20260320073129.145575-2-liuqiangneo@163.com> (raw)
In-Reply-To: <20260320073129.145575-1-liuqiangneo@163.com>
From: Qiang Liu <liuqiang@kylinos.cn>
Replace seq_printf() with seq_puts() when printing constant strings
without format specifiers. This is more efficient as seq_puts()
doesn't need to parse the format string.
Signed-off-by: Qiang Liu <liuqiang@kylinos.cn>
---
drivers/gpu/drm/drm_debugfs.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/drm_debugfs.c b/drivers/gpu/drm/drm_debugfs.c
index ae1c6126c2c5..f9658bdf703e 100644
--- a/drivers/gpu/drm/drm_debugfs.c
+++ b/drivers/gpu/drm/drm_debugfs.c
@@ -66,7 +66,7 @@ static int drm_name_info(struct seq_file *m, void *data)
seq_printf(m, " master=%s", master->unique);
if (dev->unique)
seq_printf(m, " unique=%s", dev->unique);
- seq_printf(m, "\n");
+ seq_puts(m, "\n");
mutex_unlock(&dev->master_mutex);
return 0;
@@ -139,7 +139,7 @@ static int drm_gem_name_info(struct seq_file *m, void *data)
struct drm_debugfs_entry *entry = m->private;
struct drm_device *dev = entry->dev;
- seq_printf(m, " name size handles refcount\n");
+ seq_puts(m, " name size handles refcount\n");
mutex_lock(&dev->object_name_lock);
idr_for_each(&dev->object_name_idr, drm_gem_one_name_info, m);
--
2.43.0
next prev parent reply other threads:[~2026-03-20 8:38 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-20 7:31 [PATCH 0/2] drm: Use seq_puts() for fixed string output liuqiangneo
2026-03-20 7:31 ` liuqiangneo [this message]
2026-03-21 17:54 ` Claude review: drm/debugfs: Replace seq_printf with seq_puts for constant strings Claude Code Review Bot
2026-03-20 7:31 ` [PATCH 2/2] drm/dp_mst: " liuqiangneo
2026-03-21 17:54 ` Claude review: " Claude Code Review Bot
2026-03-21 17:54 ` Claude review: drm: Use seq_puts() for fixed string output Claude Code Review Bot
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=20260320073129.145575-2-liuqiangneo@163.com \
--to=liuqiangneo@163.com \
--cc=airlied@gmail.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-kernel@vger.kernel.org \
--cc=liuqiang@kylinos.cn \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=simona@ffwll.ch \
--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