VSF Documented
vsf_eda_slist_queue.h
Go to the documentation of this file.
1/*****************************************************************************
2 * Copyright(C)2009-2022 by VSF Team *
3 * *
4 * Licensed under the Apache License, Version 2.0 (the "License"); *
5 * you may not use this file except in compliance with the License. *
6 * You may obtain a copy of the License at *
7 * *
8 * http://www.apache.org/licenses/LICENSE-2.0 *
9 * *
10 * Unless required by applicable law or agreed to in writing, software *
11 * distributed under the License is distributed on an "AS IS" BASIS, *
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. *
13 * See the License for the specific language governing permissions and *
14 * limitations under the License. *
15 * *
16 ****************************************************************************/
17
18#ifndef __VSF_EDA_SLIST_QUEUE_H__
19#define __VSF_EDA_SLIST_QUEUE_H__
20
21/*============================ INCLUDES ======================================*/
23
24#if VSF_USE_KERNEL == ENABLED
25
26#if defined(__VSF_EDA_SLIST_QUEUE_CLASS_IMPLEMENT)
27# undef __VSF_EDA_SLIST_QUEUE_CLASS_IMPLEMENT
28# define __VSF_CLASS_IMPLEMENT__
29#elif defined(__VSF_EDA_SLIST_QUEUE_CLASS_INHERIT__)
30# undef __VSF_EDA_SLIST_QUEUE_CLASS_INHERIT__
31# define __VSF_CLASS_INHERIT__
32#endif
33
34#include "utilities/ooc_class.h"
35
36#ifdef __cplusplus
37extern "C" {
38#endif
39
40/*============================ MACROS ========================================*/
41
42#if VSF_KERNEL_CFG_SUPPORT_SLIST_QUEUE == ENABLED
43
44# define vsf_msg_queue_t vsf_eda_slist_queue_t
45# define vsf_eda_msg_queue_init(__queue, __max) \
46 vsf_eda_slist_queue_init((__queue), (__max))
47# define vsf_eda_msg_queue_send(__queue, __node, __timeout) \
48 vsf_eda_queue_send((vsf_eda_queue_t *)(__queue), (__node), (__timeout))
49# define vsf_eda_msg_queue_send_get_reason(__queue, __evt, __node) \
50 vsf_eda_queue_send_get_reason((vsf_eda_queue_t *)(__queue), (__evt), (__node))
51# define vsf_eda_msg_queue_recv(__queue, __node, __timeout) \
52 vsf_eda_queue_recv((vsf_eda_queue_t *)(__queue), (void **)(__node), (__timeout))
53# define vsf_eda_msg_queue_recv_get_reason(__queue, __evt, __node) \
54 vsf_eda_queue_recv_get_reason((vsf_eda_queue_t *)(__queue), (__evt), (void **)(__node))
55
56#endif
57
58/*============================ MACROFIED FUNCTIONS ===========================*/
59/*============================ TYPES =========================================*/
60
61#if VSF_KERNEL_CFG_SUPPORT_SLIST_QUEUE == ENABLED
62
64 public_member(
65 implement(vsf_eda_queue_t)
66 )
67 private_member(
69 )
70};
71
72#endif
73
74/*============================ GLOBAL VARIABLES ==============================*/
75/*============================ PROTOTYPES ====================================*/
76
77#if VSF_KERNEL_CFG_SUPPORT_SLIST_QUEUE == ENABLED
79#endif
80
81#ifdef __cplusplus
82}
83#endif
84
85#endif
86#endif // __VSF_EDA_SLIST_QUEUE_H__
vsf_err_t
Definition __type.h:42
Definition vsf_eda.h:996
Definition vsf_eda_slist_queue.h:63
#define max(x, y)
Definition minmax.h:12
#define vsf_class(__name)
Definition ooc_class.h:48
unsigned short uint_fast16_t
Definition stdint.h:25
Definition vsf_list.h:896
vsf_err_t vsf_eda_slist_queue_init(vsf_eda_slist_queue_t *this_ptr, uint_fast16_t max)
Definition vsf_eda_slist_queue.c:67