On Sun, Sep 09, 2001 at 08:19:05PM +0200, Sven Dehmlow privat wrote: > > Hi Sven, > > Hi Ralph, > Thank you for your fast response! > > >> [...] > > Does looking at existing uses of it help? > > > > http://lxr.linux.no/ident?i=get_random_bytes > > Yes, it did. If I understand things correctly, 'void > get_random_bytes(void *buf, int nbytes)' is the exported kernel > interface of 'extract_entropy'. It fills '*buf' with numbers from a > pool of random numbers. The number of the numbers (I know, it sounds > stupid...) that are put into '*buf' is defined by 'nbytes'. > I'm a little bit confused about the fact that '*buf' is defined as > 'void *buf'. If '*buf' is filled up with numbers why isn't it defined > as 'int' or something like that? I'd imagine it filled that memory location up with random 1's and 0's, so it doesn't care what type it is. void * is a generic thing meaning 'a pointer to a memory location' -- Mark Zealey (aka JALH on irc.openprojects.net: #zealos and many more) mark@itsolve.co.uk UL++++>$ G!>(GCM/GCS/GS/GM) dpu? s:-@ a16! C++++>$ P++++>+++++$ L+++>+++++$ !E---? W+++>$ N- !o? !w--- O? !M? !V? !PS !PE--@ PGP+? r++ !t---?@ !X---? !R- b+ !tv b+ DI+ D+? G+++ e>+++++ !h++* r!-- y-- (www.geekcode.com) - Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ IRC Channel: irc.openprojects.net / #kernelnewbies Web Page: http://www.kernelnewbies.org/