Commit a4625085 authored by Brian King's avatar Brian King Committed by Linus Torvalds

[PATCH] libata: Convert from module_init to subsys_initcall

When building a monolithic kernel, the load order of drivers does not
work for SAS libata users, resulting in a kernel oops.

Convert libata to use subsys_initcall instead of module_init, which
ensures that libata gets loaded before any LLDD.

This is the same thing that scsi core does to solve the problem.  The
load order problem was observed on ipr SAS adapters and should exist for
other SAS users as well.
Signed-off-by: default avatarBrian King <brking@us.ibm.com>
Acked-by: default avatarJeff Garzik <jgarzik@pobox.com>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent cb07c9a1
...@@ -5957,7 +5957,7 @@ static void __exit ata_exit(void) ...@@ -5957,7 +5957,7 @@ static void __exit ata_exit(void)
destroy_workqueue(ata_aux_wq); destroy_workqueue(ata_aux_wq);
} }
module_init(ata_init); subsys_initcall(ata_init);
module_exit(ata_exit); module_exit(ata_exit);
static unsigned long ratelimit_time; static unsigned long ratelimit_time;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment