This is a note to let you know that I've just added the patch titled
drivercore: Fix ordering between deferred_probe and exiting initcalls
to the 3.8-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
drivercore-fix-ordering-between-deferred_probe-and-exiting-initcalls.patch
and it can be found in the queue-3.8 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <[email protected]> know about it.
>From d72cca1eee5b26e313da2a380d4862924e271031 Mon Sep 17 00:00:00 2001
From: Grant Likely <[email protected]>
Date: Thu, 14 Feb 2013 18:14:27 +0000
Subject: drivercore: Fix ordering between deferred_probe and exiting initcalls
From: Grant Likely <[email protected]>
commit d72cca1eee5b26e313da2a380d4862924e271031 upstream.
One of the side effects of deferred probe is that some drivers which
used to be probed before initcalls completed are now happening slightly
later. This causes two problems.
- If a console driver gets deferred, then it may not be ready when
userspace starts. For example, if a uart depends on pinctrl, then the
uart will get deferred and /dev/console will not be available
- __init sections will be discarded before built-in drivers are probed.
Strictly speaking, __init functions should not be called in a drivers
__probe path, but there are a lot of drivers (console stuff again)
that do anyway. In the past it was perfectly safe to do so because all
built-in drivers got probed before the end of initcalls.
This patch fixes the problem by forcing the first pass of the deferred
list to complete at late_initcall time. This is late enough to catch the
drivers that are known to have the above issues.
Signed-off-by: Grant Likely <[email protected]>
Tested-by: Haojian Zhuang <[email protected]>
Cc: Arnd Bergmann <[email protected]>
Cc: Russell King <[email protected]>
Cc: Linus Torvalds <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
---
drivers/base/dd.c | 2 ++
1 file changed, 2 insertions(+)
--- a/drivers/base/dd.c
+++ b/drivers/base/dd.c
@@ -172,6 +172,8 @@ static int deferred_probe_initcall(void)
driver_deferred_probe_enable = true;
driver_deferred_probe_trigger();
+ /* Sort as many dependencies as possible before exiting initcalls */
+ flush_workqueue(deferred_wq);
return 0;
}
late_initcall(deferred_probe_initcall);
Patches currently in stable-queue which might be from [email protected]
are
queue-3.8/drivercore-fix-ordering-between-deferred_probe-and-exiting-initcalls.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html