vhost: fix build on RHEL 7.6 for Power
authorDavid Christensen <drc@linux.vnet.ibm.com>
Wed, 14 Aug 2019 18:36:41 +0000 (13:36 -0500)
committerDavid Marchand <david.marchand@redhat.com>
Sun, 27 Oct 2019 10:07:19 +0000 (11:07 +0100)
Use of %llx print formatting causes meson build error on Power systems with
RHEL 7.6 and gcc 4.8.5.  Replace with PRIx64 macro.

Fixes: 9b62e2da1844 ("vhost: register new regions with userfaultfd")
Cc: stable@dpdk.org
Signed-off-by: David Christensen <drc@linux.vnet.ibm.com>
Reviewed-by: Tiwei Bie <tiwei.bie@intel.com>
lib/librte_vhost/vhost_user.c

index 61ef699..2a9fa7c 100644 (file)
@@ -1163,10 +1163,11 @@ vhost_user_set_mem_table(struct virtio_net **pdev, struct VhostUserMsg *msg,
                                goto err_mmap;
                        }
                        RTE_LOG(INFO, VHOST_CONFIG,
-                               "\t userfaultfd registered for range : %llx - %llx\n",
-                               reg_struct.range.start,
-                               reg_struct.range.start +
-                               reg_struct.range.len - 1);
+                               "\t userfaultfd registered for range : "
+                               "%" PRIx64 " - %" PRIx64 "\n",
+                               (uint64_t)reg_struct.range.start,
+                               (uint64_t)reg_struct.range.start +
+                               (uint64_t)reg_struct.range.len - 1);
 #else
                        goto err_mmap;
 #endif