]> git.droids-corp.org - dpdk.git/commit
crypto/cnxk: add CPT hardware flow control checks
authorAnoob Joseph <anoobj@marvell.com>
Mon, 20 Jun 2022 11:59:03 +0000 (17:29 +0530)
committerAkhil Goyal <gakhil@marvell.com>
Tue, 21 Jun 2022 18:04:50 +0000 (20:04 +0200)
commit53668249c558efaa55efc9a63f162819a33c6f3a
tree7dc737d0b7452717b7ba7ea84632e77e5ddd42f1
parentfac05e48e349ac56455c73bae811a7096b8e2b4c
crypto/cnxk: add CPT hardware flow control checks

Add hardware supported flow control checks before enqueueing to CPT.
Since both poll mode and event mode can be used at the same time, add
hardware flow control checks to make sure s/w doesn't over submit to
hardware queues. For cn9k, queue depth usage is not high and so FC check
is omitted for poll mode.

To allow for more accurate updates, flow control hardware setting is
updated to give an update per 32 packets. In case of crypto adapter,
multiple cores can enqueue to the same CPT LF at the same time. To
allow such a case, flow control threshold is updated when the adapter
is configured.

Signed-off-by: Anoob Joseph <anoobj@marvell.com>
Acked-by: Akhil Goyal <gakhil@marvell.com>
drivers/common/cnxk/hw/cpt.h
drivers/common/cnxk/roc_cpt.c
drivers/common/cnxk/roc_cpt.h
drivers/crypto/cnxk/cn10k_cryptodev_ops.c
drivers/crypto/cnxk/cn9k_cryptodev_ops.c
drivers/event/cnxk/cnxk_eventdev.c