aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorChristophe Fontaine <christophe.fontaine@enea.com>2017-10-02 18:10:54 +0200
committerChris Luke <chris_luke@comcast.com>2017-10-04 17:31:13 +0000
commitd3c008d108aa2187d1a2afe2833b4de25ca2c2ab (patch)
tree03c85d4348fc955b33e6a6d628b5f8b81a2c8af6 /src/plugins
parent9bce0f6d7c3f7f1d5f2989ff1157c2a1039cdef6 (diff)
[aarch64] Fixes CLI crashes on dpaa2 platform.
- always use 'va_args' as pointer in all format_* functions - u32 for all 'indent' params as it's declaration was inconsistent Change-Id: Ic5799309a6b104c9b50fec309cba789c8da99e79 Signed-off-by: Christophe Fontaine <christophe.fontaine@enea.com>
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/dpdk/device/format.c20
-rw-r--r--src/plugins/flowprobe/node.c2
-rw-r--r--src/plugins/ixge/ixge.c10
-rw-r--r--src/plugins/lb/lb.c2
-rw-r--r--src/plugins/memif/cli.c4
-rw-r--r--src/plugins/memif/device.c2
-rw-r--r--src/plugins/memif/node.c2
7 files changed, 21 insertions, 21 deletions
diff --git a/src/plugins/dpdk/device/format.c b/src/plugins/dpdk/device/format.c
index 697bdbe54a8..b3ccb352955 100644
--- a/src/plugins/dpdk/device/format.c
+++ b/src/plugins/dpdk/device/format.c
@@ -374,7 +374,7 @@ format_dpdk_rss_hf_name (u8 * s, va_list * args)
{
u64 bitmap = va_arg (*args, u64);
int next_split = _line_len;
- int indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
if (!bitmap)
return format (s, "none");
@@ -387,7 +387,7 @@ format_dpdk_rx_offload_caps (u8 * s, va_list * args)
{
u32 bitmap = va_arg (*args, u32);
int next_split = _line_len;
- int indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
if (!bitmap)
return format (s, "none");
@@ -400,7 +400,7 @@ format_dpdk_tx_offload_caps (u8 * s, va_list * args)
{
u32 bitmap = va_arg (*args, u32);
int next_split = _line_len;
- int indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
if (!bitmap)
return format (s, "none");
@@ -415,7 +415,7 @@ format_dpdk_device_errors (u8 * s, va_list * args)
{
dpdk_device_t *xd = va_arg (*args, dpdk_device_t *);
clib_error_t *e;
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
vec_foreach (e, xd->errors)
{
@@ -431,7 +431,7 @@ format_dpdk_device (u8 * s, va_list * args)
int verbose = va_arg (*args, int);
dpdk_main_t *dm = &dpdk_main;
dpdk_device_t *xd = vec_elt_at_index (dm->devices, dev_instance);
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
f64 now = vlib_time_now (dm->vlib_main);
struct rte_eth_dev_info di;
@@ -577,7 +577,7 @@ format_dpdk_tx_dma_trace (u8 * s, va_list * va)
dpdk_tx_dma_trace_t *t = va_arg (*va, dpdk_tx_dma_trace_t *);
dpdk_main_t *dm = &dpdk_main;
dpdk_device_t *xd = vec_elt_at_index (dm->devices, t->device_index);
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
vnet_sw_interface_t *sw = vnet_get_sw_interface (vnm, xd->vlib_sw_if_index);
s = format (s, "%U tx queue %d",
@@ -604,7 +604,7 @@ format_dpdk_rx_dma_trace (u8 * s, va_list * va)
dpdk_main_t *dm = &dpdk_main;
dpdk_device_t *xd = vec_elt_at_index (dm->devices, t->device_index);
format_function_t *f;
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
vnet_sw_interface_t *sw = vnet_get_sw_interface (vnm, xd->vlib_sw_if_index);
s = format (s, "%U rx queue %d",
@@ -641,7 +641,7 @@ static inline u8 *
format_dpdk_pkt_types (u8 * s, va_list * va)
{
u32 *pkt_types = va_arg (*va, u32 *);
- uword indent __attribute__ ((unused)) = format_get_indent (s) + 2;
+ u32 indent __attribute__ ((unused)) = format_get_indent (s) + 2;
if (!*pkt_types)
return s;
@@ -664,7 +664,7 @@ static inline u8 *
format_dpdk_pkt_offload_flags (u8 * s, va_list * va)
{
u64 *ol_flags = va_arg (*va, u64 *);
- uword indent = format_get_indent (s) + 2;
+ u32 indent = format_get_indent (s) + 2;
if (!*ol_flags)
return s;
@@ -709,7 +709,7 @@ format_dpdk_rte_mbuf (u8 * s, va_list * va)
{
struct rte_mbuf *mb = va_arg (*va, struct rte_mbuf *);
ethernet_header_t *eth_hdr = va_arg (*va, ethernet_header_t *);
- uword indent = format_get_indent (s) + 2;
+ u32 indent = format_get_indent (s) + 2;
s = format (s, "PKT MBUF: port %d, nb_segs %d, pkt_len %d"
"\n%Ubuf_len %d, data_len %d, ol_flags 0x%x, data_off %d, phys_addr 0x%x"
diff --git a/src/plugins/flowprobe/node.c b/src/plugins/flowprobe/node.c
index 2f7d002561a..1c7786067ca 100644
--- a/src/plugins/flowprobe/node.c
+++ b/src/plugins/flowprobe/node.c
@@ -73,7 +73,7 @@ format_flowprobe_trace (u8 * s, va_list * args)
CLIB_UNUSED (vlib_main_t * vm) = va_arg (*args, vlib_main_t *);
CLIB_UNUSED (vlib_node_t * node) = va_arg (*args, vlib_node_t *);
flowprobe_trace_t *t = va_arg (*args, flowprobe_trace_t *);
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
s = format (s,
"FLOWPROBE[%s]: rx_sw_if_index %d, tx_sw_if_index %d, "
diff --git a/src/plugins/ixge/ixge.c b/src/plugins/ixge/ixge.c
index 222c148c67d..5fd6a901e35 100644
--- a/src/plugins/ixge/ixge.c
+++ b/src/plugins/ixge/ixge.c
@@ -448,7 +448,7 @@ format_ixge_rx_from_hw_descriptor (u8 * s, va_list * va)
va_arg (*va, ixge_rx_from_hw_descriptor_t *);
u32 s0 = d->status[0], s2 = d->status[2];
u32 is_ip4, is_ip6, is_ip, is_tcp, is_udp;
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
s = format (s, "%s-owned",
(s2 & IXGE_RX_DESCRIPTOR_STATUS2_IS_OWNED_BY_SOFTWARE) ? "sw" :
@@ -517,7 +517,7 @@ format_ixge_tx_descriptor (u8 * s, va_list * va)
{
ixge_tx_descriptor_t *d = va_arg (*va, ixge_tx_descriptor_t *);
u32 s0 = d->status0, s1 = d->status1;
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
u32 v;
s = format (s, "buffer 0x%Lx, %d packet bytes, %d bytes this buffer",
@@ -582,7 +582,7 @@ format_ixge_rx_dma_trace (u8 * s, va_list * va)
ixge_main_t *xm = &ixge_main;
ixge_device_t *xd = vec_elt_at_index (xm->devices, t->device_index);
format_function_t *f;
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
{
vnet_sw_interface_t *sw =
@@ -869,7 +869,7 @@ format_ixge_tx_dma_trace (u8 * s, va_list * va)
ixge_main_t *xm = &ixge_main;
ixge_device_t *xd = vec_elt_at_index (xm->devices, t->device_index);
format_function_t *f;
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
{
vnet_sw_interface_t *sw =
@@ -2344,7 +2344,7 @@ format_ixge_device (u8 * s, va_list * args)
ixge_main_t *xm = &ixge_main;
ixge_device_t *xd = vec_elt_at_index (xm->devices, dev_instance);
ixge_phy_t *phy = xd->phys + xd->phy_index;
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
ixge_update_counters (xd);
xd->link_status_at_last_link_change = xd->regs->xge_mac.link_status;
diff --git a/src/plugins/lb/lb.c b/src/plugins/lb/lb.c
index cc3f8532114..0bd2ff5d238 100644
--- a/src/plugins/lb/lb.c
+++ b/src/plugins/lb/lb.c
@@ -128,7 +128,7 @@ u8 *format_lb_vip_detailed (u8 * s, va_list * args)
{
lb_main_t *lbm = &lb_main;
lb_vip_t *vip = va_arg (*args, lb_vip_t *);
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
s = format(s, "%U %U [%u] %U%s\n"
"%U new_size:%u\n",
diff --git a/src/plugins/memif/cli.c b/src/plugins/memif/cli.c
index e1bd04441e0..deca27af2ef 100644
--- a/src/plugins/memif/cli.c
+++ b/src/plugins/memif/cli.c
@@ -194,7 +194,7 @@ format_memif_queue (u8 * s, va_list * args)
memif_if_t *mif = va_arg (*args, memif_if_t *);
memif_queue_t *mq = va_arg (*args, memif_queue_t *);
uword i = va_arg (*args, uword);
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
s = format (s, "%U%s ring %u:\n",
format_white_space, indent,
@@ -218,7 +218,7 @@ format_memif_descriptor (u8 * s, va_list * args)
{
memif_if_t *mif = va_arg (*args, memif_if_t *);
memif_queue_t *mq = va_arg (*args, memif_queue_t *);
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
memif_ring_t *ring;
u16 ring_size;
u16 slot;
diff --git a/src/plugins/memif/device.c b/src/plugins/memif/device.c
index aff18f2df6b..f7eb862eef5 100644
--- a/src/plugins/memif/device.c
+++ b/src/plugins/memif/device.c
@@ -64,7 +64,7 @@ format_memif_device (u8 * s, va_list * args)
{
u32 dev_instance = va_arg (*args, u32);
int verbose = va_arg (*args, int);
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
s = format (s, "MEMIF interface");
if (verbose)
diff --git a/src/plugins/memif/node.c b/src/plugins/memif/node.c
index 4acc714902e..8190441f4b5 100644
--- a/src/plugins/memif/node.c
+++ b/src/plugins/memif/node.c
@@ -60,7 +60,7 @@ format_memif_input_trace (u8 * s, va_list * args)
CLIB_UNUSED (vlib_main_t * vm) = va_arg (*args, vlib_main_t *);
CLIB_UNUSED (vlib_node_t * node) = va_arg (*args, vlib_node_t *);
memif_input_trace_t *t = va_arg (*args, memif_input_trace_t *);
- uword indent = format_get_indent (s);
+ u32 indent = format_get_indent (s);
s = format (s, "memif: hw_if_index %d next-index %d",
t->hw_if_index, t->next_index);