Changeset cd8ad52 in mainline for kernel/test/synch/semaphore2.c
- Timestamp:
- 2008-06-03T14:58:05Z (17 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- b63f8569
- Parents:
- 7ac426e
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/test/synch/semaphore2.c
r7ac426e rcd8ad52 68 68 69 69 to = random(20000); 70 printf("cpu% d, tid %lludown+ (%d)\n", CPU->id, THREAD->tid, to);70 printf("cpu%u, tid %" PRIu64 " down+ (%d)\n", CPU->id, THREAD->tid, to); 71 71 rc = semaphore_down_timeout(&sem, to); 72 72 if (SYNCH_FAILED(rc)) { 73 printf("cpu% d, tid %lludown!\n", CPU->id, THREAD->tid);73 printf("cpu%u, tid %" PRIu64 " down!\n", CPU->id, THREAD->tid); 74 74 return; 75 75 } 76 76 77 printf("cpu% d, tid %lludown=\n", CPU->id, THREAD->tid);77 printf("cpu%u, tid %" PRIu64 " down=\n", CPU->id, THREAD->tid); 78 78 thread_usleep(random(30000)); 79 79 80 80 semaphore_up(&sem); 81 printf("cpu% d, tid %lluup\n", CPU->id, THREAD->tid);81 printf("cpu%u, tid %" PRIu64 " up\n", CPU->id, THREAD->tid); 82 82 } 83 83 … … 92 92 93 93 k = random(7) + 1; 94 printf("Creating % dconsumers\n", k);94 printf("Creating %" PRIu32 " consumers\n", k); 95 95 for (i = 0; i < k; i++) { 96 96 thrd = thread_create(consumer, NULL, TASK, 0, "consumer", false);
Note:
See TracChangeset
for help on using the changeset viewer.