aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorDaniel Borkmann <dborkman@redhat.com>2013-11-12 17:45:41 -0500
committerDavid S. Miller <davem@davemloft.net>2013-11-14 16:06:02 -0500
commit66b251422be7cb39e7619fee647724720f74d1f7 (patch)
tree060899ff6acf3bd106d242dc902baa4450ff8e7e /lib
parent16a3fa28630331e28208872fa5341ce210b901c7 (diff)
random32: add __init prefix to prandom_start_seed_timer
We only call that in functions annotated with __init, so add __init prefix in prandom_start_seed_timer() as well, so that the kernel can make use of this hint and we can possibly free up resources after it's usage. And since it's an internal function rename it to __prandom_start_seed_timer(). Signed-off-by: Daniel Borkmann <dborkman@redhat.com> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'lib')
-rw-r--r--lib/random32.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/random32.c b/lib/random32.c
index 82da4f4c3489..4f9d5dffc554 100644
--- a/lib/random32.c
+++ b/lib/random32.c
@@ -222,7 +222,7 @@ static void __prandom_timer(unsigned long dontcare)
222 add_timer(&seed_timer); 222 add_timer(&seed_timer);
223} 223}
224 224
225static void prandom_start_seed_timer(void) 225static void __init __prandom_start_seed_timer(void)
226{ 226{
227 set_timer_slack(&seed_timer, HZ); 227 set_timer_slack(&seed_timer, HZ);
228 seed_timer.expires = jiffies + 40 * HZ; 228 seed_timer.expires = jiffies + 40 * HZ;
@@ -270,7 +270,7 @@ void prandom_reseed_late(void)
270static int __init prandom_reseed(void) 270static int __init prandom_reseed(void)
271{ 271{
272 __prandom_reseed(false); 272 __prandom_reseed(false);
273 prandom_start_seed_timer(); 273 __prandom_start_seed_timer();
274 return 0; 274 return 0;
275} 275}
276late_initcall(prandom_reseed); 276late_initcall(prandom_reseed);