summaryrefslogtreecommitdiff
path: root/samples/microkernel/benchmark/app_kernel/src/sema_b.c
diff options
context:
space:
mode:
authorYonattan Louise <yonattan.a.louise.mendoza@intel.com>2015-05-14 16:30:48 -0500
committerAnas Nashif <anas.nashif@intel.com>2016-02-05 20:13:59 -0500
commitdbada63eee8516d35d11c1543788e742b70172e1 (patch)
tree6f6556441918eecadd2495e4e2944138422accf5 /samples/microkernel/benchmark/app_kernel/src/sema_b.c
parentd133f9661d670ca5340dd032ba3630f44d995af9 (diff)
Fix coding style issues.
Some checkpatch issues were solved by scripts leaving other problems such as alignment and indentation issues. In order to comply with the defined coding style the following fixes were made: - Fixed the function declaration moving the parameters' comments above the function in accordance to the doxygen format. - Fixed functions' opening and closing brackets. These brackets should not be indented. - Fixed the 'if', 'for' and 'while' statements adding the brackets around the sentence. - Fixed comments' alignment. - Fixed indentation. The work was done manually and submitted as one commit. I didn't separate these changes in different commits because they were fixed all at once. Basically, all errors were fixed in every file at once. Change-Id: Icc94a10bfd2cff82007ce60df23b2ccd4c30268d Signed-off-by: Yonattan Louise <yonattan.a.louise.mendoza@intel.com>
Diffstat (limited to 'samples/microkernel/benchmark/app_kernel/src/sema_b.c')
-rw-r--r--samples/microkernel/benchmark/app_kernel/src/sema_b.c42
1 files changed, 21 insertions, 21 deletions
diff --git a/samples/microkernel/benchmark/app_kernel/src/sema_b.c b/samples/microkernel/benchmark/app_kernel/src/sema_b.c
index e63fd7592..94c085aa7 100644
--- a/samples/microkernel/benchmark/app_kernel/src/sema_b.c
+++ b/samples/microkernel/benchmark/app_kernel/src/sema_b.c
@@ -45,104 +45,104 @@
*/
void sema_test(void)
- {
+{
uint32_t et; /* elapsed Time */
int i;
PRINT_STRING(dashline, output_file);
et = BENCH_START();
for (i = 0; i < NR_OF_SEMA_RUNS; i++) {
- task_sem_give(SEM0);
+ task_sem_give(SEM0);
}
et = TIME_STAMP_DELTA_GET(et);
check_result();
PRINT_F(output_file, FORMAT, "signal semaphore",
- SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
+ SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
task_sem_reset(SEM1);
task_sem_give(STARTRCV);
et = BENCH_START();
for (i = 0; i < NR_OF_SEMA_RUNS; i++) {
- task_sem_give(SEM1);
+ task_sem_give(SEM1);
}
et = TIME_STAMP_DELTA_GET(et);
check_result();
PRINT_F(output_file, FORMAT, "signal to waiting high pri task",
- SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
+ SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
et = BENCH_START();
for (i = 0; i < NR_OF_SEMA_RUNS; i++) {
- task_sem_give(SEM1);
+ task_sem_give(SEM1);
}
et = TIME_STAMP_DELTA_GET(et);
check_result();
PRINT_F(output_file, FORMAT,
- "signal to waiting high pri task, with timeout",
- SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
+ "signal to waiting high pri task, with timeout",
+ SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
et = BENCH_START();
for (i = 0; i < NR_OF_SEMA_RUNS; i++) {
- task_sem_give(SEM2);
+ task_sem_give(SEM2);
}
et = TIME_STAMP_DELTA_GET(et);
check_result();
PRINT_F(output_file, FORMAT, "signal to waitm (2)",
- SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
+ SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
et = BENCH_START();
for (i = 0; i < NR_OF_SEMA_RUNS; i++) {
- task_sem_give(SEM2);
+ task_sem_give(SEM2);
}
et = TIME_STAMP_DELTA_GET(et);
check_result();
PRINT_F(output_file, FORMAT, "signal to waitm (2), with timeout",
- SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
+ SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
et = BENCH_START();
for (i = 0; i < NR_OF_SEMA_RUNS; i++) {
- task_sem_give(SEM3);
+ task_sem_give(SEM3);
}
et = TIME_STAMP_DELTA_GET(et);
check_result();
PRINT_F(output_file, FORMAT, "signal to waitm (3)",
- SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
+ SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
et = BENCH_START();
for (i = 0; i < NR_OF_SEMA_RUNS; i++) {
- task_sem_give(SEM3);
+ task_sem_give(SEM3);
}
et = TIME_STAMP_DELTA_GET(et);
check_result();
PRINT_F(output_file, FORMAT, "signal to waitm (3), with timeout",
- SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
+ SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
et = BENCH_START();
for (i = 0; i < NR_OF_SEMA_RUNS; i++) {
- task_sem_give(SEM4);
+ task_sem_give(SEM4);
}
et = TIME_STAMP_DELTA_GET(et);
check_result();
PRINT_F(output_file, FORMAT, "signal to waitm (4)",
- SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
+ SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
et = BENCH_START();
for (i = 0; i < NR_OF_SEMA_RUNS; i++) {
- task_sem_give(SEM4);
+ task_sem_give(SEM4);
}
et = TIME_STAMP_DELTA_GET(et);
check_result();
PRINT_F(output_file, FORMAT, "signal to waitm (4), with timeout",
- SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
- }
+ SYS_CLOCK_HW_CYCLES_TO_NS_AVG(et, NR_OF_SEMA_RUNS));
+}
#endif /* SEMA_BENCH */