Changeset 96348adc in mainline for kernel/test/synch/rwlock2.c
- Timestamp:
- 2006-12-12T17:24:58Z (18 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 7e13972
- Parents:
- 34db7fa
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/test/synch/rwlock2.c
r34db7fa r96348adc 40 40 static rwlock_t rwlock; 41 41 42 static void writer(void *arg);43 static void failed(void);44 45 42 static void writer(void *arg) 46 43 { … … 59 56 } 60 57 61 static void failed() 62 { 63 printf("Test failed prematurely.\n"); 64 thread_exit(); 65 } 66 67 void test_rwlock2(void) 58 char * test_rwlock2(void) 68 59 { 69 60 thread_t *thrd; 70 61 71 printf("Read/write locks test #2\n");72 73 62 rwlock_initialize(&rwlock); 74 63 … … 82 71 thread_ready(thrd); 83 72 else 84 failed(); 85 73 return "Could not create thread"; 86 74 87 75 thread_sleep(1); … … 90 78 rwlock_read_unlock(&rwlock); 91 79 rwlock_read_unlock(&rwlock); 92 rwlock_read_unlock(&rwlock); 93 80 rwlock_read_unlock(&rwlock); 81 82 return NULL; 94 83 }
Note:
See TracChangeset
for help on using the changeset viewer.