[PATCH 4/5] pi_stress: Fix error and debug message formatting
John Kacur <[email protected]> Tue, 30 Jun 2026 12:45:01 -0400
| Newsgroups | org.kernel.vger.linux-rt-users |
|---|---|
| Message-ID | <[email protected]> |
Fix three message formatting issues: 1. Incorrect barrier name in error message (line 212): The error referenced "all_threads_ready" but was actually checking "all_threads_done" 2. Typo in SCHED_DEADLINE error message (line 746): Fixed malformed parenthesis in "affinity*dl)" to "affinity (dl)" 3. Wrong format specifier (line 808): Variable 'count' is unsigned long but was using %d instead of %lu These are cosmetic fixes that improve debugging clarity but don't affect program behavior. Assisted-by: Claude:claude-sonnet-4-5 Signed-off-by: John Kacur <[email protected]> --- src/pi_tests/pi_stress.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/pi_tests/pi_stress.c b/src/pi_tests/pi_stress.c index 675953923c3a..45ccac739646 100644 --- a/src/pi_tests/pi_stress.c +++ b/src/pi_tests/pi_stress.c @@ -209,7 +209,7 @@ int main(int argc, char **argv) pi_info("waiting for all threads to complete\n"); status = pthread_barrier_wait(&all_threads_done); if (status && status != PTHREAD_BARRIER_SERIAL_THREAD) { - pi_error("%s: pthread_barrier_wait(all_threads_ready): 0x%x\n", __func__, status); + pi_error("%s: pthread_barrier_wait(all_threads_done): 0x%x\n", __func__, status); return FAILURE; } pi_info("All threads terminated!\n"); @@ -743,7 +743,7 @@ void *high_priority(void *arg) status = sched_setaffinity(0, sizeof(cpu_set_t), &cpu_mask); if (status < 0) { pi_error - ("high_priority[%d]: set cpu affinity*dl): %x\n", + ("high_priority[%d]: set cpu affinity (dl): %x\n", p->id, status); return NULL; } @@ -805,7 +805,7 @@ void *high_priority(void *arg) } pthread_mutex_unlock(&shutdown_mtx); } - pi_debug("high_priority[%d]: entering start state (%d)\n", p->id, + pi_debug("high_priority[%d]: entering start state (%lu)\n", p->id, count++); status = pthread_barrier_wait(&p->start_barrier); if (status && status != PTHREAD_BARRIER_SERIAL_THREAD) { -- 2.54.0