[dpdk-stable] [PATCH] examples/vm_power: fix 32-bit build
Ferruh Yigit
ferruh.yigit at intel.com
Mon Oct 5 19:02:01 CEST 2020
Compiler version:
gcc 10.2.1 "cc (GCC) 10.2.1 20200723 (Red Hat 10.2.1-1)"
Build error:
../examples/vm_power_manager/guest_cli/vm_power_cli_guest.c:346:23:
warning: format ‘%ld’ expects argument of type ‘long int’, but
argument 4 has type ‘uint64_t’ {aka ‘long long unsigned int’}
[-Wformat=]
346 | cmdline_printf(cl, "Capabilities of [%d] vcore are:"
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
......
349 | pkt_caps_list.turbo[i],
| ~~~~~~~~~~~~~~~~~~~~~~
| |
| uint64_t {aka long long unsigned int}
Fixes: 07525d1a047a ("examples/vm_power: send capabilities request from guest")
Cc: stable at dpdk.org
Signed-off-by: Ferruh Yigit <ferruh.yigit at intel.com>
---
Cc: David Marchand <david.marchand at redhat.com>
Cc: David Hunt <david.hunt at intel.com>
Fixed patch is not new, not sure why getting the error now but was not
getting it before, do you have any clue?
Or is the CI having this error?
---
examples/vm_power_manager/guest_cli/vm_power_cli_guest.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/examples/vm_power_manager/guest_cli/vm_power_cli_guest.c b/examples/vm_power_manager/guest_cli/vm_power_cli_guest.c
index 96c1a1ff69..58029f8fb9 100644
--- a/examples/vm_power_manager/guest_cli/vm_power_cli_guest.c
+++ b/examples/vm_power_manager/guest_cli/vm_power_cli_guest.c
@@ -344,13 +344,13 @@ cmd_query_caps_list_parsed(void *parsed_result,
unsigned int i;
for (i = 0; i < pkt_caps_list.num_vcpu; ++i)
cmdline_printf(cl, "Capabilities of [%d] vcore are:"
- " turbo possibility: %ld, is priority core: %ld.\n",
+ " turbo possibility: %"PRId64", is priority core: %"PRId64".\n",
i,
pkt_caps_list.turbo[i],
pkt_caps_list.priority[i]);
} else {
cmdline_printf(cl, "Capabilities of [%d] vcore are:"
- " turbo possibility: %ld, is priority core: %ld.\n",
+ " turbo possibility: %"PRId64", is priority core: %"PRId64".\n",
lcore_id,
pkt_caps_list.turbo[lcore_id],
pkt_caps_list.priority[lcore_id]);
--
2.26.2
More information about the stable
mailing list