Skip to content

Commit

Permalink
random: align rekey_work's timer
Browse files Browse the repository at this point in the history
Align rekey_work. Even though it's infrequent, we may as well line it up.

Signed-off-by: Anton Blanchard <[email protected]>
Acked-by: Matt Mackall <[email protected]>
Cc: Theodore Ts'o <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
antonblanchard authored and torvalds committed Apr 3, 2009
1 parent 98f4ebb commit 417b43d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/char/random.c
Original file line number Diff line number Diff line change
Expand Up @@ -1488,7 +1488,8 @@ static void rekey_seq_generator(struct work_struct *work)
keyptr->count = (ip_cnt & COUNT_MASK) << HASH_BITS;
smp_wmb();
ip_cnt++;
schedule_delayed_work(&rekey_work, REKEY_INTERVAL);
schedule_delayed_work(&rekey_work,
round_jiffies_relative(REKEY_INTERVAL));
}

static inline struct keydata *get_keyptr(void)
Expand Down

0 comments on commit 417b43d

Please sign in to comment.