4.115
Last change
on this file since dc1c997b was
dc1c997b,
checked in by Jennifer Averett <Jennifer.Averett@…>, on 05/25/11 at 14:38:45
|
2011-05-25 Jennifer Averett <Jennifer.Averett@…>
PR 1792/bsps
- src/lib/libbsp/i386/pc386/Makefile.am,
src/lib/libbsp/sparc/erc32/Makefile.am,
src/lib/libbsp/sparc/leon2/Makefile.am,
src/lib/libbsp/sparc/leon3/Makefile.am: Added a generic smp wait
method to sparc and i386 bsps.
- src/lib/libbsp/shared/smp/bspsmp_wait_for.c: New file.
|
-
Property mode set to
100644
|
File size:
632 bytes
|
Line | |
---|
1 | /* |
---|
2 | * |
---|
3 | * COPYRIGHT (c) 1989-2011. |
---|
4 | * On-Line Applications Research Corporation (OAR). |
---|
5 | * |
---|
6 | * The license and distribution terms for this file may be |
---|
7 | * found in the file LICENSE in this distribution or at |
---|
8 | * http://www.rtems.com/license/LICENSE. |
---|
9 | * |
---|
10 | * $Id |
---|
11 | */ |
---|
12 | |
---|
13 | void rtems_bsp_delay( int usec ); |
---|
14 | |
---|
15 | void bsp_smp_wait_for( |
---|
16 | volatile unsigned int *address, |
---|
17 | unsigned int desired, |
---|
18 | int maximum_usecs |
---|
19 | ) |
---|
20 | { |
---|
21 | int iterations; |
---|
22 | volatile unsigned int *p = address; |
---|
23 | |
---|
24 | for (iterations=0 ; iterations < maximum_usecs ; iterations++ ) { |
---|
25 | if ( *p == desired ) |
---|
26 | break; |
---|
27 | |
---|
28 | rtems_bsp_delay( 1 ); |
---|
29 | } |
---|
30 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.