Skip to content
This repository has been archived by the owner on Sep 18, 2022. It is now read-only.

Commit

Permalink
crypto: cryptd - Use subsys_initcall to prevent races with aesni
Browse files Browse the repository at this point in the history
commit b2bac6a upstream.

As cryptd is depeneded on by other algorithms such as aesni-intel,
it needs to be registered before them.  When everything is built
as modules, this occurs naturally.  However, for this to work when
they are built-in, we need to use subsys_initcall in cryptd.

Tested-by: Josh Boyer <[email protected]>
Signed-off-by: Herbert Xu <[email protected]>
Cc: Kerin Millar <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
  • Loading branch information
herbertx authored and gregkh committed Nov 11, 2011
1 parent f450df8 commit 6dd160d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crypto/cryptd.c
Original file line number Diff line number Diff line change
Expand Up @@ -945,7 +945,7 @@ static void __exit cryptd_exit(void)
crypto_unregister_template(&cryptd_tmpl);
}

module_init(cryptd_init);
subsys_initcall(cryptd_init);
module_exit(cryptd_exit);

MODULE_LICENSE("GPL");
Expand Down

0 comments on commit 6dd160d

Please sign in to comment.