mirror of
https://gitlab.freedesktop.org/mesa/drm.git
synced 2025-12-25 03:40:10 +01:00
Fix -Werror=format build errors on FreeBSD
On 64-bit FreeBSD targets uint64_t is generally defined as `unsigned long` and not `unsigned long long`. Use the PRI macros to fix -Wformat. Signed-off-by: Alex Richardson <Alexander.Richardson@cl.cam.ac.uk> Reviewed-by: Simon Ser <contact@emersion.fr>
This commit is contained in:
parent
d77ccdf3ba
commit
fda3d0010f
3 changed files with 3 additions and 3 deletions
|
|
@ -113,7 +113,7 @@ static int printProperty(int fd, drmModeResPtr res, drmModePropertyPtr props, ui
|
|||
|
||||
} else {
|
||||
for (j = 0; j < props->count_enums; j++) {
|
||||
printf("\t\t%lld = %s\n", props->enums[j].value, props->enums[j].name);
|
||||
printf("\t\t%" PRId64 " = %s\n", props->enums[j].value, props->enums[j].name);
|
||||
if (props->enums[j].value == value)
|
||||
name = props->enums[j].name;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -381,7 +381,7 @@ static void dump_prop(struct device *dev, drmModePropertyPtr prop,
|
|||
if (drm_property_type_is(prop, DRM_MODE_PROP_ENUM)) {
|
||||
printf("\t\tenums:");
|
||||
for (i = 0; i < prop->count_enums; i++)
|
||||
printf(" %s=%llu", prop->enums[i].name,
|
||||
printf(" %s=%"PRIu64, prop->enums[i].name,
|
||||
prop->enums[i].value);
|
||||
printf("\n");
|
||||
} else if (drm_property_type_is(prop, DRM_MODE_PROP_BITMASK)) {
|
||||
|
|
|
|||
|
|
@ -126,7 +126,7 @@ dump_prop(uint32_t prop_id, uint64_t value)
|
|||
if (drm_property_type_is(prop, DRM_MODE_PROP_ENUM)) {
|
||||
printf("\t\tenums:");
|
||||
for (i = 0; i < prop->count_enums; i++)
|
||||
printf(" %s=%llu", prop->enums[i].name,
|
||||
printf(" %s=%"PRIu64, prop->enums[i].name,
|
||||
prop->enums[i].value);
|
||||
printf("\n");
|
||||
} else if (drm_property_type_is(prop, DRM_MODE_PROP_BITMASK)) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue