lkml.org 
[lkml]   [2012]   [Apr]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[RFC/PATCH 2/3] init: Initialize jump_labels before early parameters
Date
We want to use jump_labels in the debug_objects code so that when
debug_objects aren't enabled by default we can skip debug_object
code. Move the jump_label initialization before the early
parameter parsing so that debug_objects code can enable and
disable itself according to kernel command line parameters.

Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Cc: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
---

This also opens the window to using static keys for pr_debug().
I tried and wound up in circular dependency hell.

init/main.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/init/main.c b/init/main.c
index ff49a6d..39a3092 100644
--- a/init/main.c
+++ b/init/main.c
@@ -502,14 +502,14 @@ asmlinkage void __init start_kernel(void)
build_all_zonelists(NULL);
page_alloc_init();

+ jump_label_init();
+
printk(KERN_NOTICE "Kernel command line: %s\n", boot_command_line);
parse_early_param();
parse_args("Booting kernel", static_command_line, __start___param,
__stop___param - __start___param,
&unknown_bootoption);

- jump_label_init();
-
/*
* These use large bootmem allocations and must precede
* kmem_cache_init()
--
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.


\
 
 \ /
  Last update: 2012-04-06 09:07    [W:0.024 / U:0.728 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site