aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBoris BREZILLON <boris.brezillon@free-electrons.com>2017-11-01 05:57:31 -0400
committerEric Anholt <eric@anholt.net>2017-11-03 13:15:42 -0400
commite073db5c5d7ad311efa8f4192a2047b006bbc5f3 (patch)
tree9318866ac0653a00aa7e1628e3c1addb62f1b330
parentd18d1a5ac811d12f7ebc1129230312b5f2c50cb8 (diff)
drm/vc4: Fix wrong printk format in vc4_bo_stats_debugfs()
vc4->purgeable.size and vc4->purgeable.purged_size are size_t fields and should be printed with a %zd specifier. Fixes: b9f19259b84d ("drm/vc4: Add the DRM_IOCTL_VC4_GEM_MADVISE ioctl") Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Reviewed-by: Gustavo Padovan <gustavo.padovan@collabora.com> Reviewed-by: Eric Anholt <eric@anholt.net> Link: https://patchwork.freedesktop.org/patch/msgid/20171101095731.14878-1-boris.brezillon@free-electrons.com (cherry picked from commit 50f365cde4ffb5ae70c3f02384bbb46698aba65c) Signed-off-by: Eric Anholt <eric@anholt.net>
-rw-r--r--drivers/gpu/drm/vc4/vc4_bo.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/vc4/vc4_bo.c b/drivers/gpu/drm/vc4/vc4_bo.c
index 01a53ba304f8..98a6cb9f44fc 100644
--- a/drivers/gpu/drm/vc4/vc4_bo.c
+++ b/drivers/gpu/drm/vc4/vc4_bo.c
@@ -88,11 +88,11 @@ int vc4_bo_stats_debugfs(struct seq_file *m, void *unused)
88 88
89 mutex_lock(&vc4->purgeable.lock); 89 mutex_lock(&vc4->purgeable.lock);
90 if (vc4->purgeable.num) 90 if (vc4->purgeable.num)
91 seq_printf(m, "%30s: %6dkb BOs (%d)\n", "userspace BO cache", 91 seq_printf(m, "%30s: %6zdkb BOs (%d)\n", "userspace BO cache",
92 vc4->purgeable.size / 1024, vc4->purgeable.num); 92 vc4->purgeable.size / 1024, vc4->purgeable.num);
93 93
94 if (vc4->purgeable.purged_num) 94 if (vc4->purgeable.purged_num)
95 seq_printf(m, "%30s: %6dkb BOs (%d)\n", "total purged BO", 95 seq_printf(m, "%30s: %6zdkb BOs (%d)\n", "total purged BO",
96 vc4->purgeable.purged_size / 1024, 96 vc4->purgeable.purged_size / 1024,
97 vc4->purgeable.purged_num); 97 vc4->purgeable.purged_num);
98 mutex_unlock(&vc4->purgeable.lock); 98 mutex_unlock(&vc4->purgeable.lock);