34,7 → 34,7 |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
* |
* |
* CVS : $Id: jointest.c,v 1.1 2002-11-11 08:22:45 pj Exp $ |
* CVS : $Id: jointest.c,v 1.2 2004-04-17 11:36:14 giacomo Exp $ |
|
This test verify the correctness of the task_join primitive. (that |
function is the same as pthread_join... someday I will change the |
65,17 → 65,10 |
*/ |
|
#include "kernel/kern.h" |
#include "drivers/keyb.h" |
|
|
PID j0, j1, j2, j3, j4; |
mutex_t m1; |
|
void fine(KEY_EVT *e) |
{ |
sys_end(); |
} |
|
TASK J1() |
{ |
int err; |
148,16 → 141,10 |
|
PI_mutexattr_t a; |
|
KEY_EVT emerg; |
|
int err; |
void *ret; |
|
//keyb_set_map(itaMap); |
emerg.ascii = 'x'; |
emerg.scan = KEY_X; |
emerg.flag = ALTL_BIT; |
keyb_hook(emerg,fine); |
struct timespec t; |
|
j0 = exec_shadow; |
nrt_task_default_model(m); |
216,5 → 203,12 |
|
cprintf("main: join J4 returns %d error %d, exiting\n", (int)ret, err); |
|
do { |
sys_gettime(&t); |
} while (t.tv_sec < 10); |
|
sys_end(); |
|
return 0; |
|
} |