Last change
on this file since 257 was
228,
checked in by meunier, 12 years ago
|
Added support for memspaces and const.
Added an interrupt masking to the "giet_context_switch" syscall
Corrected two bugs in boot/boot_init.c (one minor and one regarding barriers initialization)
Reformatted the code in all files.
|
File size:
1.2 KB
|
Rev | Line | |
---|
[158] | 1 | ////////////////////////////////////////////////////////////////////////////////// |
---|
| 2 | // File : barrier.h |
---|
| 3 | // Date : 01/04/2012 |
---|
| 4 | // Author : alain greiner |
---|
| 5 | // Copyright (c) UPMC-LIP6 |
---|
| 6 | /////////////////////////////////////////////////////////////////////////////////// |
---|
| 7 | |
---|
| 8 | #ifndef _BARRIER_H_ |
---|
| 9 | #define _BARRIER_H_ |
---|
| 10 | |
---|
| 11 | /////////////////////////////////////////////////////////////////////////////////// |
---|
| 12 | // barrier structure |
---|
| 13 | /////////////////////////////////////////////////////////////////////////////////// |
---|
| 14 | |
---|
| 15 | typedef struct giet_barrier_s { |
---|
[228] | 16 | char name[32]; // barrier name |
---|
| 17 | unsigned int init; // total number of participants |
---|
| 18 | unsigned int count; // number of not yet arrived tasks |
---|
[165] | 19 | } giet_barrier_t; |
---|
[158] | 20 | |
---|
| 21 | ////////////////////////////////////////////////////////////////////////////// |
---|
[165] | 22 | // access functions |
---|
[158] | 23 | ////////////////////////////////////////////////////////////////////////////// |
---|
| 24 | |
---|
[228] | 25 | void barrier_init(giet_barrier_t * barrier, unsigned int value); |
---|
| 26 | void barrier_wait(giet_barrier_t * barrier); |
---|
[158] | 27 | |
---|
| 28 | #endif |
---|
| 29 | |
---|
[228] | 30 | // Local Variables: |
---|
| 31 | // tab-width: 4 |
---|
| 32 | // c-basic-offset: 4 |
---|
| 33 | // c-file-offsets:((innamespace . 0)(inline-open . 0)) |
---|
| 34 | // indent-tabs-mode: nil |
---|
| 35 | // End: |
---|
| 36 | // vim: filetype=c:expandtab:shiftwidth=4:tabstop=4:softtabstop=4 |
---|
| 37 | |
---|
Note: See
TracBrowser
for help on using the repository browser.