]> git.droids-corp.org - dpdk.git/commit
event/dlb2: improve enqueue efficiency
authorTimothy McDaniel <timothy.mcdaniel@intel.com>
Mon, 6 Jun 2022 15:29:53 +0000 (10:29 -0500)
committerJerin Jacob <jerinj@marvell.com>
Thu, 9 Jun 2022 16:30:48 +0000 (18:30 +0200)
commit87ecdd9e7fbfe3d734a9f80c4f49b526835a57b4
tree6764b4466823f8799557d5a4d190a9adecc23b0d
parentd430b921a4d7c5449f6e99b5ba40671b27d87adb
event/dlb2: improve enqueue efficiency

If user tried to send 64 events, it will take 64 credits. Enqueue API
only gets 32 credits each time. If it does not have sufficient credits,
it just fails and returns. Enqueue API does not retry. On next enqueue,
it will get 32 more and send will work. This results in alternate
enqueues failing.

Add check to make sure DLB2_MAX_ENQUEUE_DEPTH <=
both DLB2_SW_CREDIT_QUANTA_DEFAULT and DLB2_SW_CREDIT_BATCH_SZ.

Add enough retires in the driver to satisfy max enqueue depth credits
based on set quanta. Note the credit quanta size is different for each
port. Retry count = Max enqueue depth / credit quanta in driver before
returning no credit.

Fixes: 3a6d0c04e7fb ("event/dlb2: add port setup")
Cc: stable@dpdk.org
Signed-off-by: Timothy McDaniel <timothy.mcdaniel@intel.com>
drivers/event/dlb2/dlb2.c
drivers/event/dlb2/dlb2_priv.h