Re: help with pthread_t deprecation / api changes

2022-12-08 Thread Thomas Monjalon
02/12/2022 20:57, Tyler Retzlaff: > On Fri, Dec 02, 2022 at 09:03:25AM +0100, Morten Brørup wrote: > > +Bruce, FreeBSD EAL maintainer > > > > > > > > This is one of the consequences of a bloated EAL. > > > > How is an application supposed to run on top of an EAL that isn't fully > > implemente

[PATCH] net/nfp: store counter reset before zeroing flow query

2022-12-08 Thread Chaoyong He
The reset flag in the query structure are cleared by mistake, cause the flow count never be reset, so the query API will always has count value even the flow has stopped, and this will cause the flow never been aged. Fixes: 30ecce522732 ("net/nfp: support flow API") Cc: chaoyong...@corigine.com S

[Bug 1121] [19.11.13] drivers/net/ice/base/ meson build error with clang5.0 on OpenSuse15.0

2022-12-08 Thread bugzilla
https://bugs.dpdk.org/show_bug.cgi?id=1121 jiang,yu (yux.ji...@intel.com) changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|---

RE: [EXT] [PATCH 2/2] devtools: configure source repo to use as ABI reference

2022-12-08 Thread Akhil Goyal
> 08/12/2022 19:14, Akhil Goyal: > > > By default 'test-meson-builds.sh' script clones the repository which the > > > script is in, and selects a configured branch ('DPDK_ABI_REF_VERSION') > > > as a reference for ABI check. > > > > > > This patch enables selecting different repository to close for

RE: [PATCH] net/idpf: fix build option check

2022-12-08 Thread Xing, Beilei
> -Original Message- > From: Wu, Jingjing > Sent: Thursday, December 8, 2022 11:31 AM > To: dev@dpdk.org > Cc: Wu, Jingjing ; Xing, Beilei > ; > sta...@dpdk.org > Subject: [PATCH] net/idpf: fix build option check > > When enable_iova_as_pa option is disabled, idpf driver should avoid

Re: [PATCH 8/8] ethdev: telemetry convert capability related variable to hex

2022-12-08 Thread lihuisong (C)
在 2022/12/8 19:20, Bruce Richardson 写道: On Thu, Dec 08, 2022 at 11:55:16AM +0100, Morten Brørup wrote: +To: Bruce and Stephen might also have opinions on this. From: Huisong Li [mailto:lihuis...@huawei.com] Sent: Thursday, 8 December 2022 09.06 The 'dev_flags', 'rx_offloads', 'tx_offloads'

[PATCH] net/nfp: add support reading linkspeed from port table

2022-12-08 Thread Chaoyong He
From: Long Wu The NFP PMD driver retrieves the linkspeed by reading the NFP_NET_CFG_STS_LINK register. This register is not set by all versions of the firmware. Add a second preferred method to read the linkspeed from the port table instead, while keeping the old lookup method as a fallback in c

RE: [PATCH v2] vdpa/ifc: Match ANY subsystem IDs for modern virtio devices

2022-12-08 Thread Pei, Andy
Hi Abhishek, I agree with Xiao. I think it will be better you just add subvendor and subdevice you want to be take care of by this vdpa driver. > -Original Message- > From: Wang, Xiao W > Sent: Thursday, December 8, 2022 9:09 PM > To: Maheshwari, Abhishek > Cc: dev@dpdk.org; sta...@dpd

[Bug 1145] net/ice fdir flow create/destroy failed with RTE_LIBRTE_ICE_16BYTE_RX_DESC defined

2022-12-08 Thread bugzilla
https://bugs.dpdk.org/show_bug.cgi?id=1145 Bug ID: 1145 Summary: net/ice fdir flow create/destroy failed with RTE_LIBRTE_ICE_16BYTE_RX_DESC defined Product: DPDK Version: 21.11 Hardware: All OS: All

[PATCH] net/nfp: check whether the generated VF can be used

2022-12-08 Thread Chaoyong He
From: Peng Zhang All the queue pairs are shared between VF and PF for NFP, and there exist different assignment policy for different firmware application. The user can create VFs up to the max number of queue pairs, which will cause the last few VFs has no queue pairs and cannot be used, because

Re: [PATCH v2 1/3] eal: add rte control thread create API

2022-12-08 Thread Stephen Hemminger
On Tue, 6 Dec 2022 09:28:24 -0800 Tyler Retzlaff wrote: > + /* Wait for the control thread to initialize successfully */ > + while ((ctrl_thread_status = > + __atomic_load_n(¶ms->ctrl_thread_status, > + __ATOMIC_ACQUIRE)) == CTRL_THREAD_LAUNCHING)

[PATCH v4 0/3] eal: rte_ctrl_thread_create API replacement

2022-12-08 Thread Tyler Retzlaff
Remove rte_ctrl_thread_create API which exposes pthread_t and provide new rte_control_thread_create API based on EALs rte_thread_t. To limit compatibility regression risk and ease of removal of the existing rte_ctrl_thread_create in the future duplicate most of the existing implementation. The dup

[PATCH v4 3/3] eal: deprecate pthread control thread create API

2022-12-08 Thread Tyler Retzlaff
Give notice of rte_ctrl_thread_create deprecation. Signed-off-by: Tyler Retzlaff --- doc/guides/rel_notes/deprecation.rst | 4 1 file changed, 4 insertions(+) diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst index b9b02dc..ce3b4b7 100644 --- a/doc/g

[PATCH v4 1/3] eal: add rte control thread create API

2022-12-08 Thread Tyler Retzlaff
Add rte_control_thread_create API as a replacement for rte_ctrl_thread_create to allow deprecation of the use of platform specific types in DPDK public API. Signed-off-by: Tyler Retzlaff --- lib/eal/common/eal_common_thread.c | 89 ++ lib/eal/include/rte_threa

[PATCH v4 2/3] test: add rte control thread create API test

2022-12-08 Thread Tyler Retzlaff
Duplicate the rte_ctrl_thread_create test adapted to use rte_control_thread create to keep both apis under test until rte_ctrl_thread_create is removed. Signed-off-by: Tyler Retzlaff --- app/test/test_lcores.c | 42 ++ 1 file changed, 42 insertions(+) dif

Re: [PATCH v2 1/3] eal: add rte control thread create API

2022-12-08 Thread Tyler Retzlaff
On Thu, Dec 08, 2022 at 10:59:13PM +0100, Mattias Rönnblom wrote: > On 2022-12-07 17:38, Tyler Retzlaff wrote: > > > >> > >>>+ } u; > >>> void *arg; > >>> int ret; > >> > >>Why is 'ret' needed? (This question is unrelated to your patch.) > > > >i'm not the original author so difficult to answe

Re: [PATCH v2 1/3] eal: add rte control thread create API

2022-12-08 Thread Mattias Rönnblom
On 2022-12-07 17:38, Tyler Retzlaff wrote: On Wed, Dec 07, 2022 at 10:13:39AM +0100, Mattias Rönnblom wrote: On 2022-12-06 18:28, Tyler Retzlaff wrote: Add rte_control_thread_create API as a replacement for rte_ctrl_thread_create to allow deprecation of the use of platform specific types in DPD

[PATCH] eal: replace lcore direct use of pthread in the EAL

2022-12-08 Thread Tyler Retzlaff
* Replace the use of pthread_t in struct lcore_config with the EAL rte_thread_t type. * Replace the direct use of pthread_create(), pthread_self() pthread_getaffinity_np() and pthread_setaffinity_np(). Minor tweaks to return value comparisons to align with current DPDK style. Signed-off-by:

[PATCH v2 37/37] ml/cnxk: add user guide for marvell cnxk ml driver

2022-12-08 Thread Srikanth Yalavarthi
Added user guide for Marvell cnxk ML driver for Marvell Octeon cnxk Soc family. Added details about device initialization, debug options and runtime device args supported by the driver. Signed-off-by: Srikanth Yalavarthi --- v2: * Fixed typos MAINTAINERS | 1 + doc/guides/inde

[PATCH v2 36/37] ml/cnxk: add support to select poll memory region

2022-12-08 Thread Srikanth Yalavarthi
Added device argument "poll_mem" to select the memory region to be used for polling in fast-path requests. Implemented support to use scratch registers for polling. Available pool of scratch registers one-to-one mapped with the internal request queue. poll_mem: ddr: Use DDR memory location f

[PATCH v2 35/37] ml/cnxk: add support to use lock during jcmd enq

2022-12-08 Thread Srikanth Yalavarthi
Added device argument "hw_queue_lock" to select the JCMDQ enqueue ROC function to be used in fast path. hw_queue_lock: 0: Disable, use lock free version of JCMDQ enqueue ROC function for job queuing. To avoid race condition in request queuing to hardware, disabling hw_queue_lock

[PATCH v2 34/37] ml/cnxk: add support to select OCM allocation mode

2022-12-08 Thread Srikanth Yalavarthi
Added device argument "ocm_alloc_mode" to select OCM allocation method during model start. Two modes are supported by the driver. Added implementation for ocm_alloc_mode lowest as default. ocm_alloc_mode: lowest: Allocate from first available free slot / lowest tile ID in OCM (default)

[PATCH v2 33/37] ml/cnxk: add support to enable model data caching

2022-12-08 Thread Srikanth Yalavarthi
Added device argument 'cache_model_data' to enable model data caching. An inference request would be executed with dummy data in synchronous mode during model start stage. This run would cache the model weights and bias in the memory and result in improved inference throughput. cache_model_data =

[PATCH v2 32/37] ml/cnxk: add support to report DPE FW warnings

2022-12-08 Thread Srikanth Yalavarthi
Enabled support to enable and report DPE warnings from ML firmware. Configure firmware load flags based on the device arguments. Default values: enable_dpe_errors = 1 report_dpe_errors = 0 Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.c | 94 +++

[PATCH v2 31/37] ml/cnxk: enable support to get xstats in cycles

2022-12-08 Thread Srikanth Yalavarthi
Enabled support to retrieve xstats in either cycles or ns. Access to sclk is enabled only if an RVU device is probed during initialization. Driver would return the xstats in nanoseconds only when an RVU device is probed, else would fallback to cycles. Signed-off-by: Srikanth Yalavarthi --- drive

[PATCH v2 29/37] ml/cnxk: add support to get and reset device stats

2022-12-08 Thread Srikanth Yalavarthi
Enabled support to get and reset ML device stats. Device stats include number of requests enqueued/dequeued and error count. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 55 -- drivers/ml/cnxk/cn10k_ml_ops.h | 3 ++ 2 files changed, 55

[PATCH v2 27/37] ml/cnxk: add internal function for sync mode run

2022-12-08 Thread Srikanth Yalavarthi
Added internal function to execute ML inference requests in synchronous mode. Sync mode inference execution is used to launch inference requests without using a queue-pair. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 53 ++ drivers/ml/c

[PATCH v2 30/37] ml/cnxk: add support to handle extended dev stats

2022-12-08 Thread Srikanth Yalavarthi
Added support to handle ML device extended stats. Support is enabled to get xstats names and stats values and reset xstats. Supported xstats include avg, min and max hardware and firmware latency. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.h | 3 + drivers/ml/cnxk/cn

[PATCH v2 26/37] ml/cnxk: dequeue a burst of inference requests

2022-12-08 Thread Srikanth Yalavarthi
Enabled driver support to dequeue inference requests from internal queue. Dequeue checks for request completion by polling the status field of the job request. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 61 ++ drivers/ml/cnxk/cn10k_ml_

[PATCH v2 24/37] ml/cnxk: add driver support for device selftest

2022-12-08 Thread Srikanth Yalavarthi
Added support for device selftest. Device selftest includes checking the status of firmware. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 57 ++ 1 file changed, 57 insertions(+) diff --git a/drivers/ml/cnxk/cn10k_ml_ops.c b/drivers/ml/c

[PATCH v2 28/37] ml/cnxk: enable support for firmware error codes

2022-12-08 Thread Srikanth Yalavarthi
Enabled support for error handling. Added error types and subtypes supported by ML firmware. Enabled support to get device specific error code and message for a completed ML request. Signed-off-by: Srikanth Yalavarthi --- v2: * Fixed typos drivers/ml/cnxk/cn10k_ml_dev.c | 4 +- drivers/ml/cnx

[PATCH v2 25/37] ml/cnxk: enqueue a burst of inference requests

2022-12-08 Thread Srikanth Yalavarthi
Enabled driver support to enqueue a burst of inference requests to ML device. Enqueue uses internal ML request structure to queue the inferences and job completion through polling. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 96 ++ driv

[PATCH v2 22/37] ml/cnxk: enable quantization and dequantization

2022-12-08 Thread Srikanth Yalavarthi
Implemented driver functions to quantize / dequantize input and output data. Support is enabled for multiple batches. Quantization / dequantization use the type conversion functions defined in ML common code. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 150 +++

[PATCH v2 23/37] ml/cnxk: enable support to dump device debug info

2022-12-08 Thread Srikanth Yalavarthi
Added support to dump device debug information. Debug info on cn10k device includes model state info, OCM usage info, firmware debug and exception buffer. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ocm.c | 51 + drivers/ml/cnxk/cn10k_ml_ocm.h | 1 + drivers/ml/cnx

[PATCH v2 21/37] ml/cnxk: add support to get IO buffer sizes

2022-12-08 Thread Srikanth Yalavarthi
Added driver functions to get input and output buffer sizes for a given batch size. This function would compute the buffer size based on specific requirements of the device. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 52 ++ 1 file chan

[PATCH v2 20/37] ml/cnxk: enable support to update model params

2022-12-08 Thread Srikanth Yalavarthi
Added cnxk driver functions to update model params or weights and bias after a models is loaded. Updating model params would not require reloading the model. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 31 +++ 1 file changed, 31 insertions(

[PATCH v2 19/37] ml/cnxk: enable support to get model information

2022-12-08 Thread Srikanth Yalavarthi
Added driver functions to get model information. Added internal functions to set and get model info. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_model.c | 54 drivers/ml/cnxk/cn10k_ml_model.h | 9 ++ drivers/ml/cnxk/cn10k_ml_ops.c | 37

[PATCH v2 18/37] ml/cnxk: enable support to stop an ML models

2022-12-08 Thread Srikanth Yalavarthi
Implemented model stop driver function. A model stop job is enqueued through scratch registers and is checked for completion through polling in a synchronous mode. OCM pages are released after model stop completion. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 115

[PATCH v2 17/37] ml/cnxk: enable support to start an ML model

2022-12-08 Thread Srikanth Yalavarthi
Implemented model start driver function. A model start job is checked for completion in synchronous mode. Tilemask and OCM slot is calculated before starting the model. Model start is enqueued through scratch registers. OCM pages are reserved after model start completion. Signed-off-by: Srikanth

[PATCH v2 16/37] ml/cnxk: add support to reserve and free OCM pages

2022-12-08 Thread Srikanth Yalavarthi
Added support to reserve and free OCM pages for a model. OCM pages are reserved upon completion of model start and are released after model stop. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ocm.c | 131 - drivers/ml/cnxk/cn10k_ml_ocm.h | 3 +

[PATCH v2 14/37] ml/cnxk: add structures for slow and fast path JDs

2022-12-08 Thread Srikanth Yalavarthi
Added JD structures for load, unload and run jobs. Initialize job command and allocate memory for request structures for slow path jobs. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.h | 99 drivers/ml/cnxk/cn10k_ml_model.h | 4 ++ driver

[PATCH v2 13/37] ml/cnxk: add internal structures for tiles and OCM

2022-12-08 Thread Srikanth Yalavarthi
Added internal structures to handle tile and OCM information and OCM to model memory mapping. Initialize the fields to platform specific defaults and compute the OCM / tile requirements for model. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.h | 5 ++ drivers/ml/cnxk/cn

[PATCH v2 15/37] ml/cnxk: find OCM mask and page slots for a model

2022-12-08 Thread Srikanth Yalavarthi
Added support to compute OCM tilemask and page start for a model. The computed tilemask and page start are used during model start to copy model weights and bias to OCM. OCM slot for a model is allocated from the tiles with maximum amount of free memory. Signed-off-by: Srikanth Yalavarthi --- dr

[PATCH v2 11/37] ml/cnxk: enable validity checks for model metadata

2022-12-08 Thread Srikanth Yalavarthi
Added model metadata structure and enabled metadata check during model load. Remap cnxk IO types with RTE IO types. Store and update model metadata in model structure. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_model.c | 196 +++ drivers/ml/cnxk/cn10k_ml_mode

[PATCH v2 12/37] ml/cnxk: add internal structures for derived info

2022-12-08 Thread Srikanth Yalavarthi
Added internal structures to handle derived address fields and enabled support to compute DMA addresses for model start. Enabled updating internal model fields. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_model.c | 88 drivers/ml/cnxk/cn10k_ml

[PATCH v2 10/37] ml/cnxk: add functions to load and unload models

2022-12-08 Thread Srikanth Yalavarthi
Added cnxk driver implementations to load and unload ML models. Enabled support in configure stage to allocate model handles array. Assign model ID and allocate resources per each model during load stage and release resources during model unload. Added internal structures to handle ML models. Sign

[PATCH v2 09/37] ml/cnxk: add support to create device queue-pairs

2022-12-08 Thread Srikanth Yalavarthi
Enabled support to create and destroy device queue-pairs. Updated configure stage to create array to store queue-pair handles. Added internal structure for queue-pair, queue and ML inference requests. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 207 +++

[PATCH v2 08/37] ml/cnxk: enable support for device start and stop

2022-12-08 Thread Srikanth Yalavarthi
Implemented ML driver functions to start and stop ML device. Start / Stop would enable or disable ML device to accept inference requests. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 42 +++--- 1 file changed, 39 insertions(+), 3 deletions(-

[PATCH v2 05/37] ml/cnxk: parse ML firmware path from device args

2022-12-08 Thread Srikanth Yalavarthi
Enabled parsing ML firmware path for cn10k. Default path is set as "/lib/firmware/mlip-fw.bin", when args are not provided. Added internal structures for ML firmware. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.c | 71 ++ drivers/ml/cnxk/cn

[PATCH v2 07/37] ml/cnxk: enable support for simulator environment

2022-12-08 Thread Srikanth Yalavarthi
Enabled device initialization and firmware load on simulator platform. Firmware load stage on simulator would involve launching a firmware handshake request only. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.c | 119 + 1 file changed, 107 in

[PATCH v2 06/37] ml/cnxk: enable firmware load and device reset

2022-12-08 Thread Srikanth Yalavarthi
Enabled support to load ML firmware on cn10ka ROC model. Reset MLIP device during dev_close driver operation. Device can't be reconfigured after a call to close. Job execution is disabled after firmware load, execution is enabled in device start state. Added internal request structure. Signed-off-

[PATCH v2 04/37] ml/cnxk: add support for configure and close

2022-12-08 Thread Srikanth Yalavarthi
Implemented driver functions to configure and close ML devices. Added skeleton code and support to reconfigure ML device. PCI device remove is enabled in device close. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.c | 2 ++ drivers/ml/cnxk/cn10k_ml_dev.h | 21

[PATCH v2 02/37] ml/cnxk: enable probe and remove of ML device

2022-12-08 Thread Srikanth Yalavarthi
ML inference engine on cn10k platform is a PCI based device. Added driver support to probe and remove the device for cn10k poll mode driver. The device is named by the PMD as "ml_cn10k". Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.c | 114 +

[PATCH v2 03/37] ml/cnxk: add driver support to get device info

2022-12-08 Thread Srikanth Yalavarthi
Added support to get the cn10k ML device information. This is a driver implementation for the RTE function rte_ml_dev_info_get. ML device on cn10k supports one queue-pair in lock-free mode and does not support segmented input output data. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn

[PATCH v2 01/37] ml/cnxk: add skeleton for ML cnxk driver

2022-12-08 Thread Srikanth Yalavarthi
Added initial source files and build files for ML cnxk driver. Signed-off-by: Srikanth Yalavarthi --- Depends-on: patch-120600 ("common/cnxk: add ML headers and ROC code for cnxk") MAINTAINERS| 2 ++ drivers/meson.build| 1 + drivers/ml/cnxk/cn10k_ml_dev.c | 8

[PATCH v2 00/37] Implementation of ML CNXK driver

2022-12-08 Thread Srikanth Yalavarthi
Marvell ML CNXK Driver -- This patch series implements Machine Learning (ML) driver for Marvell Octeon 10 (cnxk) platform. ML inferencing is supported on cnxk platform through an integrated ML inferencing processor. The current driver supports programming the ML hardware engine

[PATCH v1 37/37] ml/cnxk: add user guide for marvell cnxk ml driver

2022-12-08 Thread Srikanth Yalavarthi
Added user guide for Marvell cnxk ML driver for Marvell Octeon cnxk Soc family. Added details about device initialization, debug options and runtime device args supported by the driver. Signed-off-by: Srikanth Yalavarthi --- MAINTAINERS | 1 + doc/guides/index.rst| 1

[PATCH v1 36/37] ml/cnxk: add support to select poll memory region

2022-12-08 Thread Srikanth Yalavarthi
Added device argument "poll_mem" to select the memory region to be used for polling in fast-path requests. Implemented support to use scratch registers for polling. Available pool of scratch registers one-to-one mapped with the internal request queue. poll_mem: ddr: Use DDR memory location f

[PATCH v1 35/37] ml/cnxk: add support to use lock during jcmd enq

2022-12-08 Thread Srikanth Yalavarthi
Added device argument "hw_queue_lock" to select the JCMDQ enqueue ROC function to be used in fast path. hw_queue_lock: 0: Disable, use lock free version of JCMDQ enqueue ROC function for job queuing. To avoid race condition in request queuing to hardware, disabling hw_queue_lock

[PATCH v1 33/37] ml/cnxk: add support to enable model data caching

2022-12-08 Thread Srikanth Yalavarthi
Added device argument 'cache_model_data' to enable model data caching. An inference request would be executed with dummy data in synchronous mode during model start stage. This run would cache the model weights and bias in the memory and result in improved inference throughput. cache_model_data =

[PATCH v1 30/37] ml/cnxk: add support to handle extended dev stats

2022-12-08 Thread Srikanth Yalavarthi
Added support to handle ML device extended stats. Support is enabled to get xstats names and stats values and reset xstats. Supported xstats include avg, min and max hardware and firmware latency. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.h | 3 + drivers/ml/cnxk/cn

[PATCH v1 28/37] ml/cnxk: enable support for firmware error codes

2022-12-08 Thread Srikanth Yalavarthi
Enabled support for error handling. Added error types and subtypes supported by ML firmware. Enabled support to get device specific error code and message for a completed ML request. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.c | 4 +- drivers/ml/cnxk/cn10k_ml_dev.h |

[PATCH v1 34/37] ml/cnxk: add support to select OCM allocation mode

2022-12-08 Thread Srikanth Yalavarthi
Added device argument "ocm_alloc_mode" to select OCM allocation method during model start. Two modes are supported by the driver. Added implementation for ocm_alloc_mode lowest as default. ocm_alloc_mode: lowest: Allocate from first available free slot / lowest tile ID in OCM (default)

[PATCH v1 27/37] ml/cnxk: add internal function for sync mode run

2022-12-08 Thread Srikanth Yalavarthi
Added internal function to execute ML inference requests in synchronous mode. Sync mode inference execution is used to launch inference requests without using a queue-pair. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 53 ++ drivers/ml/c

[PATCH v1 32/37] ml/cnxk: add support to report DPE FW warnings

2022-12-08 Thread Srikanth Yalavarthi
Enabled support to enable and report DPE warnings from ML firmware. Configure firmware load flags based on the device arguments. Default values: enable_dpe_errors = 1 report_dpe_errors = 0 Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.c | 94 +++

[PATCH v1 25/37] ml/cnxk: enqueue a burst of inference requests

2022-12-08 Thread Srikanth Yalavarthi
Enabled driver support to enqueue a burst of inference requests to ML device. Enqueue uses internal ML request structure to queue the inferences and job completion through polling. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 96 ++ driv

[PATCH v1 31/37] ml/cnxk: enable support to get xstats in cycles

2022-12-08 Thread Srikanth Yalavarthi
Enabled support to retrieve xstats in either cycles or ns. Access to sclk is enabled only if an RVU device is probed during initialization. Driver would return the xstats in nanoseconds only when an RVU device is probed, else would fallback to cycles. Signed-off-by: Srikanth Yalavarthi --- drive

[PATCH v1 22/37] ml/cnxk: enable quantization and dequantization

2022-12-08 Thread Srikanth Yalavarthi
Implemented driver functions to quantize / dequantize input and output data. Support is enabled for multiple batches. Quantization / dequantization use the type conversion functions defined in ML common code. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 150 +++

[PATCH v1 29/37] ml/cnxk: add support to get and reset device stats

2022-12-08 Thread Srikanth Yalavarthi
Enabled support to get and reset ML device stats. Device stats include number of requests enqueued/dequeued and error count. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 55 -- drivers/ml/cnxk/cn10k_ml_ops.h | 3 ++ 2 files changed, 55

[PATCH v1 26/37] ml/cnxk: dequeue a burst of inference requests

2022-12-08 Thread Srikanth Yalavarthi
Enabled driver support to dequeue inference requests from internal queue. Dequeue checks for request completion by polling the status field of the job request. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 61 ++ drivers/ml/cnxk/cn10k_ml_

[PATCH v1 24/37] ml/cnxk: add driver support for device selftest

2022-12-08 Thread Srikanth Yalavarthi
Added support for device selftest. Device selftest includes checking the status of firmware. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 57 ++ 1 file changed, 57 insertions(+) diff --git a/drivers/ml/cnxk/cn10k_ml_ops.c b/drivers/ml/c

[PATCH v1 16/37] ml/cnxk: add support to reserve and free OCM pages

2022-12-08 Thread Srikanth Yalavarthi
Added support to reserve and free OCM pages for a model. OCM pages are reserved upon completion of model start and are released after model stop. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ocm.c | 131 - drivers/ml/cnxk/cn10k_ml_ocm.h | 3 +

[PATCH v1 23/37] ml/cnxk: enable support to dump device debug info

2022-12-08 Thread Srikanth Yalavarthi
Added support to dump device debug information. Debug info on cn10k device includes model state info, OCM usage info, firmware debug and exception buffer. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ocm.c | 51 + drivers/ml/cnxk/cn10k_ml_ocm.h | 1 + drivers/ml/cnx

[PATCH v1 15/37] ml/cnxk: find OCM mask and page slots for a model

2022-12-08 Thread Srikanth Yalavarthi
Added support to compute OCM tilemask and page start for a model. The computed tilemask and page start are used during model start to copy model weights and bias to OCM. OCM slot for a model is allocated from the tiles with maximum amount of free memory. Signed-off-by: Srikanth Yalavarthi --- dr

[PATCH v1 21/37] ml/cnxk: add support to get IO buffer sizes

2022-12-08 Thread Srikanth Yalavarthi
Added driver functions to get input and output buffer sizes for a given batch size. This function would compute the buffer size based on specific requirements of the device. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 52 ++ 1 file chan

[PATCH v1 14/37] ml/cnxk: add structures for slow and fast path JDs

2022-12-08 Thread Srikanth Yalavarthi
Added JD structures for load, unload and run jobs. Initialize job command and allocate memory for request structures for slow path jobs. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.h | 99 drivers/ml/cnxk/cn10k_ml_model.h | 4 ++ driver

[PATCH v1 13/37] ml/cnxk: add internal structures for tiles and OCM

2022-12-08 Thread Srikanth Yalavarthi
Added internal structures to handle tile and OCM information and OCM to model memory mapping. Initialize the fields to platform specific defaults and compute the OCM / tile requirements for model. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.h | 5 ++ drivers/ml/cnxk/cn

[PATCH v1 20/37] ml/cnxk: enable support to update model params

2022-12-08 Thread Srikanth Yalavarthi
Added cnxk driver functions to update model params or weights and bias after a models is loaded. Updating model params would not require reloading the model. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 31 +++ 1 file changed, 31 insertions(

[PATCH v1 11/37] ml/cnxk: enable validity checks for model metadata

2022-12-08 Thread Srikanth Yalavarthi
Added model metadata structure and enabled metadata check during model load. Remap cnxk IO types with RTE IO types. Store and update model metadata in model structure. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_model.c | 196 +++ drivers/ml/cnxk/cn10k_ml_mode

[PATCH v1 19/37] ml/cnxk: enable support to get model information

2022-12-08 Thread Srikanth Yalavarthi
Added driver functions to get model information. Added internal functions to set and get model info. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_model.c | 54 drivers/ml/cnxk/cn10k_ml_model.h | 9 ++ drivers/ml/cnxk/cn10k_ml_ops.c | 37

[PATCH v1 09/37] ml/cnxk: add support to create device queue-pairs

2022-12-08 Thread Srikanth Yalavarthi
Enabled support to create and destroy device queue-pairs. Updated configure stage to create array to store queue-pair handles. Added internal structure for queue-pair, queue and ML inference requests. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 207 +++

[PATCH v1 18/37] ml/cnxk: enable support to stop an ML models

2022-12-08 Thread Srikanth Yalavarthi
Implemented model stop driver function. A model stop job is enqueued through scratch registers and is checked for completion through polling in a synchronous mode. OCM pages are released after model stop completion. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 115

[PATCH v1 08/37] ml/cnxk: enable support for device start and stop

2022-12-08 Thread Srikanth Yalavarthi
Implemented ML driver functions to start and stop ML device. Start / Stop would enable or disable ML device to accept inference requests. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_ops.c | 42 +++--- 1 file changed, 39 insertions(+), 3 deletions(-

[PATCH v1 17/37] ml/cnxk: enable support to start an ML model

2022-12-08 Thread Srikanth Yalavarthi
Implemented model start driver function. A model start job is checked for completion in synchronous mode. Tilemask and OCM slot is calculated before starting the model. Model start is enqueued through scratch registers. OCM pages are reserved after model start completion. Signed-off-by: Srikanth

[PATCH v1 06/37] ml/cnxk: enable firmware load and device reset

2022-12-08 Thread Srikanth Yalavarthi
Enabled support to load ML firmware on cn10ka ROC model. Reset MLIP device during dev_close driver operation. Device can't be reconfigured after a call to close. Job execution is disabled after firmware load, execution is enabled in device start state. Added internal request structure. Signed-off-

[PATCH v1 12/37] ml/cnxk: add internal structures for derived info

2022-12-08 Thread Srikanth Yalavarthi
Added internal structures to handle derived address fields and enabled support to compute DMA addresses for model start. Enabled updating internal model fields. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_model.c | 88 drivers/ml/cnxk/cn10k_ml

[PATCH v1 10/37] ml/cnxk: add functions to load and unload models

2022-12-08 Thread Srikanth Yalavarthi
Added cnxk driver implementations to load and unload ML models. Enabled support in configure stage to allocate model handles array. Assign model ID and allocate resources per each model during load stage and release resources during model unload. Added internal structures to handle ML models. Sign

[PATCH v1 05/37] ml/cnxk: parse ML firmware path from device args

2022-12-08 Thread Srikanth Yalavarthi
Enabled parsing ML firmware path for cn10k. Default path is set as "/lib/firmware/mlip-fw.bin", when args are not provided. Added internal structures for ML firmware. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.c | 71 ++ drivers/ml/cnxk/cn

[PATCH v1 04/37] ml/cnxk: add support for configure and close

2022-12-08 Thread Srikanth Yalavarthi
Implemented driver functions to configure and close ML devices. Added skeleton code and support to reconfigure ML device. PCI device remove is enabled in device close. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.c | 2 ++ drivers/ml/cnxk/cn10k_ml_dev.h | 21

[PATCH v1 07/37] ml/cnxk: enable support for simulator environment

2022-12-08 Thread Srikanth Yalavarthi
Enabled device initialization and firmware load on simulator platform. Firmware load stage on simulator would involve launching a firmware handshake request only. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.c | 119 + 1 file changed, 107 in

[PATCH v1 03/37] ml/cnxk: add driver support to get device info

2022-12-08 Thread Srikanth Yalavarthi
Added support to get the cn10k ML device information. This is a driver implementation for the RTE function rte_ml_dev_info_get. ML device on cn10k supports one queue-pair in lock-free mode and does not support segmented input output data. Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn

[PATCH v1 01/37] ml/cnxk: add skeleton for ML cnxk driver

2022-12-08 Thread Srikanth Yalavarthi
Added initial source files and build files for ML cnxk driver. Signed-off-by: Srikanth Yalavarthi --- Depends-on: patch-120600 ("common/cnxk: add ML headers and ROC code for cnxk") MAINTAINERS| 2 ++ drivers/meson.build| 1 + drivers/ml/cnxk/cn10k_ml_dev.c | 8

[PATCH v1 02/37] ml/cnxk: enable probe and remove of ML device

2022-12-08 Thread Srikanth Yalavarthi
ML inference engine on cn10k platform is a PCI based device. Added driver support to probe and remove the device for cn10k poll mode driver. The device is named by the PMD as "ml_cn10k". Signed-off-by: Srikanth Yalavarthi --- drivers/ml/cnxk/cn10k_ml_dev.c | 114 +

[PATCH v1 00/37] Implementation of ML CNXK driver

2022-12-08 Thread Srikanth Yalavarthi
Marvell ML CNXK Driver -- This patch series implements Machine Learning (ML) driver for Marvell Octeon 10 (cnxk) platform. ML inferencing is supported on cnxk platform through an integrated ML inferencing processor. The current driver supports programming the ML hardware engine

[PATCH v1 1/1] common/cnxk: add ML headers and ROC code for cnxk

2022-12-08 Thread Srikanth Yalavarthi
Added ML cnxk headers for register, structure definitions and ROC layer. Implemented ROC functions, registered logtype for ML module with the name pmd.ml.cnxk and defined ML hardware ID. Signed-off-by: Srikanth Yalavarthi --- Depends-on: series-26047 ("implementation of ML common code") MAINTAI

Re: [EXT] [PATCH 2/2] devtools: configure source repo to use as ABI reference

2022-12-08 Thread Thomas Monjalon
08/12/2022 19:14, Akhil Goyal: > > By default 'test-meson-builds.sh' script clones the repository which the > > script is in, and selects a configured branch ('DPDK_ABI_REF_VERSION') > > as a reference for ABI check. > > > > This patch enables selecting different repository to close for reference

[PATCH v1 4/4] common/ml: add Arm NEON type conversion routines

2022-12-08 Thread Srikanth Yalavarthi
Added ARM NEON intrinsic based implementations to support conversion of data types. Support is enabled to handle int8, uint8, int16, uint16, float16, float32 and bfloat16 types. Signed-off-by: Srikanth Yalavarthi --- drivers/common/ml/meson.build | 5 + drivers/common/ml/ml_utils.c |

[PATCH v1 3/4] common/ml: add generic type conversion functions

2022-12-08 Thread Srikanth Yalavarthi
Added generic implementations to support conversion of data types. Support is enabled to handle int8, uint8, int16, uint16, float16, float32 and bfloat16 types. Signed-off-by: Srikanth Yalavarthi --- drivers/common/ml/meson.build| 2 + drivers/common/ml/ml_utils.c | 86 +--- d

[PATCH v1 2/4] common/ml: add data type conversion routines

2022-12-08 Thread Srikanth Yalavarthi
Type conversion routines transform data from higher to lower precision data types or vice-versa. These conversion functions can be used by the ML driver implementations for quantization and de-quantization. Added driver routines for type conversion. These driver routines invoke the architecture sp

[PATCH v1 1/4] common/ml: add initial files for ML common code

2022-12-08 Thread Srikanth Yalavarthi
Added initial files for common ML driver code. Implemented ML type to size conversion, type to string and format to string conversion utility functions. Signed-off-by: Srikanth Yalavarthi --- Depends-on: series-26046 ("app/mldev: implement test framework for mldev") MAINTAINERS

  1   2   >