Skip to content

Commit

Permalink
[PATCH] libata: Convert from module_init to subsys_initcall
Browse files Browse the repository at this point in the history
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: Brian King <brking@us.ibm.com>
Acked-by: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Brian King authored and Linus Torvalds committed Nov 14, 2006
1 parent cb07c9a commit a462508
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/ata/libata-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -5957,7 +5957,7 @@ static void __exit ata_exit(void)
destroy_workqueue(ata_aux_wq);
}

module_init(ata_init);
subsys_initcall(ata_init);
module_exit(ata_exit);

static unsigned long ratelimit_time;
Expand Down

0 comments on commit a462508

Please sign in to comment.