blob: 0bd30de543b5376efa18aa37c0d079f6348d0f94 [file] [log] [blame]
suhasgrao76e8f8c2017-07-12 16:24:33 +05301
2/* Global definations */
3pthread_cond_t cv;
4pthread_mutex_t lock;
5
6#define IND_USR_DAT_LEN 8
7#define IND_USR_DAT_VAL "brcmOLT"
8#define BALCLIENT "bal_client"
9#define BALSERVER "bal_server"
10
11/* A linked list (LL) node to store a queue entry */
12struct QNode
13{
14 int obj_type;
15 int status;
16 struct QNode *next;
17};
18
19
20/* The queue, front stores the front node of LL and rear stores ths
21 last node of LL */
22typedef struct Queue
23{
24 struct QNode *front, *rear;
25}bal_queue;
26
27/* shared queue */
28bal_queue *shared_queue;
29
30void create_stub_thread();
31bal_queue *createQueue();
32struct QNode* newNode(int objKey, int status);
33void enQueue(int objKey, int status);
34struct QNode *deQueue();