Zephyr API Documentation 4.0.0-rc2
A Scalable Open Source RTOS
Loading...
Searching...
No Matches

RTIO CQE Flags . More...

Macros

#define RTIO_CQE_FLAG_MEMPOOL_BUFFER   BIT(0)
 The entry's buffer was allocated from the RTIO's mempool.
 
#define RTIO_CQE_FLAG_GET(flags)
 
#define RTIO_CQE_FLAG_MEMPOOL_GET_BLK_IDX(flags)
 Get the block index of a mempool flags.
 
#define RTIO_CQE_FLAG_MEMPOOL_GET_BLK_CNT(flags)
 Get the block count of a mempool flags.
 
#define RTIO_CQE_FLAG_PREP_MEMPOOL(blk_idx, blk_cnt)
 Prepare CQE flags for a mempool read.
 

Detailed Description

RTIO CQE Flags .

Macro Definition Documentation

◆ RTIO_CQE_FLAG_GET

#define RTIO_CQE_FLAG_GET ( flags)

#include <zephyr/rtio/rtio.h>

Value:
#define GENMASK(h, l)
Create a contiguous bitmask starting at bit position l and ending at position h.
Definition util.h:79
#define FIELD_GET(mask, value)
Extract a bitfield element from value corresponding to the field mask mask.
Definition util_macro.h:103
flags
Definition parser.h:96

◆ RTIO_CQE_FLAG_MEMPOOL_BUFFER

#define RTIO_CQE_FLAG_MEMPOOL_BUFFER   BIT(0)

#include <zephyr/rtio/rtio.h>

The entry's buffer was allocated from the RTIO's mempool.

If this bit is set, the buffer was allocated from the memory pool and should be recycled as soon as the application is done with it.

◆ RTIO_CQE_FLAG_MEMPOOL_GET_BLK_CNT

#define RTIO_CQE_FLAG_MEMPOOL_GET_BLK_CNT ( flags)

#include <zephyr/rtio/rtio.h>

Value:
FIELD_GET(GENMASK(31, 20), (flags))

Get the block count of a mempool flags.

Parameters
flagsThe CQE flags value
Returns
The block count portion of the flags field.

◆ RTIO_CQE_FLAG_MEMPOOL_GET_BLK_IDX

#define RTIO_CQE_FLAG_MEMPOOL_GET_BLK_IDX ( flags)

#include <zephyr/rtio/rtio.h>

Value:

Get the block index of a mempool flags.

Parameters
flagsThe CQE flags value
Returns
The block index portion of the flags field.

◆ RTIO_CQE_FLAG_PREP_MEMPOOL

#define RTIO_CQE_FLAG_PREP_MEMPOOL ( blk_idx,
blk_cnt )

#include <zephyr/rtio/rtio.h>

Value:
FIELD_PREP(GENMASK(19, 8), blk_idx) | FIELD_PREP(GENMASK(31, 20), blk_cnt))
#define RTIO_CQE_FLAG_MEMPOOL_BUFFER
The entry's buffer was allocated from the RTIO's mempool.
Definition rtio.h:160
#define FIELD_PREP(mask, value)
Prepare a bitfield element using value with mask representing its field position and width.
Definition util_macro.h:110

Prepare CQE flags for a mempool read.

Parameters
blk_idxThe mempool block index
blk_cntThe mempool block count
Returns
A shifted and masked value that can be added to the flags field with an OR operator.