[PATCH] drm/appletbdrm: fix format character for size_t
Jani Nikula
jani.nikula at intel.com
Tue Mar 4 13:54:56 UTC 2025
Use %zu for size_t instead of %lu to avoid failures on 32-bit builds:
error: format ‘%lu’ expects argument of type ‘long unsigned int’, but
argument 4 has type ‘size_t’ {aka ‘unsigned int’}
Fixes: 0670c2f56e45 ("drm/tiny: add driver for Apple Touch Bars in x86 Macs")
Cc: Kerem Karabay <kekrby at gmail.com>
Cc: Atharva Tiwari <evepolonium at gmail.com>
Cc: Aditya Garg <gargaditya08 at live.com>
Cc: Aun-Ali Zaidi <admin at kodeit.net>
Cc: Thomas Zimmermann <tzimmermann at suse.de>
Signed-off-by: Jani Nikula <jani.nikula at intel.com>
---
drivers/gpu/drm/tiny/appletbdrm.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/tiny/appletbdrm.c b/drivers/gpu/drm/tiny/appletbdrm.c
index f5d177e234e4..394c8f9bd41a 100644
--- a/drivers/gpu/drm/tiny/appletbdrm.c
+++ b/drivers/gpu/drm/tiny/appletbdrm.c
@@ -167,7 +167,7 @@ static int appletbdrm_send_request(struct appletbdrm_device *adev,
}
if (actual_size != size) {
- drm_err(drm, "Actual size (%d) doesn't match expected size (%lu)\n",
+ drm_err(drm, "Actual size (%d) doesn't match expected size (%zu)\n",
actual_size, size);
return -EIO;
}
@@ -208,7 +208,7 @@ static int appletbdrm_read_response(struct appletbdrm_device *adev,
}
if (actual_size != size) {
- drm_err(drm, "Actual size (%d) doesn't match expected size (%lu)\n",
+ drm_err(drm, "Actual size (%d) doesn't match expected size (%zu)\n",
actual_size, size);
return -EBADMSG;
}
--
2.39.5
More information about the dri-devel
mailing list