summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Monjalon <thomas.monjalon@6wind.com>2014-07-03 16:06:04 +0200
committerThomas Monjalon <thomas.monjalon@6wind.com>2014-07-03 16:12:39 +0200
commit91873a652750c591baf5d568ccc38ca9661e56d3 (patch)
tree792a0665fd8ef1e99d69333bb2e8af4d58a5ea0f
parente904b5746dc1632fdbdeaeef118b29c2e961da95 (diff)
downloaddpdk-91873a652750c591baf5d568ccc38ca9661e56d3.zip
dpdk-91873a652750c591baf5d568ccc38ca9661e56d3.tar.gz
dpdk-91873a652750c591baf5d568ccc38ca9661e56d3.tar.xz
xen: fix build
There were 2 errors: lib/librte_pmd_xenvirt/rte_xen_lib.c:409:2: error: zero-length gnu_printf format string [-Werror=format-zero-length] lib/librte_pmd_xenvirt/rte_xen_lib.c:424:2: error: format '%p' expects argument of type 'void *', but argument 4 has type 'uintptr_t' [-Werror=format=] Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
-rw-r--r--lib/librte_pmd_xenvirt/rte_xen_lib.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/librte_pmd_xenvirt/rte_xen_lib.c b/lib/librte_pmd_xenvirt/rte_xen_lib.c
index 85a1ed9..b3932f0 100644
--- a/lib/librte_pmd_xenvirt/rte_xen_lib.c
+++ b/lib/librte_pmd_xenvirt/rte_xen_lib.c
@@ -406,8 +406,6 @@ grant_gntalloc_mbuf_pool(struct rte_mempool *mpool, uint32_t pg_num, uint32_t *g
char key_str[PATH_MAX] = {0};
char val_str[PATH_MAX] = {0};
- snprintf(val_str, sizeof(val_str), "");
-
if (grant_node_create(pg_num, gref_arr, pa_arr, val_str, sizeof(val_str))) {
return -1;
}
@@ -421,7 +419,7 @@ grant_gntalloc_mbuf_pool(struct rte_mempool *mpool, uint32_t pg_num, uint32_t *g
if (snprintf(key_str, sizeof(key_str),
DPDK_XENSTORE_PATH"%d"MEMPOOL_VA_XENSTORE_STR, mempool_idx) == -1)
return -1;
- if (snprintf(val_str, sizeof(val_str), "%p", (uintptr_t)mpool->elt_va_start) == -1)
+ if (snprintf(val_str, sizeof(val_str), "%"PRIxPTR, (uintptr_t)mpool->elt_va_start) == -1)
return -1;
if (xenstore_write(key_str, val_str) == -1)
return -1;