rte_bbdev.h(3)
π rte_bbdev.h π
okay bestie, welcome to rte_bbdev.h(3) from the Library Functions Manual β this is the wireless base band device abstraction API and it's lowkey iconic, so grab your strawberry milk π and let's go.
β¨ NAME β¨
rte_bbdev.h β the header itself, doing the most, serving wireless base band device abstraction APIs πΈ
π SYNOPSIS π
π includes, because we're cultured π
#include <stdint.h>
#include <stdbool.h>
#include <rte_compat.h>
#include <rte_cpuflags.h>
#include 'rte_bbdev_op.h'
#include 'rte_bbdev_trace_fp.h'
π¦ Data Structures π¦
struct rte_bbdev_queue_confstruct rte_bbdev_statsstruct rte_bbdev_driver_infostruct rte_bbdev_infostruct rte_bbdev_queue_info
π§ Macros π§
#define RTE_BBDEV_MAX_DEVS 128
#define RTE_BBDEV_FOREACH(i)
#define RTE_BBDEV_END_OF_CAPABILITIES_LIST()
#define RTE_BBDEV_NAME_MAX_LEN 64
π Typedefs π
typedef void(* rte_bbdev_cb_fn) (uint16_t dev_id, enum
rte_bbdev_event_type event, void *cb_arg, void *ret_param)
π Enumerations π
enum rte_bbdev_state
enum rte_bbdev_enqueue_status { RTE_BBDEV_ENQ_STATUS_NONE,
RTE_BBDEV_ENQ_STATUS_QUEUE_FULL, RTE_BBDEV_ENQ_STATUS_RING_FULL,
RTE_BBDEV_ENQ_STATUS_INVALID_OP }
enum rte_bbdev_device_status { RTE_BBDEV_DEV_NOSTATUS,
RTE_BBDEV_DEV_NOT_SUPPORTED, RTE_BBDEV_DEV_RESET,
RTE_BBDEV_DEV_CONFIGURED, RTE_BBDEV_DEV_ACTIVE,
RTE_BBDEV_DEV_FATAL_ERR, RTE_BBDEV_DEV_RESTART_REQ,
RTE_BBDEV_DEV_RECONFIG_REQ, RTE_BBDEV_DEV_CORRECT_ERR }
enum rte_bbdev_event_type { RTE_BBDEV_EVENT_UNKNOWN,
RTE_BBDEV_EVENT_ERROR, RTE_BBDEV_EVENT_DEQUEUE, RTE_BBDEV_EVENT_MAX
}
π Functions π
uint16_t rte_bbdev_count (void)
bool rte_bbdev_is_valid (uint16_t dev_id)
uint16_t rte_bbdev_find_next (uint16_t dev_id)
int rte_bbdev_setup_queues (uint16_t dev_id, uint16_t num_queues, int socket_id)
int rte_bbdev_intr_enable (uint16_t dev_id)
int rte_bbdev_queue_configure (uint16_t dev_id, uint16_t queue_id, const struct rte_bbdev_queue_conf *conf)
int rte_bbdev_start (uint16_t dev_id)
int rte_bbdev_stop (uint16_t dev_id)
int rte_bbdev_close (uint16_t dev_id)
int rte_bbdev_queue_start (uint16_t dev_id, uint16_t queue_id)
int rte_bbdev_queue_stop (uint16_t dev_id, uint16_t queue_id)
int rte_bbdev_stats_get (uint16_t dev_id, struct rte_bbdev_stats *stats)
int rte_bbdev_stats_reset (uint16_t dev_id)
int rte_bbdev_info_get (uint16_t dev_id, struct rte_bbdev_info *dev_info)
int rte_bbdev_queue_info_get (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_queue_info *queue_info)
RTE_TAILQ_HEAD (rte_bbdev_cb_list, rte_bbdev_callback)
static uint16_t rte_bbdev_enqueue_enc_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_enc_op **ops, uint16_t num_ops)
static uint16_t rte_bbdev_enqueue_dec_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_dec_op **ops, uint16_t num_ops)
static uint16_t rte_bbdev_enqueue_ldpc_enc_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_enc_op **ops, uint16_t num_ops)
static uint16_t rte_bbdev_enqueue_ldpc_dec_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_dec_op **ops, uint16_t num_ops)
static uint16_t rte_bbdev_enqueue_fft_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_fft_op **ops, uint16_t num_ops)
static uint16_t rte_bbdev_enqueue_mldts_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_mldts_op **ops, uint16_t num_ops)
static uint16_t rte_bbdev_dequeue_enc_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_enc_op **ops, uint16_t num_ops)
static uint16_t rte_bbdev_dequeue_dec_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_dec_op **ops, uint16_t num_ops)
static uint16_t rte_bbdev_dequeue_ldpc_enc_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_enc_op **ops, uint16_t num_ops)
static uint16_t rte_bbdev_dequeue_ldpc_dec_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_dec_op **ops, uint16_t num_ops)
static uint16_t rte_bbdev_dequeue_fft_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_fft_op **ops, uint16_t num_ops)
static uint16_t rte_bbdev_dequeue_mldts_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_mldts_op **ops, uint16_t num_ops)
int rte_bbdev_callback_register (uint16_t dev_id, enum rte_bbdev_event_type event, rte_bbdev_cb_fn cb_fn, void *cb_arg)
int rte_bbdev_callback_unregister (uint16_t dev_id, enum rte_bbdev_event_type event, rte_bbdev_cb_fn cb_fn, void *cb_arg)
int rte_bbdev_queue_intr_enable (uint16_t dev_id, uint16_t queue_id)
int rte_bbdev_queue_intr_disable (uint16_t dev_id, uint16_t queue_id)
int rte_bbdev_queue_intr_ctl (uint16_t dev_id, uint16_t queue_id, int epfd, int op, void *data)
const char * rte_bbdev_device_status_str (enum rte_bbdev_device_status status)
const char * rte_bbdev_enqueue_status_str (enum rte_bbdev_enqueue_status status)
__rte_experimental int rte_bbdev_queue_ops_dump (uint16_t dev_id, uint16_t queue_index, FILE *file)
__rte_experimental char * rte_bbdev_ops_param_string (void *op, enum rte_bbdev_op_type op_type, char *str, uint32_t len)
__rte_experimental void rte_bbdev_ops_trace (void *op, enum rte_bbdev_op_type op_type)
πΈ Detailed Description πΈ
Wireless base band device abstraction APIs.
This API lets an app discover, configure and use a device to process operations, bestie. It's asynchronous β so you enqueue, and then later you dequeue, and that's the whole loop, no cap. π
β οΈ Vibe check / warning zone: the functions in this API are not thread-safe when called on the same target object (a device, or a queue on a device) β with one exception: one thread can enqueue operations to a queue while another thread dequeues from that same queue. That's it. That's the only slay-approved concurrent move. π
Definition in file rte_bbdev.h.
β¨ Macro Definition Documentation β¨
π #define RTE_BBDEV_MAX_DEVS 128 π
Max number of devices π―
Definition at line 38 of file rte_bbdev.h.
π #define RTE_BBDEV_FOREACH( i) π
Value:
for (i = rte_bbdev_find_next(-1); \
i < RTE_BBDEV_MAX_DEVS; \
i = rte_bbdev_find_next(i))
Iterate through all enabled devices β literally the "for each one of u girlies" of bbdev π«Ά
Definition at line 89 of file rte_bbdev.h.
π #define RTE_BBDEV_END_OF_CAPABILITIES_LIST() π
Value:
{ RTE_BBDEV_OP_NONE }
Macro used at end of bbdev PMD list β it's the "okay that's everyone, pack it up" marker π¬
Definition at line 364 of file rte_bbdev.h.
π #define RTE_BBDEV_NAME_MAX_LEN 64 π
Max length of device name β keep those names short and cute, 64 chars max β¨
Definition at line 479 of file rte_bbdev.h.
π¦ Typedef Documentation π¦
π§ typedef void(* rte_bbdev_cb_fn) (uint16_t dev_id, enum rte_bbdev_event_type event, void *cb_arg, void *ret_param) π§
Typedef for the application callback function that application software registers for notification of device events. Yes, it's your "text me when this happens" function π²
Parameters
dev_idβ Device identifiereventβ Device event to register for notification of.cb_argβ User specified parameter to be passed to user's callback function.ret_paramβ To pass data back to user application.
Definition at line 968 of file rte_bbdev.h.
π Enumeration Type Documentation π
π enum rte_bbdev_state π
Flags indicate current state of BBDEV device π
Definition at line 49 of file rte_bbdev.h.
π enum rte_bbdev_enqueue_status π
Flags to indicate the reason why a previous enqueue may not have consumed all requested operations. In case of multiple reasons the latter supersedes a previous one. The related macro RTE_BBDEV_ENQ_STATUS_SIZE_MAX can be used as an absolute maximum for notably sizing array while allowing for future enumeration insertion. So like, size your arrays with that and you're future-proofed, iykyk β¨
Enumerator
RTE_BBDEV_ENQ_STATUS_NONEβ Nothing to report. all good babe π«ΆRTE_BBDEV_ENQ_STATUS_QUEUE_FULLβ Not enough room in queue.RTE_BBDEV_ENQ_STATUS_RING_FULLβ Not enough room in ring.RTE_BBDEV_ENQ_STATUS_INVALID_OPβ Operation was rejected as invalid. π«
Definition at line 244 of file rte_bbdev.h.
π enum rte_bbdev_device_status π
Flags to indicate the status of the device.
Enumerator
RTE_BBDEV_DEV_NOSTATUSβ Nothing being reported.RTE_BBDEV_DEV_NOT_SUPPORTEDβ Device status is not supported on the PMD.RTE_BBDEV_DEV_RESETβ Device in reset and un-configured state.RTE_BBDEV_DEV_CONFIGUREDβ Device is configured and ready to use. βRTE_BBDEV_DEV_ACTIVEβ Device is configured and VF is being used. π₯RTE_BBDEV_DEV_FATAL_ERRβ Device has hit a fatal uncorrectable error. πRTE_BBDEV_DEV_RESTART_REQβ Device requires application to restart.RTE_BBDEV_DEV_RECONFIG_REQβ Device requires application to reconfigure queues.RTE_BBDEV_DEV_CORRECT_ERRβ Warning of a correctable error event happened.
Definition at line 255 of file rte_bbdev.h.
π enum rte_bbdev_event_type π
Definitions of device event types β the group chat notification categories π¬
Enumerator
RTE_BBDEV_EVENT_UNKNOWNβ unknown event typeRTE_BBDEV_EVENT_ERRORβ error interrupt eventRTE_BBDEV_EVENT_DEQUEUEβ dequeue eventRTE_BBDEV_EVENT_MAXβ max value of this enum
Definition at line 948 of file rte_bbdev.h.
π Function Documentation π
π« uint16_t rte_bbdev_count (void ) π«
Get the total number of devices that have been successfully initialised.
Returns
The total number of usable devices.
π« bool rte_bbdev_is_valid (uint16_t dev_id) π«
Check if a device is valid.
Parameters
dev_idβ The identifier of the device.
Returns
true if device ID is valid and device is attached, false otherwise.
π« uint16_t rte_bbdev_find_next (uint16_t dev_id) π«
Get the next enabled device.
Parameters
dev_idβ The current device
Returns
- The next device, or
RTE_BBDEV_MAX_DEVSif none found
π« int rte_bbdev_setup_queues (uint16_t dev_id, uint16_t num_queues, int socket_id) π«
Setup up device queues. This function must be called on a device before setting up the queues and starting the device. It can also be called when a device is in the stopped state.
π¨ bestie listen: if any device queues have been configured, their configuration will be cleared by a call to this function. Poof. Gone. So don't call this on a device you've already lovingly configured unless you mean it. π
Parameters
dev_idβ The identifier of the device.num_queuesβ Number of queues to configure on device.socket_idβ ID of a socket which will be used to allocate memory.
Returns
0on success-ENODEVifdev_idis invalid or the device is corrupted-EINVALifnum_queuesis invalid,0or greater than maximum-EBUSYif the identified device has already started-ENOMEMif unable to allocate memory
π« int rte_bbdev_intr_enable (uint16_t dev_id) π«
Enable interrupts. This function may be called before starting the device to enable the interrupts if they are available.
Parameters
dev_idβ The identifier of the device.
Returns
0on success-ENODEVifdev_idis invalid or the device is corrupted-EBUSYif the identified device has already started-ENOTSUPif the interrupts are not supported by the device
rte_bbdev_queue_configure</p> π
int rte_bbdev_queue_configure (uint16_t dev_id, uint16_t queue_id, const struct rte_bbdev_queue_conf * conf)
okay so this one configures a queue on a device π you can call it after the device is configured and before you start it. you can also call it while the device or the queue is just chillin in the stopped state. so flexible, we love her.
Parameters
dev_idβ the identifier of the device, bestie.queue_idβ the index of the queue.confβ the queue configuration. and get this, if it'sNULL, a default configuration will be used. iconic default behaviour fr fr β¨
Returns
0on success πΈEINVALif the identified queue size or priority are invalid πEBUSYif the identified queue or its device have already started π
rte_bbdev_start π₯
int rte_bbdev_start (uint16_t dev_id)
starts a device! this is literally the last step you need before enqueueing operations is even possible. main character moment for real π
Parameters
dev_idβ the identifier of the device.
Returns
0on success β- negative value on failure β as returned from PMD π
rte_bbdev_stop πΈ
int rte_bbdev_stop (uint16_t dev_id)
stops a device. and the glow-up potential?? the device can be reconfigured and restarted after being stopped. she's not gone, she's just resting π
Parameters
dev_idβ the identifier of the device.
Returns
0on success β¨
rte_bbdev_close π
int rte_bbdev_close (uint16_t dev_id)
closes a device. and bestie, be so serious right now β the device cannot be restarted without reconfiguration! it's giving permanent. no takebacks. no cap π«Ά
Parameters
dev_idβ the identifier of the device.
Returns
0on success β
rte_bbdev_queue_start π¦
int rte_bbdev_queue_start (uint16_t dev_id, uint16_t queue_id)
starts a specified queue on a device. you only need this if the queue has been stopped, or if the deferred_start flag was set when you were configuring the queue. so basically the queue was on pause and now she's back π
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.
Returns
0on success π- negative value on failure β as returned from PMD π
rte_bbdev_queue_stop π
int rte_bbdev_queue_stop (uint16_t dev_id, uint16_t queue_id)
stops a specified queue on a device, so you can re configure it. it's the queue version of "brb gotta change my outfit" π§
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.
Returns
0on success β¨- negative value on failure β as returned from PMD π
rte_bbdev_stats_get π
int rte_bbdev_stats_get (uint16_t dev_id, struct rte_bbdev_stats * stats)
pulls the general I/O statistics of a device. the receipts, if you will π
Parameters
dev_idβ the identifier of the device.statsβ pointer to structure to where statistics will be copied. and heads up: on error, this location may or may not have been modified. so don't come for her if it's ambiguous π
Returns
0on success βEINVALif invalid parameter pointer is provided π
rte_bbdev_stats_reset π
int rte_bbdev_stats_reset (uint16_t dev_id)
resets the statistics of a device. fresh start, clean slate, new era β¨
Parameters
dev_idβ the identifier of the device.
Returns
0on success π
rte_bbdev_info_get β
int rte_bbdev_info_get (uint16_t dev_id, struct rte_bbdev_info * dev_info)
retrieves information about a device. she's an open book, bestie π
Parameters
dev_idβ the identifier of the device.dev_infoβ pointer to structure to where information will be copied. on error, this location may or may not have been modified. yep, same caveat, same energy π
Returns
0on success πEINVALif invalid parameter pointer is provided π
rte_bbdev_queue_info_get π
int rte_bbdev_queue_info_get (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_queue_info * queue_info)
retrieves information about a specific queue on a device. not the whole device, just that one queue. very targeted, very focused, very slay π
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.queue_infoβ pointer to structure to where information will be copied. on error, this location may or may not have been modified (yes, again, it's a whole thing) π«Ά
Returns
0on success πΈEINVALif invalid parameter pointer is provided π
RTE_TAILQ_HEAD (rte_bbdev_cb_list, rte_bbdev_callback) π
structure to keep track of registered callbacks. it's literally the group chat member list of callbacks, keeping everyone accounted for π
rte_bbdev_enqueue_enc_ops π₯ [inline], [static]
uint16_t rte_bbdev_enqueue_enc_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_enc_op ** ops, uint16_t num_ops)
enqueues a burst of processed encode operations to a queue of the device. and okay, key detail: this function only enqueues as many operations as are currently possible β it does not block until num_ops entries in the queue are available. so no waiting around, no queuing up dramatically. also it does not provide any error notification, to avoid the corresponding overhead. silent but efficient, we respect it π
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.opsβ pointer array containing operations to be enqueued. must have at leastnum_opsentries.num_opsβ the maximum number of operations to enqueue.
Returns
the number of operations actually enqueued (this is the number of processed entries in the ops array). β¨
Definition at line 569 of file rte_bbdev.h.
rte_bbdev_enqueue_dec_ops π [inline], [static]
uint16_t rte_bbdev_enqueue_dec_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_dec_op ** ops, uint16_t num_ops)
enqueues a burst of processed decode operations to a queue of the device. same deal as her sister: only enqueues as many as currently possible, does not block until num_ops entries are available. and again, no error notification, to avoid the corresponding overhead. π€«
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.opsβ pointer array containing operations to be enqueued. must have at leastnum_opsentries.num_opsβ the maximum number of operations to enqueue.
Returns
the number of operations actually enqueued (this is the number of processed entries in the ops array). πΈ
Definition at line 601 of file rte_bbdev.h.
rte_bbdev_enqueue_ldpc_enc_ops π¦ [inline], [static]
uint16_t rte_bbdev_enqueue_ldpc_enc_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_enc_op ** ops, uint16_t num_ops)
enqueues a burst of processed encode operations to a queue of the device. yes bestie, it's the LDPC flavor. still only enqueues as many operations as currently possible, still does not block until num_ops entries are available, still no error notification to avoid the corresponding overhead. consistent queen π
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.opsβ pointer array containing operations to be enqueued. must have at leastnum_opsentries.num_opsβ the maximum number of operations to enqueue.
Returns
the number of operations actually enqueued (this is the number of processed entries in the ops array). β
Definition at line 633 of file rte_bbdev.h.
rte_bbdev_enqueue_ldpc_dec_ops π [inline], [static]
uint16_t rte_bbdev_enqueue_ldpc_dec_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_dec_op ** ops, uint16_t num_ops)
enqueues a burst of processed decode operations to a queue of the device β the LDPC decode one π same rules apply: enqueues only as many as currently possible, does not block until num_ops entries in the queue are available, and gives you zero error notification to dodge the overhead.
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.opsβ pointer array containing operations to be enqueued. must have at leastnum_opsentries.num_opsβ the maximum number of operations to enqueue.
Returns
the number of operations actually enqueued (this is the number of processed entries in the ops array). β¨
Definition at line 665 of file rte_bbdev.h.
rte_bbdev_enqueue_fft_ops π [inline], [static]
uint16_t rte_bbdev_enqueue_fft_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_fft_op ** ops, uint16_t num_ops)
enqueues a burst of FFT operations to a queue of the device. and yeah, same vibe as the rest: it only enqueues as many operations as currently possible and does not block until num_ops entries in the queue are available. no error notification either, to avoid the corresponding overhead. π§
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.opsβ pointer array containing operations to be enqueued. must have at leastnum_opsentries.num_opsβ the maximum number of operations to enqueue.
Returns
the number of operations actually enqueued. (this is the number of processed entries in the ops array.) π
Definition at line 697 of file rte_bbdev.h.
rte_bbdev_enqueue_mldts_ops π₯ [inline], [static]
uint16_t rte_bbdev_enqueue_mldts_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_mldts_op ** ops, uint16_t num_ops)
enqueues a burst of MLDTS operations to a queue of the device. say it with me now: only enqueues as many operations as currently possible, does not block until num_ops entries in the queue are available, no error notification, overhead avoided. π
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.opsβ pointer array containing operations to be enqueued. must have at leastnum_opsentries.num_opsβ the maximum number of operations to enqueue.
Returns
the number of operations actually enqueued (this is the number of processed entries in the ops array). π
Definition at line 729 of file rte_bbdev.h.
rte_bbdev_dequeue_enc_ops π [inline], [static]
uint16_t rte_bbdev_dequeue_enc_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_enc_op ** ops, uint16_t num_ops)
dequeues a burst of processed encode operations from a queue of the device. important: this function returns only the current contents of the queue, and does not block until @ num_ops is available. and nope, no error notification, because overhead said no. π
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.opsβ pointer array where operations will be dequeued to. must have at leastnum_opsentries, i.e. a pointer to a table ofvoid *pointers (ops) that will be filled.num_opsβ the maximum number of operations to dequeue.
Returns
the number of operations actually dequeued. (this is the number of entries copied into the ops array.) β
Definition at line 762 of file rte_bbdev.h.
rte_bbdev_dequeue_dec_ops π [inline], [static]
uint16_t rte_bbdev_dequeue_dec_ops (uint16_t dev_id, uint16_t queue_id, struct rte_bbdev_dec_op ** ops, uint16_t num_ops)
dequeues a burst of processed decode operations from a queue of the device. she also returns just the current contents of the queue and does not block until @ num_ops is available. and once more for the people in the back: no error notification, no overhead. π«Ά
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.opsβ pointer array where operations will be dequeued to. must have at leastnum_opsentries ie. a pointer to a table ofvoid *pointers (ops) that will be filled.num_opsβ the maximum number of operations to dequeue.
Returns
the number of operations actually dequeued (this is the number of entries copied into the ops array). π
Definition at line 798 of file rte_bbdev.h.
rte_bbdev_dequeue_ldpc_enc_ops β¨
uint16_t rte_bbdev_dequeue_ldpc_enc_ops (uint16_t dev_id, uint16_t queue_id,
struct rte_bbdev_enc_op ** ops, uint16_t num_ops) [inline], [static]
Grabs a burst of already-processed encode operations off a queue on the device, bestie. Heads up tho β this function hands you only whatever is sitting in the queue right this second. It does not block waiting for num_ops to show up. And it silently skips error notification, because who has the time for that overhead, honestly. π
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.opsβ pointer array where operations will be dequeued to. Must have at leastnum_opsentries.num_opsβ the maximum number of operations to dequeue.
Returns
The number of operations actually dequeued β which is literally just the number of entries copied into the ops array.
Definition at line 833 of file rte_bbdev.h.
rte_bbdev_dequeue_ldpc_dec_ops π
uint16_t rte_bbdev_dequeue_ldpc_dec_ops (uint16_t dev_id, uint16_t queue_id,
struct rte_bbdev_dec_op ** ops, uint16_t num_ops) [inline], [static]
Same energy, but for decode. Dequeues a burst of processed decode operations from a queue of the device. It returns the current contents of the queue and nothing else, no blocking until num_ops is available. And again, no error notification, because overhead said no. π«Ά
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.opsβ pointer array where operations will be dequeued to. Must have at leastnum_opsentries.num_opsβ the maximum number of operations to dequeue.
Returns
The number of operations actually dequeued (the number of entries copied into the ops array).
Definition at line 867 of file rte_bbdev.h.
rte_bbdev_dequeue_fft_ops π¦
uint16_t rte_bbdev_dequeue_fft_ops (uint16_t dev_id, uint16_t queue_id,
struct rte_bbdev_fft_op ** ops, uint16_t num_ops) [inline], [static]
You guessed it β FFT edition. Dequeues a burst of FFT operations from a queue of the device. Current queue contents only, no blocking until num_ops is available, and no error notification to dodge the overhead. Iconic behaviour, truly. β¨
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.opsβ pointer array where operations will be dequeued to. Must have at leastnum_opsentries.num_opsβ the maximum number of operations to dequeue.
Returns
The number of operations actually dequeued (the number of entries copied into the ops array).
Definition at line 901 of file rte_bbdev.h.
rte_bbdev_dequeue_mldts_ops πΈ
uint16_t rte_bbdev_dequeue_mldts_ops (uint16_t dev_id, uint16_t queue_id,
struct rte_bbdev_mldts_op ** ops, uint16_t num_ops) [inline], [static]
The MLDTS one, let's go. Dequeues a burst of MLDTS operations from a queue of the device. Returns only the current contents of the queue, does not block until num_ops is available, and provides zero error notification so it can skip that overhead entirely. π
Parameters
dev_idβ the identifier of the device.queue_idβ the index of the queue.opsβ pointer array where operations will be dequeued to. Must have at leastnum_opsentries.num_opsβ the maximum number of operations to dequeue.
Returns
The number of operations actually dequeued (the number of entries copied into the ops array).
Definition at line 935 of file rte_bbdev.h.
rte_bbdev_callback_register π
int rte_bbdev_callback_register (uint16_t dev_id, enum rte_bbdev_event_type event,
rte_bbdev_cb_fn cb_fn, void * cb_arg)
Registers a callback function for a specific device id. And the best part? You can stack multiple callbacks, and they'll all get called in the exact order you added them whenever an event fires. They run on a separate thread created by the DPDK EAL, so no, they're not chilling on your thread. π
Parameters
dev_idβ device id.eventβ the event that the callback will be registered for.cb_fnβ user supplied callback function to be called.cb_argβ pointer to parameter that will be passed to the callback.
Returns
Zero on success, negative value on failure. π
rte_bbdev_callback_unregister π
int rte_bbdev_callback_unregister (uint16_t dev_id, enum rte_bbdev_event_type event,
rte_bbdev_cb_fn cb_fn, void * cb_arg)
Unregisters a callback function for a specific device id. Breaking up is hard, but it's necessary.
Parameters
dev_idβ the device identifier.eventβ the event that the callback will be unregistered for.cb_fnβ user supplied callback function to be unregistered.cb_argβ pointer to the parameter supplied when registering the callback.(void *)-1means to remove all registered callbacks with the specified function address.
Returns
0on successEINVALif invalid parameter pointer is providedEAGAINif the provided callback pointer does not exist
rte_bbdev_queue_intr_enable π₯
int rte_bbdev_queue_intr_enable (uint16_t dev_id, uint16_t queue_id)
Turns on a one-shot interrupt for the next operation enqueued to a particular queue. The interrupt fires once that operation is ready to be dequeued. To actually deal with the interrupt, you register an epoll file descriptor with rte_bbdev_queue_intr_ctl(), and then some application thread or lcore waits it out with rte_epoll_wait(). Periodt. π
Parameters
dev_idβ the device identifier.queue_idβ the index of the queue.
Returns
0on success- negative value on failure β as returned from PMD
rte_bbdev_queue_intr_disable π
int rte_bbdev_queue_intr_disable (uint16_t dev_id, uint16_t queue_id)
Switches off that one-shot interrupt for the next operation enqueued to a particular queue β if it had been enabled in the first place, no cap.
Parameters
dev_idβ the device identifier.queue_idβ the index of the queue.
Returns
0on success- negative value on failure β as returned from PMD
rte_bbdev_queue_intr_ctl π§
int rte_bbdev_queue_intr_ctl (uint16_t dev_id, uint16_t queue_id, int epfd,
int op, void * data)
The control interface for per-queue interrupts. This is the remote, bestie.
Parameters
dev_idβ the device identifier.queue_idβ the index of the queue.epfdβ epoll file descriptor that will be associated with the interrupt source. If the special valueRTE_EPOLL_PER_THREADis provided, a per-thread epoll file descriptor created by the EAL is used (RTE_EPOLL_PER_THREADcan also be used when callingrte_epoll_wait()).opβ the operation be performed for the vector.RTE_INTR_EVENT_ADDorRTE_INTR_EVENT_DEL.dataβ user context, that will be returned in theepdata.datafield of therte_epoll_eventstructure filled in byrte_epoll_wait().
Returns
0on successENOTSUPif interrupts are not supported by the identified device- negative value on failure β as returned from PMD
rte_bbdev_device_status_str β
const char * rte_bbdev_device_status_str (enum rte_bbdev_device_status status)
Converts a device status from enum to string. Glow-up, but for types. β¨
Parameters
statusβ device status as enum.
Returns
Device status as string, or NULL if invalid. π
rte_bbdev_enqueue_status_str π
const char * rte_bbdev_enqueue_status_str (enum rte_bbdev_enqueue_status status)
Converts a queue status from enum to string.
Parameters
statusβ queue status as enum.
Returns
Queue status as string, or NULL if op_type is invalid.
rte_bbdev_queue_ops_dump π
__rte_experimental int rte_bbdev_queue_ops_dump (uint16_t dev_id, uint16_t queue_index, FILE * file)
Dumps operations info from the device to a file. Ngl, this API is for debugging the input operations you feed it β it is not a dataplane API, so please don't put it on the hot path, bestie. Tagged __rte_experimental, iykyk. π§ͺ
Parameters
dev_idβ the device identifier.queue_indexβ index of queue.fileβ a pointer to a file for output.
Returns
0on successENOTSUPif interrupts are not supported by the identified device- negative value on failure β as returned from PMD
rte_bbdev_ops_param_string π
__rte_experimental char * rte_bbdev_ops_param_string (void * op, enum rte_bbdev_op_type op_type,
char * str, uint32_t len)
Gives you a string of parameters related to the parameters of an operation of a given type. Also __rte_experimental, so tread gently. πΈ
Parameters
opβ pointer to an operation.op_typeβ operation type enum.strβ string being describing the operations.lenβ size of the string buffer.
Returns
String describing the provided operation.
rte_bbdev_ops_trace π
__rte_experimental void rte_bbdev_ops_trace (void * op, enum rte_bbdev_op_type op_type)
Drops a trace with the detail of an operation. Another __rte_experimental one, so peek responsibly. π
Parameters
opβ pointer to an operation.op_typeβ operation type enum.
π Author π
Generated automatically by Doxygen for DPDK from the source code. Not me hand-typing it, the robots did that part fr fr. π€π
And that's the whole thing, bestie! This absolute unit of a man page is from DPDK, Version 25.11.3, and it's the rte_bbdev.h(3) page. Go forth and dequeue responsibly. π¦β¨π
π¦ where this page comes from
- ubuntu resolute: dpdk-doc 25.11.3-0ubuntu0.26.04.1 Β· BSD-3-Clause
- ubuntu stonking: dpdk-doc 25.11.3-1 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms