RTEMS | tc-cpuuse.c: magic number cleanup (!1049)
Gedare Bloom (@gedare)
gitlab at rtems.org
Fri Feb 6 20:34:21 UTC 2026
Gedare Bloom started a new discussion: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1049#note_142092
Fix formatting errors:
```
gedare at localhost:~/rtems/rtems$ git clang-format HEAD^
changed files:
testsuites/validation/tc-cpuuse.c
gedare at localhost:~/rtems/rtems$ git diff
diff --git a/testsuites/validation/tc-cpuuse.c b/testsuites/validation/tc-cpuuse.c
index bc22262442..4733eda998 100644
--- a/testsuites/validation/tc-cpuuse.c
+++ b/testsuites/validation/tc-cpuuse.c
@@ -142,10 +142,14 @@ static void RtemsCpuuseValCpuuse_Action_0( void )
* Our CPU usage after the last reset is now exactly one tick of the
* software timecounter.
*/
- T_eq_i64( _Thread_Get_CPU_time_used_after_last_reset( self ), CPUUSE_SOFT_TICKS );
+ T_eq_i64(
+ _Thread_Get_CPU_time_used_after_last_reset( self ),
+ CPUUSE_SOFT_TICKS
+ );
T_eq_i64(
_Thread_Get_CPU_time_used( self ),
- cpu_usage_self + (3*CPUUSE_SOFT_TICKS) + (CPUUSE_SOFT_TICKS * idle_tasks)
+ cpu_usage_self + ( 3 * CPUUSE_SOFT_TICKS ) +
+ ( CPUUSE_SOFT_TICKS * idle_tasks )
);
T_eq_i64( _Thread_Get_CPU_time_used_after_last_reset( other ), 0 );
```
--
View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1049#note_142092
You're receiving this email because of your account on gitlab.rtems.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20260206/dd379c39/attachment-0001.htm>
More information about the bugs
mailing list