source: soft/giet_vm/libs/srl.h @ 189

Last change on this file since 189 was 189, checked in by alain, 12 years ago

Introducing a new release where all initialisation
is done in the boot code.

File size: 1.5 KB
Line 
1#ifndef SRL_H_
2#define SRL_H_
3
4/**
5   @file
6   @module{SRL}
7   @short SRL Api main header
8 */
9
10#include "libsrl/srl_public_types.h"
11//#include "libsrl/srl_private_types.h"
12
13#include "libsrl/srl_lock.h"
14#include "libsrl/srl_mwmr.h"
15#include "libsrl/srl_log.h"
16#include "libsrl/srl_barrier.h"
17#include "libsrl/srl_memspace.h"
18
19#include "libsrl/srl_hw_helpers.h"
20
21//kernel use!
22//#include "libsrl/srl_mwmr_sys.h"
23
24/* port, APP_NAME, TASK */
25# define GET_MWMR(port)                                                                       \
26({                                                                                            \
27    srl_mwmr_t  _mwmr;                                                                      \
28    if( vobj_get_vbase( APP_NAME , #port, MWMR, (unsigned int*)&_mwmr ) )                   \
29    {                                                                                         \
30        srl_log_printf( NONE, "\n[ERROR] in "TASK" task :\n");                              \
31        srl_log_printf( NONE, "          undefined <"#port"> channel: %d\n", _mwmr);           \
32        srl_log_printf( TRACE, "*** &"#port" = %x\n\n", (unsigned int)_mwmr );                 \
33        exit();/*srl?*/                                                                     \
34    }else                                                                                         \
35        srl_log_printf( TRACE, "%s:%d: arg of %s for %s,from %s; &"#port" = %x\n\n", __FILE__, __LINE__, APP_NAME, TASK,#port, (unsigned int)_mwmr ); \
36    _mwmr;\
37})
38
39#endif
40
Note: See TracBrowser for help on using the repository browser.