function lfds710_queue_umm_enqueue

From liblfds.org
Jump to: navigation, search

Source Files

└───liblfds710
    ├───inc
    │   └───liblfds710
    │           lfds710_queue_umm.h
    └───src
        └───lfds710_queue
                lfds710_queue_umm_enqueue.c

Opaque Structures

struct lfds710_queue_umm_element;
struct lfds710_queue_umm_state;

Prototype

void lfds710_queue_umm_enqueue( struct lfds710_queue_umm_state *qumms,
                                struct lfds710_queue_umm_element *qumme );

Parameters

struct lfds710_queue_umm_state *qumms

A pointer to an initialized struct lfds710_queue_umm_state.

struct lfds710_queue_umm_state *qumme

A pointer to a user-allocated LFDS710_PAL_ATOMIC_ISOLATION_IN_BYTES aligned struct lfds710_queue_umm_element. Stack declared variables will automatically be correctly aligned by the compiler, due to the information in the structure definitions; nothing has to be done. Heap allocated variables however will by no means be correctly aligned and an aligned malloc must be used.

Notes

This function enqueues a queue element, with its key and value, onto the queue. The key and value are both optional, are set by the macros LFDS710_QUEUE_UMM_SET_KEY_IN_ELEMENT and LFDS710_QUEUE_UMM_SET_VALUE_IN_ELEMENT respectively, and can only be set when a queue element is outside of a queue.

See Also