source: soft/giet_vm/giet_libs/libsrl/srl_sched_wait.h @ 523

Last change on this file since 523 was 258, checked in by alain, 11 years ago

This is a major release, including a deep restructuration of code.
The main evolutions are

  • use of the Tsar preloader to load the GIET boot-loader from disk
  • introduction of a FAT32 file system library,
  • use of this fat32 library by the boot-loader to load the map.bin data structure, and the various .elf files
  • reorganisation of drivers (one file per peripheral).
  • introduction of drivers for new peripherals: vci_chbuf_dma and vci_multi_ahci.
  • introduction of a new physical memory allocator in the boot code.

This release has been tested on the tsar_generic_iob architecture,
for the two following mappings: 4c_1p_iob_four.xml and 4c_1p_iob_sort.xml

  • Property svn:executable set to *
File size: 1.6 KB
Line 
1#ifndef SRL_SCHED_WAIT_H
2#define SRL_SCHED_WAIT_H
3
4#include "srl_public_types.h"
5
6/**
7 * @file
8 * @module{SRL}
9 * @short Smart waiting tools
10 */
11
12#define DECLARE_WAIT(name, cmp)                                       \
13/**                                                                           \
14   @this makes the current task sleep until the value pointed at @tt addr     \
15   asserts the following test:                                                \
16                                                                              \
17   @code                                                                      \
18   (*addr cmp val)                                                            \
19   @end code                                                                  \
20                                                                              \
21   @param addr The address to poll                                            \
22   @param val The value to compare to                                         \
23*/                                                                            \
24                                                                              \
25void srl_sched_wait_##name(void *addr, sint32_t val );
26
27DECLARE_WAIT(eq, ==)
28DECLARE_WAIT(ne, !=)
29DECLARE_WAIT(le, <=)
30DECLARE_WAIT(ge, >=)
31DECLARE_WAIT(lt, <)
32DECLARE_WAIT(gt, >)
33
34#undef DECLARE_WAIT
35
36
37void srl_sleep_cycles(unsigned int n);
38
39#endif
40
41
42// Local Variables:
43// tab-width: 4
44// c-basic-offset: 4
45// c-file-offsets:((innamespace . 0)(inline-open . 0))
46// indent-tabs-mode: nil
47// End:
48// vim: filetype=c:expandtab:shiftwidth=4:tabstop=4:softtabstop=4
49
Note: See TracBrowser for help on using the repository browser.