Skip to content

Commit

Permalink
random: remove cacheline alignment for locks
Browse files Browse the repository at this point in the history
Earlier changes greatly reduce the number of times we grab the lock
per output byte, so we shouldn't need this particular hack any more.

Signed-off-by: Matt Mackall <mpm@selenic.com>
Cc: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Matt Mackall authored and Linus Torvalds committed Apr 29, 2008
1 parent 1c0ad3d commit 4335820
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/char/random.c
Original file line number Diff line number Diff line change
Expand Up @@ -395,15 +395,15 @@ module_param(debug, bool, 0644);

struct entropy_store;
struct entropy_store {
/* mostly-read data: */
/* read-only data: */
struct poolinfo *poolinfo;
__u32 *pool;
const char *name;
int limit;
struct entropy_store *pull;

/* read-write data: */
spinlock_t lock ____cacheline_aligned_in_smp;
spinlock_t lock;
unsigned add_ptr;
int entropy_count;
int input_rotate;
Expand Down

0 comments on commit 4335820

Please sign in to comment.