diff options
| author | Mohammed Khajapasha <mkhaja@codeaurora.org> | 2015-09-04 20:33:31 +0530 |
|---|---|---|
| committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2018-09-06 04:04:46 -0700 |
| commit | 20f23e546e28898062efb3ed6c7e6f7a5585c099 (patch) | |
| tree | a48109500d0c93247b49b6fbfcced7c3a23937f3 /kernel/printk/printk.c | |
| parent | 6aab18ee11149b4e2d00c0fd8da3a54661979226 (diff) | |
printk: Make the console flush configurable in hotplug path
The thread which initiates the hot plug can get scheduled
out, while trying to acquire the console lock,
thus increasing the hot plug latency. This option
allows to selectively disable the console flush and
in turn reduce the hot plug latency.
Change-Id: I42507804d321b29b7761146a6c175d959bf79925
Signed-off-by: Mohammed Khajapasha <mkhaja@codeaurora.org>
Signed-off-by: Prasad Sodagudi <psodagud@codeaurora.org>
Signed-off-by: Neeraj Upadhyay <neeraju@codeaurora.org>
Diffstat (limited to 'kernel/printk/printk.c')
| -rw-r--r-- | kernel/printk/printk.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/kernel/printk/printk.c b/kernel/printk/printk.c index dca87791e9c1..da573aeaeb12 100644 --- a/kernel/printk/printk.c +++ b/kernel/printk/printk.c @@ -2119,6 +2119,8 @@ void resume_console(void) console_unlock(); } +#ifdef CONFIG_CONSOLE_FLUSH_ON_HOTPLUG + /** * console_cpu_notify - print deferred console messages after CPU hotplug * @self: notifier struct @@ -2148,6 +2150,8 @@ static int console_cpu_notify(struct notifier_block *self, return NOTIFY_OK; } +#endif + /** * console_lock - lock the console system for exclusive use. * @@ -2712,7 +2716,9 @@ static int __init printk_late_init(void) unregister_console(con); } } +#ifdef CONFIG_CONSOLE_FLUSH_ON_HOTPLUG hotcpu_notifier(console_cpu_notify, 0); +#endif return 0; } late_initcall(printk_late_init); |
