On Octeontx HW, each event timer device is enumerated as separate SRIOV VF
PCIe device.
In order to expose as a event timer device:
On PCIe probe, the driver stores the information associated with the
PCIe device and later when application requests for a event timer device
through `rte_event_timer_adapter_create` the driver infrastructure creates
the timer adapter with earlier probed PCIe VF devices.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
This commit adds the logic that is shared by all event timer adapter
drivers; the common code handles instance allocation and some
initialization.
Signed-off-by: Erik Gabriel Carrillo <erik.g.carrillo@intel.com>
Acked-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Add support for stop flush callback along with unit test.
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Acked-by: Gage Eads <gage.eads@intel.com>
When an event device is stopped, it drains all event queues and ports.
These events may contain pointers, so to prevent memory leaks eventdev now
supports a user-provided flush callback that is called during the queue
drain process. This callback is stored in process memory, so the callback
must be registered by any process that may call rte_event_dev_stop().
This commit also clarifies the behavior of rte_event_dev_stop().
This follows this mailing list discussion:
http://dpdk.org/ml/archives/dev/2018-January/087484.html
Signed-off-by: Gage Eads <gage.eads@intel.com>
Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
If application link one atomic queue to multiple ports,
and each worker core update flow_id, there will have a
chance to hit race condition issue and lead to double processing
same event. This fix solve the problem and eliminate
the race condition issue.
Fixes: 4236ce9bf5 ("event/opdl: add OPDL ring infrastructure library")
Cc: stable@dpdk.org
Signed-off-by: Liang Ma <liang.j.ma@intel.com>
Signed-off-by: Peter Mccarthy <peter.mccarthy@intel.com>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
Previously, the sw PMD would enqueue either all or no events, depending on
if enough inflight credits were available for the new events in the burst.
If a port is enqueueing a large burst (i.e. a multiple of the credit update
quanta), this can result in suboptimal performance, and requires an
understanding of the sw PMD implementation (in particular, its credit
scheme) to tune an application's burst size.
This affects software that enqueues large bursts of new events, such as the
ethernet event adapter which uses a 128-deep event buffer, when the input
packet rate is sufficiently high.
This change makes the sw PMD enqueue as many events as it has credits, if
there are any new events in the burst.
Signed-off-by: Gage Eads <gage.eads@intel.com>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
Counter variable 'out_pkts' had been set to 0, then updated. Current
code change elimates double assignment to direct assignment.
Signed-off-by: Vipin Varghese <vipin.varghese@intel.com>
Acked-by: Kevin Laatz <kevin.laatz@intel.com>
variables 'out_pkts_total' and 'out_pkts_total' will be in registers.
Hence shifting the code after the loop, helps the update from registers.
Signed-off-by: Vipin Varghese <vipin.varghese@intel.com>
Acked-by: Kevin Laatz <kevin.laatz@intel.com>
For most run cases 'sw->started' holds true. Adding a branch prediction
suggestion to compiler helps as this is first conditional check just
after entering the function.
Signed-off-by: Vipin Varghese <vipin.varghese@intel.com>
Acked-by: Kevin Laatz <kevin.laatz@intel.com>
Move commonly used functions across mempool, event and net devices to a
common folder in drivers.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Acked-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Some changes had already been pushed via SHA:72654f090a11 patch. This
patch updates them.
Signed-off-by: Shreyansh Jain <shreyansh.jain@nxp.com>
Acked-by: Nipun Gupta <nipun.gupta@nxp.com>
rte_cycles.h shall be included instead of rte_cycles_64.h
dpaa_eventdev.c:32:27:
fatal error: rte_cycles_64.h: No such file or directory
Fixes: 9caac5dd1e ("event/dpaa: introduce PMD")
Cc: stable@dpdk.org
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
This patch fixes the build dependency of various
dpaaX components, when the dpaa or fslmc bus is disabled,
or VFIO is disabled.
Fixes: 1ee9569576 ("config: enable dpaaX drivers for generic ARMv8")
Cc: stable@dpdk.org
Reported-by: Yongseok Koh <yskoh@mellanox.com>
Suggested-by: Thomas Monjalon <thomas@monjalon.net>
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Checking if portal has been allocated is now required at the
caller of rte_dpaa_portal_init() API. This patch adds check
in the dpaa eventdev driver.
Fixes: 5d944582d0 ("bus/dpaa: check portal presence in the caller function")
Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
DPAA2 eventdev is named as event_dpaa2 which conflicts with
event_dpaa when both are compiled in together. So event_dpaa
is required to renamed.
Fixes: 1ee9569576 ("config: enable dpaaX drivers for generic ARMv8")
Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
This patch ensures that the OPDL files all contain correct SPDX tags.
The following changes were made to achieve this:
* replace license text with SPDX tag
* correct occurences where SPDX tag was not on first line of file
* ensure license years were correct
Fixes: 4236ce9bf5 ("event/opdl: add OPDL ring infrastructure library")
Fixes: 3c7f3dcfb0 ("event/opdl: add PMD main body and helper function")
Fixes: d548ef513c ("event/opdl: add unit tests")
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Liang Ma <liang.j.ma@intel.com>
This commit enables dynamic logging with the SW pmd.
The string "pmd.event.sw" is used to change the verbosity
of the logging output, as per the newly defined log naming.
Signed-off-by: Harry van Haaren <harry.van.haaren@intel.com>
This commit aligns the names for dynamic logging with
the newly defined logging format.
Signed-off-by: Harry van Haaren <harry.van.haaren@intel.com>
Acked-by: Liang Ma <liang.j.ma@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
This commit aligns the names for dynamic logging with
the newly defined logging format.
Signed-off-by: Harry van Haaren <harry.van.haaren@intel.com>
Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Acked-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Add Cavium octeontx to meson build and change order of drivers built
from event->mempool->net to mempool->net->event to resolve dependency.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Add checks during build to ensure that all symbols in the EXPERIMENTAL
version map section have __experimental tags on their definitions, and
enable the warnings needed to announce their use. Also add an
ALLOW_EXPERIMENTAL_APIS define to allow individual libraries and files
to declare the acceptability of experimental api usage
Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
ICC reports the issue at compile time as follows.
error #592: variable "i" is used before its value is set
RTE_SET_USED(i);
The patch is to fix it. GCC and CLANG has been tested as well.
Fixes: d548ef513c ("event/opdl: add unit tests")
Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
Acked-by: Liang Ma <liang.j.ma@intel.com>
This commit reworks the loop counter variable declarations
to be in line with the DPDK source code.
Fixes: 3c7f3dcfb0 ("event/opdl: add PMD main body and helper function")
Fixes: 8ca8e3b48e ("event/opdl: add event queue config get/set")
Fixes: d548ef513c ("event/opdl: add unit tests")
Signed-off-by: Harry van Haaren <harry.van.haaren@intel.com>
Acked-by: Liang Ma <liang.j.ma@intel.com>
align the config option name with config/common_base
Fixes: aaa4a221da ("event/sw: add new software-only eventdev driver")
Cc: stable@dpdk.org
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
Create a rte_ethdev_driver.h file and move PMD specific APIs here.
Drivers updated to include this new header file.
There is no update in header content and since ethdev.h included by
ethdev_driver.h, nothing changed from driver point of view, only
logically grouping of APIs. From applications point of view they can't
access to driver specific APIs anymore and they shouldn't.
More PMD specific data structures still remain in ethdev.h because of
inline functions in header use them. Those will be handled separately.
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Shreyansh Jain <shreyansh.jain@nxp.com>
Acked-by: Andrew Rybchenko <arybchenko@solarflare.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
In the info get API we were returning number of event
ports as MAX number of LCORE's. After this change actual
number of event ports (i.e. number of DPIO's) is provided
in the info get API.
Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
This patch provides cleaner approach to store the DQRR entries,
which are yet to be consumed in case of atomic queues.
Also, this patch changes the storage of the DQRR entry index
into the mbuf->seqn instead of ev->opaque
Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Update software eventdev ops to invoke selftest when application invokes
`rte_event_dev_selftest`.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
Modify test_eventdev_sw to be standalone selftest independent of test
framework.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
Move software eventdev specific test (test_eventdev_sw) to
driver/event/sw/.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
Add selftest as a device argument that can be enabled by suppling
'self_test=1' as a vdev parameter
--vdev="event_octeontx,self_test=1"
The selftest is run after vdev creation is successfully
complete.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Modify test_eventdev_octeontx to be standalone selftest independent of
test framework.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>