summaryrefslogtreecommitdiff
path: root/src/lib/thread.c
diff options
context:
space:
mode:
authorLee Leahy <leroy.p.leahy@intel.com>2017-03-08 17:37:06 -0800
committerLee Leahy <leroy.p.leahy@intel.com>2017-03-09 17:29:33 +0100
commit2f919ec4765e4484d79b866332fa19ec338db5c0 (patch)
tree1ddb3a7eba06bdd40657c5f63bc8dce322c530a6 /src/lib/thread.c
parentb2d834a93afe129851f9aa7400f3fb2f42be20a4 (diff)
src/lib: Remove braces for single statements
Fix the following warning detected by checkpatch.pl: WARNING: braces {} are not necessary for single statement blocks TEST=Build and run on Galileo Gen2 Change-Id: Ie4b41f6fb75142ddd75103a55e0347ed85e7e873 Signed-off-by: Lee Leahy <Leroy.P.Leahy@intel.com> Reviewed-on: https://review.coreboot.org/18697 Reviewed-by: Arthur Heymans <arthur@aheymans.xyz> Tested-by: build bot (Jenkins)
Diffstat (limited to 'src/lib/thread.c')
-rw-r--r--src/lib/thread.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/lib/thread.c b/src/lib/thread.c
index c2504823b9..9387b037dd 100644
--- a/src/lib/thread.c
+++ b/src/lib/thread.c
@@ -121,9 +121,8 @@ static void idle_thread(void *unused)
{
/* This thread never voluntarily yields. */
thread_prevent_coop();
- while (1) {
+ while (1)
timers_run();
- }
}
static void schedule(struct thread *t)
@@ -214,9 +213,8 @@ static void idle_thread_init(void)
t = get_free_thread();
- if (t == NULL) {
+ if (t == NULL)
die("No threads available for idle thread!\n");
- }
/* Queue idle thread to run once all other threads have yielded. */
prepare_thread(t, idle_thread, NULL, call_wrapper, NULL);