File tree Expand file tree Collapse file tree 2 files changed +10
-4
lines changed Expand file tree Collapse file tree 2 files changed +10
-4
lines changed Original file line number Diff line number Diff line change 11
11
#include "dyn_gossip.h"
12
12
#include "dyn_token.h"
13
13
14
+ _C2G_InQ C2G_InQ = {};
15
+ _C2G_OutQ C2G_OutQ = {};
16
+
14
17
// should use pooling to store struct ring_message so that we can reuse
15
18
struct ring_msg * create_ring_msg (void ) {
16
19
struct ring_msg * msg = dn_alloc (sizeof (* msg ));
Original file line number Diff line number Diff line change @@ -16,17 +16,20 @@ struct gossip_node;
16
16
typedef rstatus_t (* callback_t )(void * msg );
17
17
typedef void (* data_func_t )(void * );
18
18
19
- volatile struct {
19
+ typedef volatile struct {
20
20
long m_getIdx ;
21
21
long m_putIdx ;
22
22
void * m_entry [C2G_InQ_SIZE ];
23
- } C2G_InQ ;
23
+ } _C2G_InQ ;
24
24
25
- volatile struct {
25
+ typedef volatile struct {
26
26
long m_getIdx ;
27
27
long m_putIdx ;
28
28
void * m_entry [C2G_OutQ_SIZE ];
29
- } C2G_OutQ ;
29
+ } _C2G_OutQ ;
30
+
31
+ extern _C2G_InQ C2G_InQ ;
32
+ extern _C2G_OutQ C2G_OutQ ;
30
33
31
34
struct ring_msg {
32
35
callback_t cb ;
You can’t perform that action at this time.
0 commit comments