diff options
author | Christian Ehrhardt <christian.ehrhardt@canonical.com> | 2019-07-04 10:40:06 +0200 |
---|---|---|
committer | Christian Ehrhardt <christian.ehrhardt@canonical.com> | 2019-07-04 10:48:05 +0200 |
commit | 8d53e9f3c6001dcb2865f6e894da5b54e1418f88 (patch) | |
tree | 63907f21c13636a987d43463c675d0727a04e327 /drivers/event/opdl | |
parent | e2bea7436061ca2e7e14bfcfdc5870f2555c3965 (diff) |
New upstream version 18.11.2upstream-18.11-stable
Change-Id: I23eb4f9179abf1f9c659891f8fddb27ee68ad26b
Signed-off-by: Christian Ehrhardt <christian.ehrhardt@canonical.com>
Diffstat (limited to 'drivers/event/opdl')
-rw-r--r-- | drivers/event/opdl/opdl_evdev.c | 7 | ||||
-rw-r--r-- | drivers/event/opdl/opdl_evdev_xstats.c | 7 | ||||
-rw-r--r-- | drivers/event/opdl/opdl_ring.h | 8 |
3 files changed, 11 insertions, 11 deletions
diff --git a/drivers/event/opdl/opdl_evdev.c b/drivers/event/opdl/opdl_evdev.c index a4f0bc8b..d2d2be44 100644 --- a/drivers/event/opdl/opdl_evdev.c +++ b/drivers/event/opdl/opdl_evdev.c @@ -422,16 +422,17 @@ opdl_dump(struct rte_eventdev *dev, FILE *f) else p_type = "????"; - sprintf(queue_id, "%02u", port->external_qid); + snprintf(queue_id, sizeof(queue_id), "%02u", + port->external_qid); if (port->p_type == OPDL_REGULAR_PORT || port->p_type == OPDL_ASYNC_PORT) - sprintf(total_cyc, + snprintf(total_cyc, sizeof(total_cyc), " %'16"PRIu64"", (cpg != 0 ? port->port_stat[total_cycles] / cpg : 0)); else - sprintf(total_cyc, + snprintf(total_cyc, sizeof(total_cyc), " ----"); fprintf(f, "%4s %10u %8u %9s %'16"PRIu64" %'16"PRIu64" %s " diff --git a/drivers/event/opdl/opdl_evdev_xstats.c b/drivers/event/opdl/opdl_evdev_xstats.c index 0e6c6bd5..27b3d880 100644 --- a/drivers/event/opdl/opdl_evdev_xstats.c +++ b/drivers/event/opdl/opdl_evdev_xstats.c @@ -32,10 +32,9 @@ opdl_xstats_init(struct rte_eventdev *dev) uint32_t index = (i * max_num_port_xstat) + j; /* Name */ - sprintf(device->port_xstat[index].stat.name, - "port_%02u_%s", - i, - port_xstat_str[j]); + snprintf(device->port_xstat[index].stat.name, + sizeof(device->port_xstat[index].stat.name), + "port_%02u_%s", i, port_xstat_str[j]); /* ID */ device->port_xstat[index].id = index; diff --git a/drivers/event/opdl/opdl_ring.h b/drivers/event/opdl/opdl_ring.h index 751a59db..14ababe0 100644 --- a/drivers/event/opdl/opdl_ring.h +++ b/drivers/event/opdl/opdl_ring.h @@ -24,7 +24,7 @@ * packets. * * A opdl_ring can be used as the basis for pipeline based applications. Instead - * of each stage in a pipeline dequeueing from a ring, processing and enqueueing + * of each stage in a pipeline dequeuing from a ring, processing and enqueuing * to another ring, it can process entries in-place on the ring. If stages do * not depend on each other, they can run in parallel. * @@ -152,7 +152,7 @@ opdl_ring_get_name(const struct opdl_ring *t); * Enabling this may have a negative impact on performance if only one thread * will be processing this stage. * @param is_input - * Indication to nitialise the stage with all slots available or none + * Indication to initialise the stage with all slots available or none * * @return * A pointer to the new stage, or NULL on error. @@ -589,7 +589,7 @@ opdl_ring_set_stage_threadsafe(struct opdl_stage *s, bool threadsafe); * Compare the event descriptor with original version in the ring. * if key field event descriptor is changed by application, then * update the slot in the ring otherwise do nothing with it. - * the key field is flow_id, prioirty, mbuf, impl_opaque + * the key field is flow_id, priority, mbuf, impl_opaque * * @param s * The opdl_stage. @@ -600,7 +600,7 @@ opdl_ring_set_stage_threadsafe(struct opdl_stage *s, bool threadsafe); * @param atomic * queue type associate with the stage. * @return - * if the evevnt key field is changed compare with previous record. + * if the event key field is changed compare with previous record. */ bool |