venus: Fix error log on PPC

On the ppc64le architecture error log fail to compile with error:

    ../src/virtio/vulkan/vn_renderer_virtgpu.c: In function ‘virtgpu_ioctl_map’:
    ../src/virtio/vulkan/vn_renderer_virtgpu.c:751:66: error: format ‘%llu’ expects argument of type ‘long long unsigned int’, but argument 6 has type ‘__u64’ {aka ‘long unsigned int’} [-Werror=format=]
    751 |          "mmap failed: gpu_fd=%d, handle=%u, size=%zu, offset=%llu, err=%s",
        |                                                               ~~~^
        |                                                                  |
        |                                                                  long long unsigned int
        |                                                               %lu
    752 |          gpu->fd, gem_handle, size, args.offset, strerror(errno));
        |                                     ~~~~~~~~~~~
        |                                         |
        |                                         __u64 {aka long unsigned int}
    cc1: some warnings being treated as errors

Parse the parameters to fix the failure.

Fixes: a49b7adad8 ("venus: add error log coverage for virtgpu backend")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39775>
This commit is contained in:
José Expósito 2026-02-09 10:02:18 +01:00 committed by Marge Bot
parent 757ae04bd9
commit dd3fe2d671

View file

@ -749,7 +749,7 @@ virtgpu_ioctl_map(struct virtgpu *gpu,
vn_log(
gpu->instance,
"mmap failed: gpu_fd=%d, handle=%u, size=%zu, offset=%llu, err=%s",
gpu->fd, gem_handle, size, args.offset, strerror(errno));
gpu->fd, gem_handle, size, (long long)args.offset, strerror(errno));
return NULL;
}