kselftest: timers: Fix const correctness
authorPiotr Zalewski <pZ010001011111@proton.me>
Mon, 19 Aug 2024 17:58:34 +0000 (17:58 +0000)
committerShuah Khan <skhan@linuxfoundation.org>
Wed, 21 Aug 2024 06:48:48 +0000 (00:48 -0600)
commit99338cc1e47187c3efdd39cda2a31500d0f2305d
tree6ada7f36b5b29864b5ded10315aa958c1b128310
parent41f37c852ac3fbfd072a00281b60dc7ba056be8c
kselftest: timers: Fix const correctness

Make timespec pointers, pointers to const in checklist function. As a
consequence, make list parameter in checklist function pointer to const
as well. Const-correctness increases readability.

Improvement was found by running cppcheck tool on the patched file as
follows:
```
cppcheck --enable=all \
tools/testing/selftests/timers/threadtest.c \
--suppress=missingIncludeSystem \
--suppress=unusedFunction
```

Reviewed-by: Shuah Khan <skhan@linuxfoundation.org>
Signed-off-by: Piotr Zalewski <pZ010001011111@proton.me>
Acked-by: John Stultz <jstultz@google.com>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
tools/testing/selftests/timers/threadtest.c