kernel: timeout: fix missing final else
z_timeout_end_calc() was missing final else statement in the if else if construct. This commit pulls the last condition into a final else {} to comply with guideline 15.7. Signed-off-by: Jennifer Williams <jennifer.m.williams@intel.com>
This commit is contained in:
parent
a3c7e45a73
commit
dc11ffb562
1 changed files with 6 additions and 5 deletions
|
@ -310,12 +310,13 @@ uint64_t sys_clock_timeout_end_calc(k_timeout_t timeout)
|
|||
return UINT64_MAX;
|
||||
} else if (K_TIMEOUT_EQ(timeout, K_NO_WAIT)) {
|
||||
return sys_clock_tick_get();
|
||||
}
|
||||
} else {
|
||||
|
||||
dt = timeout.ticks;
|
||||
dt = timeout.ticks;
|
||||
|
||||
if (IS_ENABLED(CONFIG_TIMEOUT_64BIT) && Z_TICK_ABS(dt) >= 0) {
|
||||
return Z_TICK_ABS(dt);
|
||||
if (IS_ENABLED(CONFIG_TIMEOUT_64BIT) && Z_TICK_ABS(dt) >= 0) {
|
||||
return Z_TICK_ABS(dt);
|
||||
}
|
||||
return sys_clock_tick_get() + MAX(1, dt);
|
||||
}
|
||||
return sys_clock_tick_get() + MAX(1, dt);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue