Re: drivers/char/random.c line 728 BUG

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Andrew Morton
Date: Friday, August 29, 2008 - 12:54 pm

On Fri, 29 Aug 2008 12:48:07 -0700
Andrew Morton <akpm@linux-foundation.org> wrote:


The fixed version even generates improved code.

Let's try to avoid repeats:

--- a/drivers/char/random.c~drivers-char-randomc-fix-a-race-which-can-lead-to-a-bogus-bug-fix
+++ a/drivers/char/random.c
@@ -407,7 +407,7 @@ struct entropy_store {
 	/* read-write data: */
 	spinlock_t lock;
 	unsigned add_ptr;
-	int entropy_count;
+	int entropy_count;	/* Must at no time exceed ->POOLBITS! */
 	int input_rotate;
 };
 
_

--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
drivers/char/random.c line 728 BUG, Aaron Straus, (Tue Aug 26, 3:59 pm)
Re: drivers/char/random.c line 728 BUG, Aaron Straus, (Thu Aug 28, 3:59 pm)
Re: drivers/char/random.c line 728 BUG, Andrew Morton, (Fri Aug 29, 12:48 pm)
Re: drivers/char/random.c line 728 BUG, Andrew Morton, (Fri Aug 29, 12:54 pm)
Re: drivers/char/random.c line 728 BUG, Aaron Straus, (Fri Aug 29, 3:31 pm)
Re: drivers/char/random.c line 728 BUG, Andrew Morton, (Fri Aug 29, 3:42 pm)
Re: drivers/char/random.c line 728 BUG, Matt Mackall, (Wed Sep 3, 11:18 am)
Re: drivers/char/random.c line 728 BUG, Aaron Straus, (Wed Sep 3, 11:28 am)
Re: drivers/char/random.c line 728 BUG, Matt Mackall, (Wed Sep 3, 3:12 pm)
Re: drivers/char/random.c line 728 BUG, Andrew Morton, (Wed Sep 3, 3:32 pm)
Re: drivers/char/random.c line 728 BUG, Matt Mackall, (Wed Sep 3, 3:51 pm)
Re: drivers/char/random.c line 728 BUG, Andrew Morton, (Wed Sep 3, 4:12 pm)