2009-06-10 09:58:50 +02:00
|
|
|
#ifndef _COMMON_COMM_H_
|
|
|
|
#define _COMMON_COMM_H_ 1
|
|
|
|
|
|
|
|
#include <stdint.h>
|
|
|
|
|
|
|
|
#define CACHE_LINE_SIZE 128
|
|
|
|
#define BUF_SIZE CACHE_LINE_SIZE
|
|
|
|
|
2009-06-11 23:37:37 +02:00
|
|
|
#define likely(x) __builtin_expect(!!(x), 1)
|
|
|
|
#define unlikely(x) __builtin_expect(!!(x), 0)
|
|
|
|
|
2009-06-10 09:58:50 +02:00
|
|
|
extern volatile int cont;
|
2009-06-17 18:15:16 +02:00
|
|
|
extern long nb_prod;
|
2009-06-10 09:58:50 +02:00
|
|
|
|
|
|
|
__BEGIN_DECLS
|
|
|
|
|
2009-06-17 18:15:16 +02:00
|
|
|
int init_library(void);
|
|
|
|
void reception(void (*)(volatile void *));
|
2009-06-10 09:58:50 +02:00
|
|
|
extern int swap_buffer;
|
|
|
|
|
|
|
|
__END_DECLS
|
|
|
|
|
|
|
|
#endif
|