diff options
Diffstat (limited to 'src/plugins/dpdk/device')
-rw-r--r-- | src/plugins/dpdk/device/common.c | 2 | ||||
-rw-r--r-- | src/plugins/dpdk/device/flow.c | 12 | ||||
-rw-r--r-- | src/plugins/dpdk/device/init.c | 4 |
3 files changed, 9 insertions, 9 deletions
diff --git a/src/plugins/dpdk/device/common.c b/src/plugins/dpdk/device/common.c index b9ba161423b..57430eff977 100644 --- a/src/plugins/dpdk/device/common.c +++ b/src/plugins/dpdk/device/common.c @@ -214,7 +214,7 @@ dpdk_device_stop (dpdk_device_t * xd) rte_eth_allmulticast_disable (xd->port_id); rte_eth_dev_stop (xd->port_id); - memset (&xd->link, 0, sizeof (struct rte_eth_link)); + clib_memset (&xd->link, 0, sizeof (struct rte_eth_link)); /* For bonded interface, stop slave links */ if (xd->pmd == VNET_DPDK_PMD_BOND) diff --git a/src/plugins/dpdk/device/flow.c b/src/plugins/dpdk/device/flow.c index 6ed11e2f304..6612ce4e1ad 100644 --- a/src/plugins/dpdk/device/flow.c +++ b/src/plugins/dpdk/device/flow.c @@ -179,7 +179,7 @@ dpdk_flow_add (dpdk_device_t * xd, vnet_flow_t * f, dpdk_flow_entry_t * fe) .vni_reserved = clib_host_to_net_u32 (((u32) - 1) << 8) }; - memset (raw, 0, sizeof raw); + clib_memset (raw, 0, sizeof raw); raw[0].item.relative = 1; raw[0].item.length = vxlan_hdr_sz; @@ -258,12 +258,12 @@ dpdk_flow_ops_fn (vnet_main_t * vnm, vnet_flow_dev_op_t op, u32 dev_instance, { /* make sure no action is taken for in-flight (marked) packets */ fle = pool_elt_at_index (xd->flow_lookup_entries, fe->mark); - memset (fle, -1, sizeof (*fle)); + clib_memset (fle, -1, sizeof (*fle)); vec_add1 (xd->parked_lookup_indexes, fe->mark); xd->parked_loop_count = dm->vlib_main->main_loop_count; } - memset (fe, 0, sizeof (*fe)); + clib_memset (fe, 0, sizeof (*fe)); pool_put (xd->flow_entries, fe); goto disable_rx_offload; @@ -294,7 +294,7 @@ dpdk_flow_ops_fn (vnet_main_t * vnm, vnet_flow_dev_op_t op, u32 dev_instance, fe->mark = fle - xd->flow_lookup_entries; /* install entry in the lookup table */ - memset (fle, -1, sizeof (*fle)); + clib_memset (fle, -1, sizeof (*fle)); if (flow->actions & VNET_FLOW_ACTION_MARK) fle->flow_id = flow->mark_flow_id; if (flow->actions & VNET_FLOW_ACTION_REDIRECT_TO_NODE) @@ -329,11 +329,11 @@ dpdk_flow_ops_fn (vnet_main_t * vnm, vnet_flow_dev_op_t op, u32 dev_instance, done: if (rv) { - memset (fe, 0, sizeof (*fe)); + clib_memset (fe, 0, sizeof (*fe)); pool_put (xd->flow_entries, fe); if (fle) { - memset (fle, -1, sizeof (*fle)); + clib_memset (fle, -1, sizeof (*fle)); pool_put (xd->flow_lookup_entries, fle); } } diff --git a/src/plugins/dpdk/device/init.c b/src/plugins/dpdk/device/init.c index 7d9ec7e5c80..697458c04b6 100644 --- a/src/plugins/dpdk/device/init.c +++ b/src/plugins/dpdk/device/init.c @@ -145,7 +145,7 @@ dpdk_device_lock_init (dpdk_device_t * xd) { xd->lockp[q] = clib_mem_alloc_aligned (CLIB_CACHE_LINE_BYTES, CLIB_CACHE_LINE_BYTES); - memset ((void *) xd->lockp[q], 0, CLIB_CACHE_LINE_BYTES); + clib_memset ((void *) xd->lockp[q], 0, CLIB_CACHE_LINE_BYTES); } } @@ -1518,7 +1518,7 @@ dpdk_update_link_state (dpdk_device_t * xd, f64 now) return; xd->time_last_link_update = now ? now : xd->time_last_link_update; - memset (&xd->link, 0, sizeof (xd->link)); + clib_memset (&xd->link, 0, sizeof (xd->link)); rte_eth_link_get_nowait (xd->port_id, &xd->link); if (LINK_STATE_ELOGS) |