diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-02-20 01:10:26 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-02-20 01:10:26 -0500 |
commit | ece8e0b2f9c980e5511fe8db2d68c6f1859b9d83 (patch) | |
tree | 70f1e3363080884965686576d079d24da8863a58 /init/main.c | |
parent | 67cb104b4c30bd52292b6a7f526349aab2dd5cbd (diff) | |
parent | a0327ff0eda915be623658babacef706099c11a8 (diff) |
Merge branch 'for-3.9-async' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq
Pull async changes from Tejun Heo:
"These are followups for the earlier deadlock issue involving async
ending up waiting for itself through block requesting module[1]. The
following changes are made by these commits.
- Instead of requesting default elevator on each request_queue init,
block now requests it once early during boot.
- Kmod triggers warning if invoked from an async worker.
- Async synchronization implementation has been reimplemented. It's
a lot simpler now."
* 'for-3.9-async' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq:
async: initialise list heads to fix crash
async: replace list of active domains with global list of pending items
async: keep pending tasks on async_domain and remove async_pending
async: use ULLONG_MAX for infinity cookie value
async: bring sanity to the use of words domain and running
async, kmod: warn on synchronous request_module() from async workers
block: don't request module during elevator init
init, block: try to load default elevator module early during boot
Diffstat (limited to 'init/main.c')
-rw-r--r-- | init/main.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/init/main.c b/init/main.c index cee4b5c66d81..63534a141b4e 100644 --- a/init/main.c +++ b/init/main.c | |||
@@ -70,6 +70,8 @@ | |||
70 | #include <linux/perf_event.h> | 70 | #include <linux/perf_event.h> |
71 | #include <linux/file.h> | 71 | #include <linux/file.h> |
72 | #include <linux/ptrace.h> | 72 | #include <linux/ptrace.h> |
73 | #include <linux/blkdev.h> | ||
74 | #include <linux/elevator.h> | ||
73 | 75 | ||
74 | #include <asm/io.h> | 76 | #include <asm/io.h> |
75 | #include <asm/bugs.h> | 77 | #include <asm/bugs.h> |
@@ -794,6 +796,17 @@ static void __init do_pre_smp_initcalls(void) | |||
794 | do_one_initcall(*fn); | 796 | do_one_initcall(*fn); |
795 | } | 797 | } |
796 | 798 | ||
799 | /* | ||
800 | * This function requests modules which should be loaded by default and is | ||
801 | * called twice right after initrd is mounted and right before init is | ||
802 | * exec'd. If such modules are on either initrd or rootfs, they will be | ||
803 | * loaded before control is passed to userland. | ||
804 | */ | ||
805 | void __init load_default_modules(void) | ||
806 | { | ||
807 | load_default_elevator_module(); | ||
808 | } | ||
809 | |||
797 | static int run_init_process(const char *init_filename) | 810 | static int run_init_process(const char *init_filename) |
798 | { | 811 | { |
799 | argv_init[0] = init_filename; | 812 | argv_init[0] = init_filename; |
@@ -900,4 +913,7 @@ static noinline void __init kernel_init_freeable(void) | |||
900 | * we're essentially up and running. Get rid of the | 913 | * we're essentially up and running. Get rid of the |
901 | * initmem segments and start the user-mode stuff.. | 914 | * initmem segments and start the user-mode stuff.. |
902 | */ | 915 | */ |
916 | |||
917 | /* rootfs is available now, try loading default modules */ | ||
918 | load_default_modules(); | ||
903 | } | 919 | } |