[PATCH] nandtest: use seed argument

Brian Norris computersforpeace at gmail.com
Mon Nov 28 12:56:50 EST 2011


On Thu, Nov 24, 2011 at 2:57 AM, Jan Weitzel <j.weitzel at phytec.de> wrote:
> if a seed is provided it is actually not used. First call is
> "seed = rand()" killing the given seed.
>
> Signed-off-by: Jan Weitzel <j.weitzel at phytec.de>

Tested-by: Brian Norris <computersforpeace at gmail.com>

You might also note that when a seed isn't provided, nandtest does not
produce random results because it just uses the default seed. At least
for my system, I see the same results every execution; I believe this
is the general C rand() behavior. I'll send a follow-up patch that
actually utilizes <time.h> to use time as a random seed.

Brian



More information about the linux-mtd mailing list