#ifndef __OSP_SW_QUEUE_H__
#define __OSP_SW_QUEUE_H__

#include "osp_msg.h"

#define OSP_QUE_DEP     (32)
#define OSP_QUE_SIZE    (4)     //(OSP_MSG_HEAD_LEN)  //(16)

typedef struct osp_ape_que_info_struct
{
    uint32_t enque_idx;  /*osp_sw_enque idx*/
    uint32_t deque_idx;  /*osp_sw_deque idx*/ 
    uint32_t enque_count;
    uint32_t deque_count;
    uint32_t full_count;
    uint32_t empty_count;
    uint32_t mask;
    sem_t *msg_sem;
    osp_msg_head* que_msg[OSP_QUE_DEP];
}osp_sw_queue;

extern int osp_sw_queue_int(osp_sw_queue *p_sw_queue_head);
extern int osp_sw_deque(osp_msg_head **pmsg_head, osp_sw_queue *que);
extern int osp_sw_enque(osp_msg_head *pmsg_head, osp_sw_queue *que);

#endif /* __OSP_SW_QUEUE_H__ */

