* grab the lock, update both counters, release the lock. */
| 119 | * grab the lock, update both counters, release the lock. |
| 120 | */ |
| 121 | static void |
| 122 | plock_add(struct plock_test *pt, uint32_t self, uint32_t n) |
| 123 | { |
| 124 | plock_lock(&pt->lock, self); |
| 125 | pt->iter++; |
| 126 | pt->val += n; |
| 127 | plock_unlock(&pt->lock, self); |
| 128 | } |
| 129 | |
| 130 | static int |
| 131 | plock_test1_lcore(void *data) |
no test coverage detected